Seems I'm creating this thread totally on my own ... :-)
On Mon, Jul 03, 2000 at 01:41:03PM +0200, Alexander Mai wrote:
> Can anyone comment on our XmGetSecondaryResourceData() implementation?
> After I succeeded in building vdx (I had to use an old gcc; gcc 2.9.x doesn't
> work - I assume the code is not ANSI C++ compliant) I was able to start up
> the app.
> Loading an arbitrary project seems to trigger a crash caused
> by bogus data supplied by XmGetSecondaryResourceData().
[...]
> LessTif's doesn't 'say' anything.
> The problem may be much deeper inside LessTif than the call given
> above ...
>
Well guessed ;-)
1) some widgets seem to differ WRT implementation,
this explains test/baseclass/test5
2) we could have a known(?) bug in Vendor.c
static Cardinal
get_sec_res_data(WidgetClass wc, XmSecondaryResourceData **data)
{
/* FIX ME */
return _XmSecondaryResourceData(&_XmVendorSCoreClassExtRec,
data, NULL, NULL, NULL, NULL);
}
The function being called returns invalid or at least questionable
data due to the NULLs being passed. Then it returns 1 which
is passed upwards and finally returned from XmGetSecondaryResourceData().
Applications (VDX ...) seem to rely on e.g. resource name != NULL
and might crash.
'Fixing' this seems to make VDX work at least beyond loading the
1-2 examples which I've tried.
The '' indicates I'm not sure at all how to properly fix this,
I just did it manually within gdb ...
--
Alexander Mai
[EMAIL PROTECTED]