Changeset 5bfd7ba2d5743010ea14e1fc3afc6c36f3ba2adc

Show
Ignore:
Timestamp:
05/14/08 22:02:59 (2 months ago)
Author:
Rémi Denis-Courmont <rem@videolan.org>
git-committer:
Rémi Denis-Courmont <rem@videolan.org> 1210795379 +0300
git-parent:

[3d7eabaf80eb76dc2111f399aec6586d1b0094a8]

git-author:
Rémi Denis-Courmont <rem@videolan.org> 1210795368 +0300
Message:

We may still have children when destroyed...

...if the destructor destroys them properly.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • src/misc/objects.c

    rbb84da6 r5bfd7ba  
    880880        if (p_this->p_parent) 
    881881            vlc_object_detach_unlocked (p_this); 
    882 #ifndef NDEBUG 
    883         /* Detach from children to protect against FIND_PARENT. 
    884          * Destroying an object with children is currently not allowed anyway. 
    885          * This code is there only to ensure that the debugging code in 
    886          * vlc_object_destroy() will be invoked before a concurrent 
    887          * FIND_PARENT gets the chance to crash the process. */ 
     882        /* Detach from children to protect against FIND_PARENT */ 
    888883        for (int i = 0; i < p_this->i_children; i++) 
    889884            p_this->pp_children[i]->p_parent = NULL; 
    890 #endif 
    891885    } 
    892886