From 333f4963de6d174d852774a88ada852f77f57994 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 8 Jul 2003 15:33:06 +0000 Subject: [PATCH] * The output of a Derive() node is not a referenced path. --- src/fstate.cc | 2 -- src/nix.cc | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/src/fstate.cc b/src/fstate.cc index fa677a257..731493fd3 100644 --- a/src/fstate.cc +++ b/src/fstate.cc @@ -359,8 +359,6 @@ void fstateRefs2(FState fs, StringSet & paths) else if (ATmatch(fs, "Derive(, , [], , [])", &s1, &s2, &ins, &s3, &e2)) { - paths.insert(s3); - while (!ATisEmpty(ins)) { fstateRefs2(ATgetFirst(ins), paths); ins = ATgetNext(ins); diff --git a/src/nix.cc b/src/nix.cc index ec4c91788..f3549ead8 100644 --- a/src/nix.cc +++ b/src/nix.cc @@ -160,7 +160,7 @@ static void opQuery(Strings opFlags, Strings opArgs) break; case qRefs: { - Strings refs = fstateRefs(termFromHash(hash)); + Strings refs = fstateRefs(realiseFState(termFromHash(hash))); for (Strings::iterator j = refs.begin(); j != refs.end(); j++) cout << format("%s\n") % *j;