Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: fe267afbff0b8ad118d1d99d43f75b621157276f
Ticket: 3463315fffffffffffffffffffffffffffffffff
file normalize breaks C:/Windows/system32/drivers/etc/hosts
User & Date: zoro2 on 2011-12-21 19:56:08
Changes

  1. icomment:
    Small update - changing WOW64 seems to resolve the issue - previous example did not show it as I ran it in same process (and Tcl caches file normalize results):
    
    % package require twapi ; ::twapi::Wow64EnableWow64FsRedirection 0
    % file normalize C:/Windows/system32/drivers/etc/hosts
    C:/Windows/System32/drivers/etc/hosts
    
    And in a new process:
    
    % package require twapi ; ::twapi::Wow64EnableWow64FsRedirection 1
    % file normalize C:/Windows/system32/drivers/etc/hosts
    C:/Windows/System32/drivers//hosts
    
    So this seems to be an issue with how Windows handles drivers\etc in WOW64 mode.
    
    Also, when WOW64 is enabled:
    
    % glob C:/Windows/system32/drivers/etc
    C:/Windows/system32/drivers/etc
    % glob C:/Windows/system32/drivers/e*
    C:/Windows/system32/drivers/en-US
    % glob -type hidden C:/Windows/system32/drivers/e*
    no files matched glob pattern "C:/Windows/system32/drivers/e*"
    
    So it may be an issue the file is not visible when listing contents of directory.
    
    With WOW64 disabled:
    
    % glob C:/Windows/system32/drivers/et*
    C:/Windows/system32/drivers/etc
    
    
    
  2. login: "zoro2"
  3. mimetype: "text/plain"
  4. username: "zoro2"