about summary refs log tree commit diff
path: root/src/nix-setuid-helper/nix-setuid-helper.cc
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2012-09-25T19·38-0400
committerEelco Dolstra <eelco.dolstra@logicblox.com>2012-09-25T19·38-0400
commite464b0247d9dd2c53770a851956dd34f82b7c9a6 (patch)
tree75517243f3ce6c5facd3e2424fefbaeeaaad1af1 /src/nix-setuid-helper/nix-setuid-helper.cc
parent28bf183d2d2f775e653efe4cee98d7359ce65455 (diff)
parentb9c2b4d5b4cd5d52a950e6dd90eb2e2e79891fa0 (diff)
Merge branch 'readonly-store'
Diffstat (limited to 'src/nix-setuid-helper/nix-setuid-helper.cc')
-rw-r--r--src/nix-setuid-helper/nix-setuid-helper.cc7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/nix-setuid-helper/nix-setuid-helper.cc b/src/nix-setuid-helper/nix-setuid-helper.cc
index 26c457fd93c3..697964088c2a 100644
--- a/src/nix-setuid-helper/nix-setuid-helper.cc
+++ b/src/nix-setuid-helper/nix-setuid-helper.cc
@@ -193,16 +193,15 @@ static void run(int argc, char * * argv)
     if (st.st_mode & (S_IWGRP | S_IWOTH))
         throw Error(format("`%1%' should not be group or world-writable") % configFile);
 
-    Strings tokens = tokenizeString(readFile(fdConfig));
+    vector<string> tokens = tokenizeString<vector<string> >(readFile(fdConfig));
 
     fdConfig.close();
 
     if (tokens.size() != 2)
         throw Error(format("parse error in `%1%'") % configFile);
 
-    Strings::iterator i = tokens.begin();
-    string nixUser = *i++;
-    string buildUsersGroup = *i++;
+    string nixUser = tokens[0];
+    string buildUsersGroup = tokens[1];
 
 
     /* Check that the caller (real uid) is the one allowed to call