chiark / gitweb /
job: when cancelling jobs, make sure to propagate this properly to depending jobs
[elogind.git] / src / dbus-job.c
index 16aa8d071eb18dfa3f1b4f8a5c17c5615f168dd2..2a33039bdb23a95eb50b65ce5e0e022a96d3603c 100644 (file)
@@ -97,7 +97,7 @@ static DBusHandlerResult bus_job_message_dispatch(Job *j, DBusConnection *connec
                 if (!(reply = dbus_message_new_method_return(message)))
                         goto oom;
 
-                job_free(j);
+                job_finish_and_invalidate(j, JOB_CANCELED);
 
         } else
                 return bus_default_message_handler(j->manager, connection, message, INTROSPECTION, properties);