Overview
| Artifact ID: | 0bea805e2b6c4142c667d316cd2f557004c15ce4ac3d6e400b8640b5034be890 |
|---|---|
| Ticket: | 25a127ccbd1f1e3da8ce7ed058ea7f4f570ece56
Windows: file rename -force onto a read-only file fails since TIP 744 |
| User & Date: | serhiy.storchaka on 2026-10-12 11:17:09 |
Changes
- cmimetype changed to: "text/x-fossil-wiki"
- comment changed to:
On Windows, <code>file rename -force</code> onto an existing read-only file fails in 9.1 with "permission denied", and the source is not moved. All 8.6 releases replace the file, as on Unix. <verbatim> foreach f {src dst} {close [open $f w]} file attributes dst -readonly 1 file rename -force src dst </verbatim> TIP 744 ([5e98a389b8]) replaced the rename of the target to a temporary name in <code>DoRenameFile()</code> by <code>MoveFileExW(MOVEFILE_REPLACE_EXISTING)</code>, which fails for a read-only target. Test fCmd-9.7 covers this, but it was skipped everywhere because of the undefined <code>notWine</code> constraint. - foundin changed to: "9.1.0"
- login: "serhiy.storchaka"
- priority changed to: "5 Medium"
- resolution changed to: "None"
- severity changed to: "Minor"
- status changed to: "Open"
- submitter changed to: "serhiy.storchaka"
- subsystem changed to: "37. File System"
- title changed to:
Windows: file rename -force onto a read-only file fails since TIP 744
- type changed to: "Bug"