diff options
Diffstat (limited to 'src/nix-store/main.cc')
-rw-r--r-- | src/nix-store/main.cc | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/nix-store/main.cc b/src/nix-store/main.cc index 51e587255003..ed93f2065790 100644 --- a/src/nix-store/main.cc +++ b/src/nix-store/main.cc @@ -170,7 +170,6 @@ static void opSubstitute(Strings opFlags, Strings opArgs) if (!opArgs.empty()) throw UsageError("no arguments expected"); - SubstitutePairs subPairs; Transaction txn; createStoreTransaction(txn); @@ -196,12 +195,10 @@ static void opSubstitute(Strings opFlags, Strings opArgs) references.insert(s); } if (!cin || cin.eof()) throw Error("missing input"); - subPairs.push_back(pair<Path, Substitute>(srcPath, sub)); + registerSubstitute(txn, srcPath, sub); setReferences(txn, srcPath, references); } - registerSubstitutes(txn, subPairs); - txn.commit(); } |