From: <no...@tc...> - 2025-08-04 17:48:18
|
Automated mail by fx, on behalf of no...@tc... Ticket Change [b7c27ae764ca603dfb4897e7da1152189c344b95696455f0771da50263f12f93] ["crc32 -filename $name" end in error on files containing wrong encodings] By anonymous For Tcllib On 2025-08-04T17:38:15.902 Details https://core.tcl-lang.org/tcllib/tinfo?name=b7c27ae764ca603dfb4897e7da1152189c344b95696455f0771da50263f12f93 Ticket https://core.tcl-lang.org/tcllib/tktview/7bd2d439ca61da14a9fc5e8372e5fb1f86c28ff1 Changed Fields assignee: nobody closer: nobody comment: Old Tcl scripts running on 8.6.x+ with corresponding Tcllib for crc32 package read the files regardless of their encoding or with the system encoding. Now with Tcl 9.0.1 and corresponding Tcllib the crc32 package do the same, but the core checks for wrong encoding on read of file's content. The error message from "crc32::crc32" with used option "-filename" gives on some files "invalid integer" than a checksum. All these files have not the same encoding as used from system and/or simple compatible (ASCII) text. Maybe new options for encoding (and/or binary or not) are needed? Best solution for now is not to use the convenient way: open file for them self, fconfigure it to the right encoding or binary, and finally run crc32 with this handle, afterwards closing file and unset used temporary variables. (Please set the Version for Tcl 9.0.1, I use on ActiveTcl 8.6.4.1 crc32 1.3.2 and found it on BAWT-distribution 3.0.1, thanks.) Best greetings, Thomas [TWu] is_private: 0 login: anonymous priority: 5 Medium resolution: None severity: Critical status: Open submitter: anonymous subsystem: crc title: "crc32 -filename $name" end in error on files containing wrong encodings type: Bug ------------------------------------------------------------ See Tcl/Tk development @ http://core.tcl-lang.org/ ------------------------------------------------------------ |