Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 686fe073529acc667e5aa68a326b780e0e6b8aba
Ticket: 1661378fffffffffffffffffffffffffffffffff
"file readable" broken on vmware shared folders
User & Date: aotto1968 on 2007-02-16 10:13:10
Changes

  1. assignee changed to: "dkf"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    Dear Support,
    
      I have a problem with "file readable" on winxp 32bit
      as vmware guest on an openSuse host.
    
      I using "Shared Folders" on windows to access
      a directory from linux.
    
      but tcl on winxp has a problem with acessing
      files on the shared folder:
    
      detail:
    
       1. file readable returns 0 -> not readable
       2. but in tcl I can open and read this file -> readable
       3. the problem is that the tcl pkgLoader stops working
    
    from tclPkgUnknown in tcl8.4 package.tcl
    >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
    501   catch {
    502       foreach file [glob -directory $dir -join -nocomplain \
    503               * pkgIndex.tcl] {
    504           set dir [file dirname $file]
    505           if {![info exists procdDirs($dir)] && [file readable $file]} {
    506               if {[catch {source $file} msg]} {
    507                   tclLog "error reading package index file $file: $msg"
    508               } else {
    509                   set procdDirs($dir) 1
    510               }
    511           }
    512       }
    513   }
    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
    
    the "file readable" will return 0 and the pkgLoader will not
    load the pkgIndex.tcl file
    
    => this is a bug
    from the code down you get the info that from inside tcl
    "files readable" returns 0 but I can open and read the file
    
    test script
    >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><
    
    parray tcl_platform
    
    foreach f {"//.host/Shared
    Folders/FbgBase/src/TestFreiburg/lib/TestFbg/pkgIndex.tcl"} {
    
        puts "++ $f"
        if {![file exists $f]} {
            puts "  -> file does not exists !!"
            continue
        }
        unset -nocomplain stat
        unset -nocomplain attribute
        file stat $f stat
        array set attribute [file attributes $f]
        puts exists:[file exists $f]
        puts readable:[file readable $f]
        parray stat
        parray attribute
        set FH [open $f r]
        while {![eof $FH]} {
            puts "pkgIndex.tcl: [gets $FH]"
        }
        close $FH
    }
    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
    
    results
    >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
    tcl_platform(byteOrder) = littleEndian
    tcl_platform(machine)   = intel
    tcl_platform(os)        = Windows NT
    tcl_platform(osVersion) = 5.1
    tcl_platform(platform)  = windows
    tcl_platform(user)      = SYSTEM
    tcl_platform(wordSize)  = 4
    ++ //.host/Shared Folders/FbgBase/src/TestFreiburg/lib/TestFbg/pkgIndex.tcl
    exists:1
    readable:0
    stat(atime) = 1171619183
    stat(ctime) = 1171619183
    stat(dev)   = -1
    stat(gid)   = 0
    stat(ino)   = 0
    stat(mode)  = 33188
    stat(mtime) = 1171545538
    stat(nlink) = 1
    stat(size)  = 369
    stat(type)  = file
    stat(uid)   = 0
    attribute(-archive)   = 0
    attribute(-hidden)    = 0
    attribute(-longname)  = //.host/Shared
    Folders/FbgBase/src/TestFreiburg/lib/TestFbg/pkgIndex.tcl
    attribute(-readonly)  = 0
    attribute(-shortname) = //.host/Shared
    Folders/FbgBase/src/TestFreiburg/lib/TestFbg/pkgIndex.tcl
    attribute(-system)    = 0
    pkgIndex.tcl: ##
    pkgIndex.tcl: ##  testFreiburg - src/TestFreiburg/lib/pkgIndex.tcl
    pkgIndex.tcl: ##
    pkgIndex.tcl: ##  (C) 2004 - Freiburg - Project - Group
    pkgIndex.tcl: ##  ------------------------------------------------------
    pkgIndex.tcl: ##  EMail: freiburg AT compiler-factory DOT de
    pkgIndex.tcl: ##  ------------------------------------------------------
    pkgIndex.tcl: ##  all rights reserved
    pkgIndex.tcl: ##
    pkgIndex.tcl:
    pkgIndex.tcl: package ifneeded TestFbg 2.0 [list source [file join $dir
    TestFbg.tcl]]
    pkgIndex.tcl:
    pkgIndex.tcl:
    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
    
    
    mfg
    
      Andreas Otto
    
    
  4. foundin changed to: "obsolete: 8.4.14"
  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: "aotto1968"
  10. subsystem changed to: "16. Commands A-H"
  11. title changed to: ""file readable" broken on vmware shared folders"
  12. type changed to: "Bug"