From: <no...@so...> - 2002-10-02 20:50:49
|
Bugs item #607390, was opened at 2002-09-10 09:26 You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=112997&aid=607390&group_id=12997 Category: 07. [entry] Group: 8.4.0 >Status: Closed >Resolution: Duplicate Priority: 7 Submitted By: Don Porter (dgp) Assigned to: Jeffrey Hobbs (hobbs) Summary: segfault in entry var trace Initial Comment: Another segfault similar to 605121: set FOO init entry .e1 -textvariable FOO -validate all \ -vcmd {%W configure -bg white; format 1} bind .e1 <Destroy> {set FOO hello} destroy .e1 Again the problem is that EntryTextVarProc passes a NULL varName to Tcl_SetVar. Program received signal SIGSEGV, Segmentation fault. 0x1201c8394 in TclLookupVar (interp=0x120346320, part1=0x0, part2=0x0, flags=1, msg=0x120216bef "read", createPart1=0, createPart2=1, arrayPtrPtr=0x11fffddb8) at ../unix/../generic/tclVar.c:236 236 for (p = part1; *p ; p++) { (gdb) bt #0 0x1201c8394 in TclLookupVar (interp=0x120346320, part1=0x0, part2=0x0, flags=1, msg=0x120216bef "read", createPart1=0, createPart2=1, arrayPtrPtr=0x11fffddb8) at ../unix/../generic/tclVar.c:236 #1 0x1201c99ac in Tcl_GetVar2Ex (interp=0x120346320, part1=0x0, part2=0x0, flags=1) at ../unix/../generic/tclVar.c:1075 #2 0x1201c98cc in Tcl_GetVar2 (interp=0x120346320, part1=0x0, part2=0x0, flags=1) at ../unix/../generic/tclVar.c:1027 #3 0x1201c9844 in Tcl_GetVar (interp=0x120346320, varName=0x0, flags=1) at ../unix/../generic/tclVar.c:987 #4 0x12003931c in EntryTextVarProc (clientData=0x120436de0, interp=0x120346320, name1=0x120439f80 "FOO", name2=0x0, flags=32) at /local/src/tk/unix/../generic/tkEntry.c:3321 #5 0x1201ceef8 in CallVarTraces (iPtr=0x120346320, arrayPtr=0x0, varPtr=0x120436120, part1=0x120439f80 "FOO", part2=0x0, flags=32, leaveErrMsg=512) at ../unix/../generic/tclVar.c:4188 #6 0x1201ca874 in TclPtrSetVar (interp=0x120346320, varPtr=0x120436120, arrayPtr=0x0, part1=0x120439f80 "FOO", part2=0x0, newValuePtr=0x1203b3b00, flags=512) at ../unix/../generic/tclVar.c:1658 #7 0x1201ca208 in Tcl_ObjSetVar2 (interp=0x120346320, part1Ptr=0x1203ddb20, part2Ptr=0x0, newValuePtr=0x1203b3b00, flags=512) at ../unix/../generic/tclVar.c:1492 #8 0x1201c9df8 in Tcl_SetObjCmd (dummy=0x0, interp=0x120346320, objc=3, objv=0x11fffe450) at ../unix/../generic/tclVar.c:1263 #9 0x12011cf3c in TclEvalObjvInternal (interp=0x120346320, objc=3, objv=0x11fffe450, command=0x11fffe668 "set FOO hello", length=13, flags=0) at ../unix/../generic/tclBasic.c:3048 #10 0x12011e05c in Tcl_EvalEx (interp=0x120346320, script=0x11fffe668 "set FOO hello", numBytes=13, flags=0) at ../unix/../generic/tclBasic.c:3646 #11 0x12011e5dc in Tcl_Eval (interp=0x120346320, string=0x11fffe668 "set FOO hello") at ../unix/../generic/tclBasic.c:3811 #12 0x120120ec4 in Tcl_GlobalEval (interp=0x120346320, command=0x11fffe668 "set FOO hello") at ../unix/../generic/tclBasic.c:5261 #13 0x1200c723c in Tk_BindEvent (bindingTable=0x1203a2400, eventPtr=0x11fffead8, tkwin=0x120436170, numObjects=0, objectPtr=0x11fffe910) at /local/src/tk/unix/../generic/tkBind.c:1805 #14 0x1200d00a4 in TkBindEventProc (winPtr=0x120436170, eventPtr=0x11fffead8) at /local/src/tk/unix/../generic/tkCmds.c:287 #15 0x1200dbc7c in Tk_HandleEvent (eventPtr=0x11fffead8) at /local/src/tk/unix/../generic/tkEvent.c:1017 #16 0x12001d634 in Tk_DestroyWindow (tkwin=0x120436170) at /local/src/tk/unix/../generic/tkWindow.c:1356 #17 0x1200d07cc in Tk_DestroyObjCmd (clientData=0x1203a11b0, interp=0x120346320, objc=2, objv=0x11fffef10) at /local/src/tk/unix/../generic/tkCmds.c:472 #18 0x12011cf3c in TclEvalObjvInternal (interp=0x120346320, objc=2, objv=0x11fffef10, command=0x120436106 "destroy .e1\n", length=12, flags=0) at ../unix/../generic/tclBasic.c:3048 #19 0x12011e05c in Tcl_EvalEx (interp=0x120346320, script=0x120436080 "set FOO init\nentry .e1 -textvariable FOO -validate all \\n\t-vcmd {%W configure -bg white; format 1}\nbind .e1 <Destroy> {set FOO hell o}\ndestroy .e1\n", numBytes=146, flags=0) at ../unix/../generic/tclBasic.c:3646 #20 0x120191608 in Tcl_FSEvalFile (interp=0x120346320, pathPtr=0x1203b3b60) at ../unix/../generic/tclIOUtil.c:1371 #21 0x120190288 in Tcl_EvalFile (interp=0x120346320, fileName=0x11ffff278 "seg3.tcl") at ../unix/../generic/tclIOUtil.c:234 #22 0x12001b348 in Tk_MainEx (argc=1, argv=0x11ffff3e0, appInitProc=0x12001ae80 <Tcl_AppInit>, interp=0x120346320) at /local/src/tk/unix/../generic/tkMain.c:234 #23 0x12001ae58 in main (argc=2, argv=0x11ffff3d8) at /local/src/tk/unix/tkAppInit.c:68 ---------------------------------------------------------------------- >Comment By: Jeffrey Hobbs (hobbs) Date: 2002-10-02 13:50 Message: Logged In: YES user_id=72656 fix in 8.4.1 - the entry must check ENTRY_DELETED to abort the EntryTextVarProc early when it is being destroyed. Dup'ed to 617446. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=112997&aid=607390&group_id=12997 |