1
0
mirror of https://github.com/systemd/systemd.git synced 2024-10-28 11:55:44 +03:00

bus-message: drop asserts in functions which are wrappers for varargs version

The function does no processing on it's own, and just forwards arguments
to the other function. Let's just use the asserts there.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek 2018-08-03 16:36:51 +02:00
parent f88214cf9d
commit 8792bdf8a3

View File

@ -2444,11 +2444,6 @@ _public_ int sd_bus_message_append(sd_bus_message *m, const char *types, ...) {
va_list ap;
int r;
assert_return(m, -EINVAL);
assert_return(types, -EINVAL);
assert_return(!m->sealed, -EPERM);
assert_return(!m->poisoned, -ESTALE);
va_start(ap, types);
r = sd_bus_message_appendv(m, types, ap);
va_end(ap);
@ -4501,10 +4496,6 @@ _public_ int sd_bus_message_read(sd_bus_message *m, const char *types, ...) {
va_list ap;
int r;
assert_return(m, -EINVAL);
assert_return(m->sealed, -EPERM);
assert_return(types, -EINVAL);
va_start(ap, types);
r = sd_bus_message_readv(m, types, ap);
va_end(ap);