Article View: comp.sys.next.programmer
Article #100side effects of DPSTraceContext() ?
From: Stefan Brueck
Date: Mon, 02 Nov 1992 16:13
Date: Mon, 02 Nov 1992 16:13
52 lines
2164 bytes
2164 bytes
hi
perhaps a stupid question:
which are the side effects of the DPSTraceContext() function?
the answer could help me to solve a problem found in a programming session:
my program (lets call it MyApp) is builded with InterfaceBuilder 2.1 under
NeXTStep 2.0.
MyApp wants to add some matrix elements to its mainmenu. therefore it
uses in a seperate routine called after the appDidBecomeActive: message
something like that:
myMenu = [NXApp mainMenu]
[myMenu sizeToFit]
this works fine when started without debugging. when debugging is done
with GDB there occurs a "Segmentation fault" in/after the sizeToFit:
call. the stackframe looks similar to this:
#0 nxzonefreenolock()
#1 free()
#2 freeBuckets()
...
#5 NXHashInsert()
#6 DPSMapNames()
bad. but there is a workaround for the problem. if i use DPSTraceContext()
in the following manner
1) DPSTraceContext() YES after loading the *nib file and before
[NXApp run]
2) DPSTraceContext NO before launching the main routines of MyApp
after receiving the appDidBecomeActive: message
the fault doesn't occure. "learning" from DPSTraceContext() could solve
the problem. another help would be the documentation for DPSMapNames()
- any idea where can i find this?
ciao
stefan
--
##############################################################################
Institut fuer Neue Materialien (INM) #
Universitaet des Saarlandes, Geb. 43 # Phone: +49 681 302 5086
Stefan Brueck # E-Mail (Internet): brueck@inm.uni-sb.de
W-6600 Saarbruecken (Germany) #
##############################################################################
Technical Details
Message-ID:
<BRUECK.92Nov2171304@inmsol.inm.uni-sb.de>Path:
arc1-ca.pugleaf.net!sparky!uunet!pipex!warwick!uknet!mcsun!Germany.EU.net!sbsvax!coli-gate.coli.uni-sb.de!coli-gate!brueckShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!pipex!warwick!uknet!mcsun!Germany.EU.net!sbsvax!coli-gate.coli.uni-sb.de!coli-gate!brueck From: brueck@inm.uni-sb.de (Stefan Brueck) Newsgroups: comp.sys.next.programmer Subject: side effects of DPSTraceContext() ? Message-ID: <BRUECK.92Nov2171304@inmsol.inm.uni-sb.de> Date: 2 Nov 92 16:13:04 GMT Sender: news@coli.uni-sb.de (Usenet news system) Distribution: comp Organization: Institute for New Materials (INM), Saarbr"ucken, Germany. Lines: 52