Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 3c2d0f8c02e831e611d21ef3f2d06a14c8c54f40
Ticket: 218355ffffffffffffffffffffffffffffffffff
problem with file names starting with tilde
User & Date: nobody on 2000-10-26 00:56:38
Changes

  1. assignee changed to: "nobody"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    OriginalBugID: 4131 Bug
    Version: 8.3b2
    SubmitDate: '2000-02-07'
    LastModified: '2000-03-01'
    Severity: LOW
    Status: Closed
    Submitter: techsupp
    ChangedBy: hobbs
    OS: Windows 98
    OSVersion: 4.10.1998
    Machine: Celeron 300 / 64 Mb
    FixedDate: '2000-10-25'
    ClosedDate: '2000-03-01'
    
    
    Name: SnakE
    
    Comments:
    The bug is in the 'glob' command. In example above its output is:
          tools Stuff ~test.file temp
        while it should be:
          tools Stuff ./~test.file temp
    
    ReproducibleScript:
    test.tsh:
      foreach name [glob -nocomplain *] { puts [file join somedir $name] }
    
    To see the bug, you should have a file which name starts with tilde, '~test.file' for example, in the current directory. Then run the test: 'tclsh83.exe test.tsh'
    
    ObservedBehavior:
    The output will be like this:
      somedir/tools
      somedir/Stuff
      ~test.file
      somedir/temp
    As you've noticed, directory name 'somedir' have been lost for the '~test.file' by 'file join' command
    
    DesiredBehavior:
    The output should be like this:
      somedir/tools
      somedir/Stuff
      somedir/~test.file
      somedir/temp
    
    
    
    The ~ is one of those chars that has to be handled separately, and
    with minor coding improvements you can make the above work without
    problems:
        foreach name [glob -nocomplain ./*] { puts [file join somedir $name] }
    
    or in 8.3:
        foreach name [glob -nocomplain -dir . *] { ... }
     
    -- 03/01/2000 hobbs
    
  4. foundin changed to: "obsolete: 8.3b2"
  5. priority changed to: "5 Medium"
  6. resolution changed to: "None"
  7. status changed to: "Open"
  8. submitter changed to: "nobody"
  9. subsystem changed to: "37. File System"
  10. title changed to: "problem with file names starting with tilde"
  11. type changed to: "Bug"