chiark / gitweb /
api: in constructor function calls, always put the returned object pointer first...
[elogind.git] / src / journal / journald-native.c
index 5e19fa3f55ef8a8a1be0910c8a8c0277024ea0fe..359d962c72cb5d42a0a39b85c45d91d33dc9af10 100644 (file)
@@ -419,7 +419,7 @@ int server_open_native_socket(Server*s) {
                 return -errno;
         }
 
-        r = sd_event_add_io(s->event, s->native_fd, EPOLLIN, process_datagram, s, &s->native_event_source);
+        r = sd_event_add_io(s->event, &s->native_event_source, s->native_fd, EPOLLIN, process_datagram, s);
         if (r < 0) {
                 log_error("Failed to add native server fd to event loop: %s", strerror(-r));
                 return r;