chiark / gitweb /
sd-bus: react properly to EOVERFLOW by generating a log message about dropped broadca...
authorLennart Poettering <lennart@poettering.net>
Tue, 25 Nov 2014 18:54:18 +0000 (19:54 +0100)
committerLennart Poettering <lennart@poettering.net>
Tue, 25 Nov 2014 19:42:31 +0000 (20:42 +0100)
src/libsystemd/sd-bus/bus-kernel.c

index 0927d82..e03e447 100644 (file)
@@ -1185,6 +1185,11 @@ int bus_kernel_read_message(sd_bus *bus, bool hint_priority, int64_t priority) {
                 if (errno == EAGAIN)
                         return 0;
 
+                if (errno == EOVERFLOW) {
+                        log_debug("%s: kdbus reports %" PRIu64 " dropped broadcast messages, ignoring.", strna(bus->description), (uint64_t) recv.dropped_msgs);
+                        return 0;
+                }
+
                 return -errno;
         }