Segmentation violation in panel_paint

fredc at umrisca.isc.umr.edu fredc at umrisca.isc.umr.edu
Wed Jan 30 07:49:37 AEST 1991


I am writing a SunView application which uses a panel to present graphical
menus to the user.  Each time I put up a menu, I destroy all of the
current panel items and add different items to the panel.  In one
particular case, after clearing off the old items and adding some others,
I get a segmentation violation (discovered using dbxtool) some time after
displaying the newly reformed panel (i.e., it does not do this when
displaying the newly formed panel item array, but while other tasks are
being done).

The actual error message from dbxtool is:

signal SEGV (no mapping at the fault address) in panel_paint at 0xed6a3e6
panel_paint+0x4a:		tstl	a0@(0x52)

I think the problem might be that I am not getting all of the old panel
items deleted.  The way I am currently doing it is to save the panel item
pointers returned from the create functions in a linked list which I later
use to "panel_destroy" the items.  Is there a better or easier way to do
this, and how can I check if I got everything deleted?

Fred Clauss                  INTERNET:  fredc at isc.umr.edu (preferred)
P.O. Box 815                  		or fredc at ee.umr.edu
Rolla, MO 65401		     BITNET:    S081192 at UMRVMA
phone: (314)364-7224



More information about the Comp.sys.sun mailing list