[omniORB] Crash on using nil reference

Sai-Lai Lo S.Lo@uk.research.att.com
11 May 2001 11:38:15 +0100


>>>>> Tim Ward writes:

> From: Duncan Grisby <dgrisby@uk.research.att.com>
>> 
>> The semantics of the reference counts are that when the count reaches
>> zero, the object reference is deleted. After that, any operations on
>> the object reference are dealing with freed memory, so it's impossible
>> for the ORB to trap reliably. The fact that you are using _var types
>> doesn't make any difference.

> Ah, right. (More sophisticated smart pointers keep a map of pointers and
> reference counts (in debug builds, at least), so after an object has been
> deallocated the pointer can still reliably and safely spot and report this
> without crashing.)

And how does one retire the mapping of pointers and reference counts?


-- 
Sai-Lai Lo                                   S.Lo@uk.research.att.com
AT&T Laboratories Cambridge           WWW:   http://www.uk.research.att.com 
24a Trumpington Street                Tel:   +44 1223 343000
Cambridge CB2 1QA                     Fax:   +44 1223 313542
ENGLAND