radixii@grebyn.com (Radix II) (12/04/90)
We are having lots of problems with memory growth in a Motif application. We are using SCO's ODT. The problem seems to be that no Widget completely gives up all of its memory when the Widget is destroyed. Text Widgets and List widgets are the biggest culprits. The Text Widgets are all multi-line, read-only widgets which are inside a Form Dialog. Typical text size is 2-3K. When the user presses the QUIT button, the application destroys the Form Dialog. The Scrolled List Widgets are also part of a Form Dialog. Number of items varies from a few to hundreds. The amount of memory left undestroyed varies with the number of items in the List. The widget hierarchy is: I. FormDialog (FORM) 1. Scrolled Text Widget (or Scrolled List) 2. Row Column Widget 2a. PushButton Widget (QUIT) 2b. PushButton Widget The callback procedure for the Pushbutton contains the code to destroy. At the present time, the following is used for the forms containing a Text Widget: XtPopdown (XtParent (form) XtDestroyWidget (XtParent (form) ) Approximately 17K of memory is never recovered after this process. In the case of the List Widget, destroying XtParent(form) produces a core dump. Destroying the form itself produces a core dump unless the list is destroyed first: XtPopdown (XtParent (form) ) XtDestroyWidget (list) XtDestroyWidget (form) For a small number of list items, about 40K of memory is not recovered. We have used xlswins to check if the windows have actually disappeared from the server -- they have. We have checked that compound strings and buffers created by the application have been freed. Please send replies to : radixii@grebyn.com Any suggestions will be gratefully appreciated. Thank you in advance, Holly Wallace Radix II, Incorporated. .
mgsmith@hplabsb.HP.COM (Michael Smith) (12/05/90)
>We are having lots of problems with memory growth in a Motif >application. Most of the memory leak problems have been fixed with Motif 1.1. Is that what you are using. Mike Smith HP Labs