Overview
| Artifact ID: | 67e146dfbef71a0024a65abccd7a5d81accea8dc4c06b4590c5806276f138be5 |
|---|---|
| Ticket: | 8c4082563d6a7ebda4b8804e221a0de31c4c40e4
Tcl_Eval() result can be truncated at NUL |
| User & Date: | serhiy.storchaka on 2024-06-23 14:04:21 |
Changes
- closedate changed to: "2460485.08636199"
- closer changed to: "serhiy.storchaka"
- icomment:
I tested also other eval functions (they are not used in Tkinter). `Tcl_EvalObjEx`, `Tcl_EvalEx` and `Tcl_GlobalEvalObj` do not truncate the result. `Tcl_VarEval` and `Tcl_GlobalEval` truncate the result. Looking at the code of `Tcl_Eval`, it is simply `Tcl_EvalEx` followed by `Tcl_GetStringResult`. So the result is truncated in `Tcl_GetStringResult`. The documentation for `Tcl_NewStringObj` implies that embedded null bytes are acceptable if the length is specified.
- login: "serhiy.storchaka"
- mimetype: "text/x-markdown"