From 7a57b2920b7f04ab0cdd42687dd183217231549e Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Sun, 22 Mar 2009 17:51:45 +0000 Subject: [PATCH] * Better error message when nix-store --import is applied to garbage (previously it would likely say "implementation cannot deal with > 32-bit integers"). --- src/nix-store/nix-store.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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;