Overview
| Artifact ID: | ad897e6059c5b8005b11278b9768150a6775ad24 |
|---|---|
| Ticket: | 1882373fffffffffffffffffffffffffffffffff
Bug in code of Tcl_GetAlias in tclInterp.c |
| User & Date: | an00na on 2008-01-30 04:32:04 |
Changes
- assignee changed to: "hobbs"
- cmimetype changed to: "text/plain"
- comment changed to:
The last `for' loop in Tcl_GetAlias function: for (i = 1; i < objc; i++) { *argvPtr[i - 1] = TclGetString(objv[i]); } The bug spot is `*argvPtr[i - 1]'. Obviously, it should be `(*argvPtr)[i - 1]', otherwise, it causes invalid memory access when objc > 2, since it is only when idx is 0 that *argvPtr[idx] is the same as (*argvPtr)[idx] in effect. Thus, the fixed code is: for (i = 1; i < objc; i++) { (*argvPtr)[i - 1] = TclGetString(objv[i]); } It is verified by our application product. - foundin changed to: "obsolete: 8.5.0"
- is_private changed to: "0"
- priority changed to: "5 Medium"
- resolution changed to: "None"
- status changed to: "Open"
- submitter changed to: "an00na"
- subsystem changed to: "20. [interp]"
- title changed to: "Bug in code of Tcl_GetAlias in tclInterp.c"
- type changed to: "Bug"