summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/libsystemd/libsystemd.sym8
-rw-r--r--src/libsystemd/sd-bus/bus-control.c2
-rw-r--r--src/libsystemd/sd-bus/bus-message.c21
-rw-r--r--src/systemd/sd-bus.h8
4 files changed, 20 insertions, 19 deletions
diff --git a/src/libsystemd/libsystemd.sym b/src/libsystemd/libsystemd.sym
index 984bc155a9..e2e917e00e 100644
--- a/src/libsystemd/libsystemd.sym
+++ b/src/libsystemd/libsystemd.sym
@@ -85,8 +85,8 @@ global:
sd_bus_message_get_type;
sd_bus_message_get_cookie;
sd_bus_message_get_reply_cookie;
- sd_bus_message_get_no_reply;
- sd_bus_message_get_no_auto_start;
+ sd_bus_message_get_expect_reply;
+ sd_bus_message_get_auto_start;
sd_bus_message_get_priority;
sd_bus_message_get_signature;
sd_bus_message_get_path;
@@ -103,8 +103,8 @@ global:
sd_bus_message_is_signal;
sd_bus_message_is_method_call;
sd_bus_message_is_method_error;
- sd_bus_message_set_no_reply;
- sd_bus_message_set_no_auto_start;
+ sd_bus_message_set_expect_reply;
+ sd_bus_message_set_auto_start;
sd_bus_message_set_destination;
sd_bus_message_set_priority;
sd_bus_message_append;
diff --git a/src/libsystemd/sd-bus/bus-control.c b/src/libsystemd/sd-bus/bus-control.c
index 5548239426..61cdf2249e 100644
--- a/src/libsystemd/sd-bus/bus-control.c
+++ b/src/libsystemd/sd-bus/bus-control.c
@@ -1214,7 +1214,7 @@ _public_ int sd_bus_get_owner_machine_id(sd_bus *bus, const char *name, sd_id128
if (r < 0)
return r;
- r = sd_bus_message_set_no_auto_start(m, true);
+ r = sd_bus_message_set_auto_start(m, false);
if (r < 0)
return r;
diff --git a/src/libsystemd/sd-bus/bus-message.c b/src/libsystemd/sd-bus/bus-message.c
index b42c4915ea..4e95226c5d 100644
--- a/src/libsystemd/sd-bus/bus-message.c
+++ b/src/libsystemd/sd-bus/bus-message.c
@@ -831,16 +831,17 @@ _public_ int sd_bus_message_get_reply_cookie(sd_bus_message *m, uint64_t *cookie
return 0;
}
-_public_ int sd_bus_message_get_no_reply(sd_bus_message *m) {
+_public_ int sd_bus_message_get_expect_reply(sd_bus_message *m) {
assert_return(m, -EINVAL);
- return m->header->type == SD_BUS_MESSAGE_METHOD_CALL ? !!(m->header->flags & BUS_MESSAGE_NO_REPLY_EXPECTED) : 0;
+ return m->header->type == SD_BUS_MESSAGE_METHOD_CALL &&
+ !(m->header->flags & BUS_MESSAGE_NO_REPLY_EXPECTED);
}
-_public_ int sd_bus_message_get_no_auto_start(sd_bus_message *m) {
+_public_ int sd_bus_message_get_auto_start(sd_bus_message *m) {
assert_return(m, -EINVAL);
- return !!(m->header->flags & BUS_MESSAGE_NO_AUTO_START);
+ return !(m->header->flags & BUS_MESSAGE_NO_AUTO_START);
}
_public_ const char *sd_bus_message_get_path(sd_bus_message *m) {
@@ -968,27 +969,27 @@ _public_ int sd_bus_message_is_method_error(sd_bus_message *m, const char *name)
return 1;
}
-_public_ int sd_bus_message_set_no_reply(sd_bus_message *m, int b) {
+_public_ int sd_bus_message_set_expect_reply(sd_bus_message *m, int b) {
assert_return(m, -EINVAL);
assert_return(!m->sealed, -EPERM);
assert_return(m->header->type == SD_BUS_MESSAGE_METHOD_CALL, -EPERM);
if (b)
- m->header->flags |= BUS_MESSAGE_NO_REPLY_EXPECTED;
- else
m->header->flags &= ~BUS_MESSAGE_NO_REPLY_EXPECTED;
+ else
+ m->header->flags |= BUS_MESSAGE_NO_REPLY_EXPECTED;
return 0;
}
-_public_ int sd_bus_message_set_no_auto_start(sd_bus_message *m, int b) {
+_public_ int sd_bus_message_set_auto_start(sd_bus_message *m, int b) {
assert_return(m, -EINVAL);
assert_return(!m->sealed, -EPERM);
if (b)
- m->header->flags |= BUS_MESSAGE_NO_AUTO_START;
- else
m->header->flags &= ~BUS_MESSAGE_NO_AUTO_START;
+ else
+ m->header->flags |= BUS_MESSAGE_NO_AUTO_START;
return 0;
}
diff --git a/src/systemd/sd-bus.h b/src/systemd/sd-bus.h
index 01f6275c4b..52481c6fcf 100644
--- a/src/systemd/sd-bus.h
+++ b/src/systemd/sd-bus.h
@@ -192,8 +192,8 @@ sd_bus* sd_bus_message_get_bus(sd_bus_message *m);
int sd_bus_message_get_type(sd_bus_message *m, uint8_t *type);
int sd_bus_message_get_cookie(sd_bus_message *m, uint64_t *cookie);
int sd_bus_message_get_reply_cookie(sd_bus_message *m, uint64_t *cookie);
-int sd_bus_message_get_no_reply(sd_bus_message *m);
-int sd_bus_message_get_no_auto_start(sd_bus_message *m);
+int sd_bus_message_get_expect_reply(sd_bus_message *m);
+int sd_bus_message_get_auto_start(sd_bus_message *m);
int sd_bus_message_get_priority(sd_bus_message *m, int64_t *priority);
const char *sd_bus_message_get_signature(sd_bus_message *m, int complete);
@@ -215,8 +215,8 @@ int sd_bus_message_is_signal(sd_bus_message *m, const char *interface, const cha
int sd_bus_message_is_method_call(sd_bus_message *m, const char *interface, const char *member);
int sd_bus_message_is_method_error(sd_bus_message *m, const char *name);
-int sd_bus_message_set_no_reply(sd_bus_message *m, int b);
-int sd_bus_message_set_no_auto_start(sd_bus_message *m, int b);
+int sd_bus_message_set_expect_reply(sd_bus_message *m, int b);
+int sd_bus_message_set_auto_start(sd_bus_message *m, int b);
int sd_bus_message_set_destination(sd_bus_message *m, const char *destination);
int sd_bus_message_set_priority(sd_bus_message *m, int64_t priority);