Path: utzoo!attcan!uunet!lll-winken!ames!mailrus!tut.cis.ohio-state.edu!bloom-beacon!TUB.BITNET!net From: net@TUB.BITNET (Oliver Laumann) Newsgroups: comp.windows.x Subject: Bugs in list widget Message-ID: <8902211520.AA06900@tub.UUCP> Date: 21 Feb 89 15:20:40 GMT Sender: daemon@bloom-beacon.MIT.EDU Organization: The Internet Lines: 23 During the last days I had the pleasure to ``fight'' with the Athena ``list'' widget. I disvovered two bugs (and there are probably more; I didn't test everything): 1) When the widget instance is initialized, the ``list'' resource is referenced (in an attempt to count the items) and *then* initialized to a default value. As a consequence, application programmers *must* pass a value for XtNlist to the call of XtCreateWidget(). Otherwise a NULL pointer is referenced in the function ResetList(). This can be fixed by moving the initialization of the ``list'' resource in front of the call to ResetList(). 2) The function PaintItemName() is sometimes called with an out-of-range item number which causes a segmentation violation or a bus error. I don't know under which circumstances this happens or how it can be fixed. It looks like an off-by-one error. Regards, -- Oliver Laumann net@TUB.BITNET net@tub.UUCP