<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Duncan Grisby wrote:
<blockquote cite="midE1Gc1Z4-0001XQ-Qq@apasphere.com" type="cite">
<pre wrap="">On Thursday 12 October, Tuyen Chau wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Is there an easy way to get _refCount() on an object reference?
</pre>
</blockquote>
<pre wrap=""><!---->
You can't. What are you trying to achieve by accessing the reference
count? Most things you could attempt to do would be subverted by race
conditions where the reference count changes after you access it.
Cheers,
Duncan.
</pre>
</blockquote>
Thanks Duncan. We need to use _refCount() for debugging purposes
only. We have a complex client that routinely obtains hundreds of
proxy objects through a fairly involved IDL then release them when they
are done. These objects can have member variables (in their proxy
class) that reference each other due to their hierarchical
relationship. We have a debugging mechanism in place to track the
reference count on objects (used with Orbix) to ensure that the objects
are properly released, and hence, the need to use an equivalent of
_refCount() in OmniOrb.<br>
<br>
Any other idea? The client has 2 threads, one thread making CORBA
requests, the other serving callbacks from the server.<br>
<br>
Tuyen,<br>
<br>
</body>
</html>