Download Reference Manual
The Developer's Library for D
About Wiki Forums Source Search Contact

Changeset 3641

Show
Ignore:
Timestamp:
06/19/08 16:40:30 (3 months ago)
Author:
kris
Message:

oops, forgot about Win32SansUnicode

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/tango/io/FileConduit.d

    r3638 r3641  
    410410                        access = Access[style.access]; 
    411411 
     412                        // zero terminate the path 
     413                        char[512] zero = void; 
     414                        auto name = stdc.toStringz (path, zero); 
     415 
    412416                        version (Win32SansUnicode) 
    413                                  handle = CreateFileA (path.cString.ptr, access, share,  
     417                                 handle = CreateFileA (name, access, share,  
    414418                                                       null, create,  
    415419                                                       attr | FILE_ATTRIBUTE_NORMAL, 
     
    417421                             else 
    418422                                { 
    419                                 char[512] zero = void; 
     423                                // convert to utf16 
    420424                                wchar[512] convert = void; 
    421  
    422                                 // zero terminate and convert to utf16 
    423                                 auto name = stdc.toStringz (path, zero); 
    424425                                auto wide = Utf.toString16 (name[0..path.length+1], convert); 
    425426