bus: make reference counting non-atomic
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 1 Mar 2019 11:43:12 +0000 (12:43 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Mon, 4 Mar 2019 13:16:24 +0000 (14:16 +0100)
commit42541a71a2c9560fe37fbef37b868bb53b53aef4
treede94866f9fec6af0b88c4750cbf85c526b3a441b
parentf68a26221c3bb93be2841bfcaaaaae5bf0db64ee
bus: make reference counting non-atomic

We had atomic counters, but all other operations were non-serialized. This
means that concurrent access to the bus object was only safe if _all_ threads
were doing read-only access. Even sending of messages from threads would not be
possible, because after sending of the message we usually want to remove it
from the send queue in the bus object, which would race. Let's just kill this.
src/libsystemd/sd-bus/bus-internal.h
src/libsystemd/sd-bus/sd-bus.c
src/libsystemd/sd-bus/test-bus-cleanup.c