summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorEvgeny Vereshchagin <evvers@ya.ru>2017-02-12 08:38:16 +0300
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2017-02-12 00:38:16 -0500
commit0d7578dc30b9c9e8eb213e517d4928f222764a44 (patch)
treeb6a7c92a15b18df213b63fb6ecbf352e5a72f3db /src
parentb9e2d822d0b6bf7972a9b9f5ca26b65ea5b0b293 (diff)
shared: pass *unsigned_long to namespace_flag_from_string_many (#5315)
Fixes: ``` src/shared/bus-unit-util.c: In function ‘bus_append_unit_property_assignment’: src/shared/bus-unit-util.c:570:65: warning: passing argument 2 of ‘namespace_flag_from_string_many’ from incompatible pointer type [-Wincompatible-pointer-types] r = namespace_flag_from_string_many(eq, &flags); ^ In file included from src/shared/bus-unit-util.c:31:0: src/shared/nsflags.h:41:5: note: expected ‘long unsigned int *’ but argument is of type ‘uint64_t * {aka long long unsigned int *}’ int namespace_flag_from_string_many(const char *name, unsigned long *ret); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` Closes #5312
Diffstat (limited to 'src')
-rw-r--r--src/shared/bus-unit-util.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/shared/bus-unit-util.c b/src/shared/bus-unit-util.c
index 17c67221a0..4ca614f647 100644
--- a/src/shared/bus-unit-util.c
+++ b/src/shared/bus-unit-util.c
@@ -554,7 +554,7 @@ int bus_append_unit_property_assignment(sd_bus_message *m, const char *assignmen
} else if (streq(field, "RestrictNamespaces")) {
bool invert = false;
- uint64_t flags = 0;
+ unsigned long flags = 0;
if (eq[0] == '~') {
invert = true;
@@ -575,7 +575,7 @@ int bus_append_unit_property_assignment(sd_bus_message *m, const char *assignmen
if (invert)
flags = (~flags) & NAMESPACE_FLAGS_ALL;
- r = sd_bus_message_append(m, "v", "t", flags);
+ r = sd_bus_message_append(m, "v", "t", (uint64_t) flags);
} else if ((dep = unit_dependency_from_string(field)) >= 0)
r = sd_bus_message_append(m, "v", "as", 1, eq);
else if (streq(field, "MountFlags")) {