1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-06 21:41:48 +02:00

* Don't use ULLONG_MAX in maxFreed - use 0 to mean "no limit".

18446744073709551615ULL breaks on GCC 3.3.6 (`integer constant is
  too large for "long" type').
This commit is contained in:
Eelco Dolstra 2009-03-26 11:02:07 +00:00
parent 92f525ecf4
commit 5dd8fb2069
4 changed files with 8 additions and 10 deletions

View file

@ -531,7 +531,10 @@ static void opGC(Strings opFlags, Strings opArgs)
else if (*i == "--print-live") options.action = GCOptions::gcReturnLive;
else if (*i == "--print-dead") options.action = GCOptions::gcReturnDead;
else if (*i == "--delete") options.action = GCOptions::gcDeleteDead;
else if (*i == "--max-freed") options.maxFreed = getIntArg(*i, i, opFlags.end());
else if (*i == "--max-freed") {
options.maxFreed = getIntArg(*i, i, opFlags.end());
if (options.maxFreed == 0) options.maxFreed = 1;
}
else if (*i == "--max-links") options.maxLinks = getIntArg(*i, i, opFlags.end());
else if (*i == "--use-atime") options.useAtime = true;
else if (*i == "--max-atime") {