Overview
| Artifact ID: | fbe3dcbbec61fcf6779bab343ca4584da0c4eefc |
|---|---|
| Ticket: | 1283976fffffffffffffffffffffffffffffffff
Tcl_UniCharToUtf mishandles negative input |
| User & Date: | dgp on 2005-09-07 13:55:34 |
Changes
- assignee changed to: "nijtmans"
- cmimetype changed to: "text/plain"
- comment changed to:
dkf% scan [format %c -1] %c%c%c 255 191 {} ... [09:43]dkf% string bytelength [format %c -1] 2 ... [09:43]dkfSo, [format %c -1] is *wrong* ... [09:44]dgphmmm... Tcl_UniCharToUtf accepts an "int" argument instead of a "Tcl_UniChar" one. [09:44]dkfI think that's because some compilers aren't keen on arguments narrower than a word [09:45]dgpbut the logic of the routine assumes an unsigned input. rmaxdgp: IIRC I also wondered about this when I worked on the -nocase stuff some time ago, and Jeff knew the reason why it is so. [09:45]dkfI think T_UCTU should cast it's argument to Tcl_UniChar [09:46]dkf(at the very least) ... [09:49]dgpok, so the flaw is in T_UCTU and not [format] itself ten [09:53]dkf[format] shouldn't be able to step outside the internal encoding model - foundin changed to: "obsolete: 8.4.11"
- priority changed to: "5 Medium"
- resolution changed to: "None"
- status changed to: "Open"
- submitter changed to: "dgp"
- subsystem changed to: "44. UTF-8 Strings"
- title changed to: "Tcl_UniCharToUtf mishandles negative input"
- type changed to: "Bug"