diff options
Diffstat (limited to 'src/libstore/local-store.cc')
-rw-r--r-- | src/libstore/local-store.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libstore/local-store.cc b/src/libstore/local-store.cc index bae5fad7b..5bdf0362d 100644 --- a/src/libstore/local-store.cc +++ b/src/libstore/local-store.cc @@ -907,7 +907,7 @@ std::shared_ptr<const ValidPathInfo> LocalStore::queryPathInfoInternal(State & s try { narHash = Hash::parseAnyPrefixed(useQueryPathInfo.getStr(1)); } catch (BadHash & e) { - throw Error("invalid-path entry for '%s': %s", printStorePath(path), e.what()); + throw BadStorePath("bad hash in store path '%s': %s", printStorePath(path), e.what()); } auto info = std::make_shared<ValidPathInfo>(path, narHash); @@ -957,8 +957,8 @@ void LocalStore::updatePathInfo(State & state, const ValidPathInfo & info) uint64_t LocalStore::queryValidPathId(State & state, const StorePath & path) { auto use(state.stmts->QueryPathInfo.use()(printStorePath(path))); - if (!use.next()) - throw InvalidPath("path '%s' is not valid", printStorePath(path)); + if (!use.next()) // TODO: I guess if SQLITE got corrupted..? + throw InvalidPath("path '%s' does not exist", printStorePath(path)); return use.getInt(0); } |