diff options
Diffstat (limited to 'third_party/nix/src/libstore/nar-accessor.cc')
-rw-r--r-- | third_party/nix/src/libstore/nar-accessor.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/third_party/nix/src/libstore/nar-accessor.cc b/third_party/nix/src/libstore/nar-accessor.cc index ac286374b8bd..3a8d6b884104 100644 --- a/third_party/nix/src/libstore/nar-accessor.cc +++ b/third_party/nix/src/libstore/nar-accessor.cc @@ -132,7 +132,7 @@ struct NarAccessor : public FSAccessor { } NarMember* find(const Path& path) { - Path canon = path == "" ? "" : canonPath(path); + Path canon = path.empty() ? "" : canonPath(path); NarMember* current = &root; auto end = path.end(); for (auto it = path.begin(); it != end;) { @@ -238,7 +238,7 @@ void listNar(JSONPlaceholder& res, ref<FSAccessor> accessor, const Path& path, if (st.isExecutable) { obj.attr("executable", true); } - if (st.narOffset) { + if (st.narOffset != 0u) { obj.attr("narOffset", st.narOffset); } break; |