Fix to prevent proxy writer from getting alive while deleting
Signed-off-by: Dennis Potman <dennis.potman@adlinktech.com>
This commit is contained in:
		
							parent
							
								
									801def8bd5
								
							
						
					
					
						commit
						63df8cb38d
					
				
					 1 changed files with 7 additions and 0 deletions
				
			
		| 
						 | 
				
			
			@ -4598,6 +4598,13 @@ void proxy_writer_set_alive_may_unlock (struct proxy_writer *pwr, bool notify)
 | 
			
		|||
     heap). */
 | 
			
		||||
  assert (!pwr->alive);
 | 
			
		||||
 | 
			
		||||
  /* check that proxy writer still exists (when deleting it is removed from guid hash) */
 | 
			
		||||
  if (ephash_lookup_proxy_writer_guid (pwr->e.gv->guid_hash, &pwr->e.guid) == NULL)
 | 
			
		||||
  {
 | 
			
		||||
    ELOGDISC (pwr, "proxy_writer_set_alive_may_unlock("PGUIDFMT") - not in guid_hash, pwr deleting\n", PGUID (pwr->e.guid));
 | 
			
		||||
    return;
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  ddsrt_mutex_lock (&pwr->c.proxypp->e.lock);
 | 
			
		||||
  pwr->alive = true;
 | 
			
		||||
  pwr->alive_vclock++;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue