chiark / gitweb /
errno is positive
[elogind.git] / src / libsystemd-bus / bus-kernel.c
index b53c5eddcbb2ad49546589030f84446febbdeb8a..b83dfcbc27bca1b37ecde52840b3302437d7b872 100644 (file)
@@ -339,7 +339,7 @@ int bus_kernel_read_message(sd_bus *bus, sd_bus_message **m) {
                 if (errno == EAGAIN)
                         return 0;
 
-                if (errno != -EMSGSIZE)
+                if (errno != EMSGSIZE)
                         return -errno;
 
                 sz *= 2;
@@ -378,7 +378,7 @@ int bus_kernel_create(const char *name, char **s) {
         if (!p)
                 return -ENOMEM;
 
-        if (ioctl(fd, KDBUS_CMD_BUS_MAKE, &fname) < 0) {
+        if (ioctl(fd, KDBUS_CMD_BUS_MAKE, fname) < 0) {
                 close_nointr_nofail(fd);
                 free(p);
                 return -errno;