Overview
| Artifact ID: | f342f53a747d80c04cae52d9dfc8eb5f014d13f5 |
|---|---|
| Ticket: | 1493067fffffffffffffffffffffffffffffffff
Mingw Tcl_FSStat() returns wrong file sizes |
| User & Date: | eriklns on 2006-05-22 16:45:15 |
Changes
- assignee changed to: "nobody"
- cmimetype changed to: "text/plain"
- comment changed to:
When using Tcl_FSStat(someTcl_Obj, &statBuf) in a Tcl extension compiled with MinGW, loading the extension in a stock ActiveTcl tclsh, the file sizes that are in the statBuf.size field are plain wrong. Attached, you find the code for an extension (filesize.c -> filesize.dll) defining a new Tcl command [filesize]. The results from that command compared to the regular [file size] command are: ActiveTcl8.4.12 tclsh.exe ========================= % load filesize.dll % filesize filesize.dll 1000 <== wrong value % file size filesize.dll 13933 As an alternative to the code in filesize.c, which has the memory for statBuf allocated automatically, I used Tcl_AllocStatBuf() to allocate the memory dynamically. This did not make a difference.
- foundin changed to: "None"
- priority changed to: "5 Medium"
- resolution changed to: "None"
- status changed to: "Open"
- submitter changed to: "eriklns"
- subsystem changed to: "None"
- title changed to: "Tcl_FSStat() returns wrong file sizes"
- type changed to: "Bug"