(5) fix foo_mem_clean() functions to avoid race cond.
authorkremlin <ian@kremlin.cc>
Tue, 5 Aug 2014 02:18:51 +0000 (21:18 -0500)
committerkremlin <ian@kremlin.cc>
Tue, 5 Aug 2014 02:18:51 +0000 (21:18 -0500)
commit341587dbd94b8845b91baef896d9da2693df19bb
tree1caa4744472945fa20d75942b34c7d281c9f80b5
parent509599f043fd77c5eee595ebce117ff9e11a5324
(5) fix foo_mem_clean() functions to avoid race cond.

mem_clean functions previously free()'d our pointer array without
first checking that the name/interface had properly been unexported from
dbus. checking first better guarantees all operations implicating that date
have ceased, and that it is safe to go ahead and stop the GMainLoop before
immediately returning. this causes the code just after the main_loop_begin()
call to start functioning, in our case the actual free() calls (which are now
*absolutley* safe to call)
src/interfaces/localed/localed.c
src/interfaces/logind/logind.c
src/interfaces/timedated/timedated.c