forked from lix-project/lix
* Remove write permission from store objects after they have been
added to the store. Bug reported by Martin.
This commit is contained in:
parent
47f87072ad
commit
c16be6ac92
|
@ -448,6 +448,8 @@ Path addToStore(const Path & _srcPath)
|
|||
|
||||
copyPath(srcPath, dstPath);
|
||||
|
||||
makePathReadOnly(dstPath);
|
||||
|
||||
Transaction txn(nixDB);
|
||||
registerValidPath(txn, dstPath);
|
||||
txn.commit();
|
||||
|
@ -476,6 +478,8 @@ void addTextToStore(const Path & dstPath, const string & s)
|
|||
|
||||
writeStringToFile(dstPath, s);
|
||||
|
||||
makePathReadOnly(dstPath);
|
||||
|
||||
Transaction txn(nixDB);
|
||||
registerValidPath(txn, dstPath);
|
||||
txn.commit();
|
||||
|
|
Loading…
Reference in a new issue