1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2024-10-30 14:55:26 +03:00

bus: properly check if kdbus connection worked

This commit is contained in:
Lennart Poettering 2013-04-12 00:43:29 +02:00
parent de2975759d
commit c320885c9f

View File

@ -175,7 +175,7 @@ int bus_kernel_connect(sd_bus *b) {
assert(b->kernel); assert(b->kernel);
b->input_fd = open(b->kernel, O_RDWR|O_NOCTTY|O_CLOEXEC); b->input_fd = open(b->kernel, O_RDWR|O_NOCTTY|O_CLOEXEC);
if (b->input_fd) if (b->input_fd < 0)
return -errno; return -errno;
b->output_fd = b->input_fd; b->output_fd = b->input_fd;