asokan@lgc.com (Asokan Manohar) (06/18/91)
Hi Netters:
I am keen to know if XtGetValues allocates memory for motif resources,
which needs to be freed by the calling application.
Consider the following example...
XmStringTable xmstr;
int n = 0, tot;
Arg args[2];
XtSetArg(args[n], XmNitems, &xmstr); n++;
XtSetArg(args[n], XmNitemCount, &tot); n++; /* # of items */
XtGetValues(list_wdg, wargs, n);
Is it correct to free as next ?
while(tot)
{
XmStringFree(xmstr[tot-1]);
tot--;
}
XtFree(xmstr);
Thx a lot for replying !
e mail:
asokan@lgc.com
--
Overflow on /dev/null; Please empty the bit bucket