[ROOT] on lists

From: Primrose Mbanefo (didi_mbanefo@laposte.net)
Date: Thu Aug 16 2001 - 11:23:06 MEST


Hello everyone,
In the following code presenter is an object from the TRootControlBar class.

gROOT->GetListOfSpecials()->Add(presenter)

This is a test to know if presenter still exists or if it has been deleted by 
another function:
{
end with '}'> if (gROOT->GetListOfSpecials()->FindObject(presenter))
end with '}'> cout<<"in"<<endl;
end with '}'> else
end with '}'> cout<<"out"<<endl;
end with '}'> }
 
But when presenter doesn't exist anymore I get a segmentation fault. 
 *** Break *** segmentation violation

I would like to know why I get the segmentation fault and if an object is 
automatically removed from the list when it has been deleted by another 
function. Isn't there any way of knowing if an object still exists or if it 
has been deleted?
Thanks a lot.
Primrose



This archive was generated by hypermail 2b29 : Tue Jan 01 2002 - 17:50:57 MET