chiark / gitweb /
bus: properly return an error when we detect a method call timeout
authorLennart Poettering <lennart@poettering.net>
Thu, 12 Dec 2013 04:29:56 +0000 (05:29 +0100)
committerLennart Poettering <lennart@poettering.net>
Thu, 12 Dec 2013 04:40:05 +0000 (05:40 +0100)
src/libsystemd-bus/sd-bus.c

index edd917e..37408cf 100644 (file)
@@ -1754,6 +1754,8 @@ _public_ int sd_bus_call(
                 r = bus_poll(bus, true, left);
                 if (r < 0)
                         return r;
+                if (r == 0)
+                        return -ETIMEDOUT;
 
                 r = dispatch_wqueue(bus);
                 if (r < 0) {