Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 26f36430e34e81543891e9bc0ea5330327214167
Ticket: 2879351fffffffffffffffffffffffffffffffff
file writable broken on Windows
User & Date: damonc on 2009-10-14 22:41:40
Changes

  1. assignee changed to: "nobody"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    This is a dup of bug #2857875, which was closed by SF while I was off having a baby.  The following script was run on a Vista 32 bit installation with the given results:
    
    puts "Tcl Version = [info patchlevel]"
    
    set file tmp[pid].txt
    
    foreach dir [list C:/ "C:/Program Files" $::env(LOCALAPPDATA)] {
        if {[file writable $dir]} {
            puts "$dir is writable"
        } else {
            puts "$dir is not writable"
        }
    
        if {[catch {close [open [file join $dir $file] w]} err]} {
            puts "Could not create file in $dir"
        } else {
            puts "Created file in $dir"
            file delete [file join $dir $file]
        }
    }
    
    Results:
    
    Tcl Version = 8.4.12
    C:/ is writable
    Could not create file in C:/
    C:/Program Files is not writable
    Created file in C:/Program Files
    C:\Users\vmuser\AppData\Local is writable
    Created file in C:\Users\vmuser\AppData\Local
    
    Tcl Version = 8.4.13
    C:/ is not writable
    Could not create file in C:/
    C:/Program Files is not writable
    Created file in C:/Program Files
    C:\Users\vmuser\AppData\Local is writable
    Created file in C:\Users\vmuser\AppData\Local
    
    Tcl Version = 8.6b1.1
    C:/ is not writable
    Could not create file in C:/
    C:/Program Files is not writable
    Created file in C:/Program Files
    C:\Users\vmuser\AppData\Local is writable
    Created file in C:\Users\vmuser\AppData\Local
    
    And, running as Administrator:
    
    Tcl Version = 8.6b1.1
    C:/ is writable
    Created file in C:/
    C:/Program Files is writable
    Created file in C:/Program Files
    C:\Users\vmuser\AppData\Local is writable
    Created file in C:\Users\vmuser\AppData\Local
    
    Please tell me if there's anything else I can test or any other information you need.
    
  4. foundin changed to: "None"
  5. is_private changed to: "0"
  6. priority changed to: "5 Medium"
  7. resolution changed to: "None"
  8. status changed to: "Open"
  9. submitter changed to: "damonc"
  10. subsystem changed to: "None"
  11. title changed to: "file writable broken on Windows"
  12. type changed to: "Bug"