chiark / gitweb /
tree-wide: use path_hash_ops instead of string_hash_ops whenever we key by a path
authorLennart Poettering <lennart@poettering.net>
Thu, 8 Feb 2018 17:58:35 +0000 (18:58 +0100)
committerSven Eden <yamakuzure@gmx.net>
Wed, 30 May 2018 05:58:53 +0000 (07:58 +0200)
Let's make use of our new hash_ops!

src/basic/mount-util.c
src/login/logind-acl.c

index 03e1b9a427307d759454ed692272fde09285c269..8b480bbeb9b6b854c58dd9f2ce8348909b892e0f 100644 (file)
@@ -427,7 +427,7 @@ int bind_remount_recursive_with_mountinfo(const char *prefix, bool ro, char **bl
 
         path_kill_slashes(cleaned);
 
-        done = set_new(&string_hash_ops);
+        done = set_new(&path_hash_ops);
         if (!done)
                 return -ENOMEM;
 
@@ -437,7 +437,7 @@ int bind_remount_recursive_with_mountinfo(const char *prefix, bool ro, char **bl
                 char *x;
                 unsigned long orig_flags;
 
-                todo = set_new(&string_hash_ops);
+                todo = set_new(&path_hash_ops);
                 if (!todo)
                         return -ENOMEM;
 
index d785f67ca31021e0aaf12088b5ec710a938d45e9..3f355e7ea80213df53894da97c1ff3589e119f7b 100644 (file)
@@ -192,7 +192,7 @@ int devnode_acl_all(struct udev *udev,
 
         assert(udev);
 
-        nodes = set_new(&string_hash_ops);
+        nodes = set_new(&path_hash_ops);
         if (!nodes)
                 return -ENOMEM;