Changeset 1220


Ignore:
Timestamp:
15/12/2006 00:18:52 (5 years ago)
Author:
chris
Message:
  • Remove #ifdefs around geteuid(), re-enable use of fake version under Win32 as requested by Ben.

(merges [1080])

File:
1 edited

Legend:

Unmodified
Added
Removed
  • box/trunk/lib/backupclient/BackupClientFileAttributes.cpp

    r464 r1220  
    680680                // Work out times as timevals 
    681681                struct timeval times[2]; 
     682 
     683                #ifdef WIN32 
     684                BoxTimeToTimeval(box_ntoh64(pattr->ModificationTime),  
     685                        times[1]); 
     686                BoxTimeToTimeval(box_ntoh64(pattr->AttrModificationTime),  
     687                        times[0]); 
     688                // Because stat() returns the creation time in the ctime 
     689                // field under Windows, and this gets saved in the  
     690                // AttrModificationTime field of the serialised attributes, 
     691                // we subvert the first parameter of emu_utimes() to allow 
     692                // it to be reset to the right value on the restored file. 
     693                #else 
    682694                BoxTimeToTimeval(modtime, times[1]); 
    683695                // Copy access time as well, why not, got to set it to something 
    684696                times[0] = times[1]; 
    685                 // Attr modification time will be changed anyway, nothing that can be done about it 
     697                // Attr modification time will be changed anyway,  
     698                // nothing that can be done about it 
     699                #endif 
    686700                 
    687701                // Try to apply 
Note: See TracChangeset for help on using the changeset viewer.