about summary refs log tree commit diff
path: root/src/nix/verify.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/nix/verify.cc')
-rw-r--r--src/nix/verify.cc16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/nix/verify.cc b/src/nix/verify.cc
index 39a4395cfe5b..da15678088d0 100644
--- a/src/nix/verify.cc
+++ b/src/nix/verify.cc
@@ -83,16 +83,16 @@ struct CmdVerify : StorePathsCommand
 
                 if (!noContents) {
 
-                    HashSink sink(info.narHash.type);
+                    HashSink sink(info->narHash.type);
                     store->narFromPath(storePath, sink);
 
                     auto hash = sink.finish();
 
-                    if (hash.first != info.narHash) {
+                    if (hash.first != info->narHash) {
                         corrupted = 1;
                         printMsg(lvlError,
                             format("path ‘%s’ was modified! expected hash ‘%s’, got ‘%s’")
-                            % storePath % printHash(info.narHash) % printHash(hash.first));
+                            % storePath % printHash(info->narHash) % printHash(hash.first));
                     }
 
                 }
@@ -101,7 +101,7 @@ struct CmdVerify : StorePathsCommand
 
                     bool good = false;
 
-                    if (info.ultimate && !sigsNeeded)
+                    if (info->ultimate && !sigsNeeded)
                         good = true;
 
                     else {
@@ -114,18 +114,18 @@ struct CmdVerify : StorePathsCommand
                             for (auto sig : sigs) {
                                 if (sigsSeen.count(sig)) continue;
                                 sigsSeen.insert(sig);
-                                if (info.checkSignature(publicKeys, sig))
+                                if (info->checkSignature(publicKeys, sig))
                                     validSigs++;
                             }
                         };
 
-                        doSigs(info.sigs);
+                        doSigs(info->sigs);
 
                         for (auto & store2 : substituters) {
                             if (validSigs >= actualSigsNeeded) break;
                             try {
-                                if (!store2->isValidPath(storePath)) continue;
-                                doSigs(store2->queryPathInfo(storePath).sigs);
+                                doSigs(store2->queryPathInfo(storePath)->sigs);
+                            } catch (InvalidPath &) {
                             } catch (Error & e) {
                                 printMsg(lvlError, format(ANSI_RED "error:" ANSI_NORMAL " %s") % e.what());
                             }