about summary refs log tree commit diff
path: root/third_party/nix/src/libstore/local-store.cc
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/nix/src/libstore/local-store.cc')
-rw-r--r--third_party/nix/src/libstore/local-store.cc10
1 files changed, 6 insertions, 4 deletions
diff --git a/third_party/nix/src/libstore/local-store.cc b/third_party/nix/src/libstore/local-store.cc
index faea0fbce56a..ebc912969423 100644
--- a/third_party/nix/src/libstore/local-store.cc
+++ b/third_party/nix/src/libstore/local-store.cc
@@ -8,6 +8,7 @@
 #include <iostream>
 
 #include <absl/strings/numbers.h>
+#include <absl/strings/str_split.h>
 #include <fcntl.h>
 #include <glog/logging.h>
 #include <grp.h>
@@ -477,14 +478,15 @@ static void canonicalisePathMetaData_(const Path& path, uid_t fromUid,
       throw SysError("querying extended attributes of '%s'", path);
     }
 
-    for (auto& eaName : tokenizeString<Strings>(
-             std::string(eaBuf.data(), eaSize), std::string("\000", 1))) {
+    for (auto& eaName :
+         absl::StrSplit(std::string(eaBuf.data(), eaSize),
+                        absl::ByString(std::string("\000", 1)))) {
       /* Ignore SELinux security labels since these cannot be
          removed even by root. */
       if (eaName == "security.selinux") {
         continue;
       }
-      if (lremovexattr(path.c_str(), eaName.c_str()) == -1) {
+      if (lremovexattr(path.c_str(), std::string(eaName).c_str()) == -1) {
         throw SysError("removing extended attribute '%s' from '%s'", eaName,
                        path);
       }
@@ -702,7 +704,7 @@ void LocalStore::queryPathInfoUncached(
 
       s = (const char*)sqlite3_column_text(state->stmtQueryPathInfo, 6);
       if (s != nullptr) {
-        info->sigs = tokenizeString<StringSet>(s, " ");
+        info->sigs = absl::StrSplit(s, absl::ByChar(' '));
       }
 
       s = (const char*)sqlite3_column_text(state->stmtQueryPathInfo, 7);