chiark / gitweb /
Prep v239: Unmask cg_weight_parse()
[elogind.git] / src / basic / cgroup-util.c
index ad71e6e8a876f9dc72307df55621a52b44ff44a7..42395aae5deee34755facaf076e6166db2d94040 100644 (file)
@@ -1,7 +1,4 @@
 /* SPDX-License-Identifier: LGPL-2.1+ */
-/***
-  Copyright 2010 Lennart Poettering
-***/
 
 #include <dirent.h>
 #include <errno.h>
@@ -1810,7 +1807,7 @@ int cg_path_get_owner_uid(const char *path, uid_t *uid) {
 #else
         p = strappend("/run/systemd/sessions/", slice);
 
-        r = parse_env_file(p, NEWLINE, "UID", &s, NULL);
+        r = parse_env_file(NULL, p, NEWLINE, "UID", &s, NULL);
         if (r == -ENOENT)
                 return -ENXIO;
         if (r < 0)
@@ -2815,7 +2812,6 @@ bool cg_is_hybrid_wanted(void) {
 #endif // 0
 }
 
-#if 0 /// UNNEEDED by elogind
 int cg_weight_parse(const char *s, uint64_t *ret) {
         uint64_t u;
         int r;
@@ -2836,6 +2832,7 @@ int cg_weight_parse(const char *s, uint64_t *ret) {
         return 0;
 }
 
+#if 0 /// UNNEEDED by elogind
 const uint64_t cgroup_io_limit_defaults[_CGROUP_IO_LIMIT_TYPE_MAX] = {
         [CGROUP_IO_RBPS_MAX]    = CGROUP_LIMIT_MAX,
         [CGROUP_IO_WBPS_MAX]    = CGROUP_LIMIT_MAX,