Operating System - HP-UX
1832251 Members
2586 Online
110041 Solutions
New Discussion

64-bit motif GUIs core in utf8 locale.

 
BryceX
New Member

64-bit motif GUIs core in utf8 locale.

Greetings,

The following program will core (SIGBUS) dump when a '/' is entered in the text box.

OS: HP/UX 11.11i,11.00
locale: en_US.utf8

compile using: /opt/ansic/bin/cc +DD64 file.c -lXm -lXt -lX11

#include
#include

#include
#include

int
main(int argc, char **argv)

{
Widget shell;
Widget text;
XtAppContext app;

printf("LC_ALL = %s\n", setlocale(LC_ALL, ""));

XtSetLanguageProc(NULL, NULL, NULL);

shell = XtVaOpenApplication(&app, "Utf8text", NULL, 0,
&argc, argv, NULL, sessionShellWidgetClass, NULL);

text = XmCreateText(shell, "Text", NULL, 0);

XmTextSetString(text, "type a '/' for core dump");

XtManageChild(text);

XtRealizeWidget(shell);
XtAppMainLoop(app);

return (0);
}


I have installed patch PHSS_33130(11.11) and PHSS_29369(11.00) which advertises to fix this bug but the problem persists.

The problem is specific to 64-bit binaries running in a utf8 locale. roman8 and iso88597 locales run fine.

The stack trace is as follows:

(gdb) bt
#0 0x800003fffee5d5d4 in + 0x800001f ()
from /usr/lib/nls/iconv/pa20_64/methods.2/lsbucs2.sl
#1 0x800003ffff3d3ae8 in iconv+0x30 () from /usr/lib/pa20_64/libc.2
#2 0x800003ffff4af090 in GetUTF8CharFromISOCode+0x58 ()
from /usr/lib/pa20_64/libX11.3
#3 0x800003ffff4af874 in _XHPInputISO8859_15ToUTF8+0x74 ()
from /usr/lib/pa20_64/libX11.3
#4 0x800003ffff4b0f64 in _XhpConvertLookup+0x194 ()
from /usr/lib/pa20_64/libX11.3
#5 0x800003ffff4ce868 in _XimLocalMbLookupString+0x50 ()
from /usr/lib/pa20_64/libX11.3
#6 0x800003ffff488434 in XmbLookupString+0x3c ()
from /usr/lib/pa20_64/libX11.3
#7 0x800003ffff76a944 in XmImMbLookupString+0x94 ()
from /usr/lib/pa20_64/libXm.4
#8 0x800003ffff6faa18 in SelfInsert+0x60 () from /usr/lib/pa20_64/libXm.4
#9 0x800003ffff56cfcc in HandleActions+0x134 () from /usr/lib/pa20_64/libXt.3
#10 0x800003ffff56d614 in HandleSimpleState+0x29c ()
from /usr/lib/pa20_64/libXt.3
#11 0x800003ffff56ddd8 in _XtTranslateEvent+0xb0 ()
from /usr/lib/pa20_64/libXt.3
#12 0x800003ffff53e51c in XtDispatchEventToWidget+0x374 ()
from /usr/lib/pa20_64/libXt.3
---Type to continue, or q to quit---
#13 0x800003ffff53f650 in _XtDefaultDispatcher+0x418 ()
from /usr/lib/pa20_64/libXt.3
#14 0x800003ffff53f840 in XtDispatchEvent+0x128 ()
from /usr/lib/pa20_64/libXt.3
#15 0x800003ffff53ff60 in XtAppMainLoop+0x58 () from /usr/lib/pa20_64/libXt.3
#16 0x4000000000002838 in main (argc=1, argv=0x800003ffff7f0598)
at utf8text.c:29

Does anyone know of another patch I need to install to resolve this bug?

Thanks,

B

Attached is the built binary compiled on an HP 11.00 box (PHSS_29369 applied).
1 REPLY 1
CMART
New Member

Re: 64-bit motif GUIs core in utf8 locale.

LOL LEARN TO PROGRAM NOOB