Artifacts Associated With Ticket 568123ffffffffffffffffffffffffffffffffff
Ticket change [a891720f6b] (rid 99022) by hemanglavana on 2002-06-12 17:29:49:
- assignee initialized to: "nobody"
- cmimetype initialized to: "text/plain"
- comment initialized to:
Here's the patch: Index: tclBasic.c =================================================================== RCS file: /cvsroot/tcl/tcl/generic/tclBasic.c,v retrieving revision 1.58 diff -c -r1.58 tclBasic.c *** tclBasic.c 11 Jun 2002 15:42:19 -0000 1.58 --- tclBasic.c 12 Jun 2002 17:19:37 -0000 *************** *** 4970,4976 **** while ( (*tracePtr2) != NULL && (*tracePtr2) != tracePtr ) { tracePtr2 = &((*tracePtr2)->nextPtr); } ! if ( tracePtr2 == NULL ) { return; } (*tracePtr2) = (*tracePtr2)->nextPtr; --- 4970,4976 ---- while ( (*tracePtr2) != NULL && (*tracePtr2) != tracePtr ) { tracePtr2 = &((*tracePtr2)->nextPtr); } ! if ( *tracePtr2 == NULL ) { return; } (*tracePtr2) = (*tracePtr2)->nextPtr; If you examine the code carefully, tracePtr2 can never be NULL because it is assigned the address of (*tracePtr2)->nextPtr in the while loop. On the other hand, it is possible for *tracePtr2 to be NULL (this is also one of the conditions in while loop). Hence the if condition should check for *tracePtr2 == NULL instead of tracePtr2 == NULL, otherwise the following line "(*tracePtr2) = ..." can give segmentation fault. - foundin initialized to: "None"
- priority initialized to: "5 Medium"
- resolution initialized to: "None"
- status initialized to: "Open"
- submitter initialized to: "hemanglavana"
- subsystem initialized to: "None"
- title initialized to: "bug in Tcl_DeleteTrace function"
- type initialized to: "Bug"
Ticket change [5d99e647f3] (rid 115497) by msofer on 2002-06-13 02:36:15:
- closedate changed to: "2002-06-12T19:36:15"
- closer changed to: "msofer"
- icomment:
Logged In: YES user_id=148712 Done, thanks.
- login: "msofer"
- mimetype: "text/plain"
- resolution changed to: "Accepted"
- status changed to: "Closed"
- username: "msofer"
Ticket change [dbbaae7ffa] (rid 108010) by msofer on 2002-06-13 02:40:58:
- assignee changed to: "msofer"
- closedate changed to: "2002-06-12T19:40:58"
- closer changed to: "msofer"