about summary refs log tree commit diff
path: root/third_party/nix/src/libstore/remote-fs-accessor.cc
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/nix/src/libstore/remote-fs-accessor.cc')
-rw-r--r--third_party/nix/src/libstore/remote-fs-accessor.cc6
1 files changed, 2 insertions, 4 deletions
diff --git a/third_party/nix/src/libstore/remote-fs-accessor.cc b/third_party/nix/src/libstore/remote-fs-accessor.cc
index d5b20288479c..2917f01f7939 100644
--- a/third_party/nix/src/libstore/remote-fs-accessor.cc
+++ b/third_party/nix/src/libstore/remote-fs-accessor.cc
@@ -75,14 +75,12 @@ std::pair<ref<FSAccessor>, Path> RemoteFSAccessor::fetch(const Path& path_) {
               throw SysError("opening NAR cache file '%s'", cacheFile);
             }
 
-            if (lseek(fd.get(), offset, SEEK_SET) !=
-                static_cast<off_t>(offset)) {
+            if (lseek(fd.get(), offset, SEEK_SET) != (off_t)offset) {
               throw SysError("seeking in '%s'", cacheFile);
             }
 
             std::string buf(length, 0);
-            readFull(fd.get(), reinterpret_cast<unsigned char*>(buf.data()),
-                     length);
+            readFull(fd.get(), (unsigned char*)buf.data(), length);
 
             return buf;
           });