chiark / gitweb /
sd-event: return 'r' rather than '-errno'
authorTom Gundersen <teg@jklm.no>
Fri, 15 Aug 2014 17:15:30 +0000 (19:15 +0200)
committerTom Gundersen <teg@jklm.no>
Fri, 15 Aug 2014 18:32:27 +0000 (20:32 +0200)
src/libsystemd/sd-event/sd-event.c

index 3a9d934..7917ab9 100644 (file)
@@ -779,7 +779,7 @@ _public_ int sd_event_add_io(
         r = source_io_register(s, s->enabled, events);
         if (r < 0) {
                 source_free(s);
-                return -errno;
+                return r;
         }
 
         if (ret)
@@ -1060,7 +1060,7 @@ _public_ int sd_event_add_child(
                 r = event_update_signal_fd(e);
                 if (r < 0) {
                         source_free(s);
-                        return -errno;
+                        return r;
                 }
         }