aboutsummaryrefslogtreecommitdiff
path: root/src/nix-store/nix-store.cc
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2009-03-22 17:51:45 +0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2009-03-22 17:51:45 +0000
commit7a57b2920b7f04ab0cdd42687dd183217231549e (patch)
treefa2e804fcab905ca2dd92c10dbeb4b0a909c654e /src/nix-store/nix-store.cc
parent77d272623fb4fd57cf27d4b92a7dc1713a2d4098 (diff)
* Better error message when nix-store --import is applied to garbage
(previously it would likely say "implementation cannot deal with > 32-bit integers").
Diffstat (limited to 'src/nix-store/nix-store.cc')
-rw-r--r--src/nix-store/nix-store.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nix-store/nix-store.cc b/src/nix-store/nix-store.cc
index 4a70d870a..28cd1adf4 100644
--- a/src/nix-store/nix-store.cc
+++ b/src/nix-store/nix-store.cc
@@ -625,7 +625,7 @@ static void opImport(Strings opFlags, Strings opArgs)
FdSource source(STDIN_FILENO);
while (true) {
- int n = readInt(source);
+ unsigned long long n = readLongLong(source);
if (n == 0) break;
if (n != 1) throw Error("input doesn't look like something created by `nix-store --export'");
cout << format("%1%\n") % store->importPath(requireSignature, source) << std::flush;