diff --git a/src/libstore/local-store.cc b/src/libstore/local-store.cc index 56f8c5dd8..1bbeaa912 100644 --- a/src/libstore/local-store.cc +++ b/src/libstore/local-store.cc @@ -1202,7 +1202,7 @@ StorePath LocalStore::addToStoreFromDump( Path tempDir; AutoCloseFD tempDirFd; - bool methodsMatch = (FileIngestionMethod) dumpMethod == hashMethod; + bool methodsMatch = ContentAddressMethod(FileIngestionMethod(dumpMethod)) == hashMethod; /* If the methods don't match, our streaming hash of the dump is the wrong sort, and we need to rehash. */