[omniNotify] 64 bit notifd on Solaris 2.8 core dumps immediately

Bob Gruber bob.gruber at gmail.com
Wed Jun 15 17:37:07 BST 2005


I'm not able to look at the code right now, but assuming that the
omniNotify code is always referring to a CORBA::Long when it is
manipulating longs, one could replace the use of 'long' with
'CORBA::Long' in the entire code base.

In particular, change

(*(long*)foo)

to 

(*(CORBA::Long*)foo)

Does that work?



On 6/15/05, Mark Zimmerman <markzimm at frii.com> wrote:
> sizeof(void*) = sizeof(long) always. This code by itself is OK but the
> problem is created higher up in the call tree. It is not the size of
> the pointers that is the problem but rather the size and alignment of
> the data element being pointed to. It starts out as a reference to a
> 32 bit value but is transmogrified through perverse magic into what it
> thinks is a pointer to a 64 bit value.
> 
> -- Mark
> 
> On Wed, Jun 15, 2005 at 08:16:37PM +0100, Jon wrote:
> > Hi
> > is that because they are casting void * to long *?
> > eg
> > inline int RDI_SLongRank(const void* L, const void* R)
> > { return *((long *) L) - *((long *) R); }
> >
> > are those types different sizes on 64 bit solaris 8?
> > you could hack up a quick test program to take size of each type to check?
> >
> >
> >
> > Jon
> >
> > On Wednesday 15 June 2005 18:28, Mark Zimmerman wrote:
> > > On Wed, Jun 15, 2005 at 10:46:10AM -0600, Mark Zimmerman wrote:
> > > > notifd seems to run fine with this change but I am concerned that this
> > > > might break it in other ways I have not yet encountered.
> > >
> > > Well, "seems to run fine" was a major overstatement; It really just
> > > starts up fine but continues to get bus errors as soon as something
> > > tries to use it. All of the functions in RDIHashFuncs.h that contain
> > > the string 'Long' in their names exhibit this problem.
> > >
> > > -- Mark
> > >
> > > _______________________________________________
> > > omninotify-list mailing list
> > > omninotify-list at omniorb-support.com
> > > http://www.omniorb-support.com/mailman/listinfo/omninotify-list
> >
> 
> _______________________________________________
> omninotify-list mailing list
> omninotify-list at omniorb-support.com
> http://www.omniorb-support.com/mailman/listinfo/omninotify-list
>



More information about the omninotify-list mailing list