Changeset 1291 for trunk


Ignore:
Timestamp:
Nov 12, 2010, 5:13:26 AM (11 years ago)
Author:
Peter Johansson
Message:

fixes #263. copy_file now copies permissions too.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/utility.cc

    r1253 r1291  
    103103                               "error reading source file '" + source + "'");
    104104    i.close(); o.close();
     105    // copy permissions
     106    struct stat nodestat;
     107    stat(source.c_str(),&nodestat);   
     108    chmod(target.c_str(), nodestat.st_mode);
    105109  }
    106110
Note: See TracChangeset for help on using the changeset viewer.