GDBusConnection: check for initializedness in most public API
authorSimon McVittie <simon.mcvittie@collabora.co.uk>
Wed, 19 Oct 2011 16:23:30 +0000 (17:23 +0100)
committerSimon McVittie <simon.mcvittie@collabora.co.uk>
Fri, 21 Oct 2011 15:02:33 +0000 (16:02 +0100)
commit848df03e16e190eddf1ee63733d85f687b65bdf9
tree16418ef4a4151a4aa39a71656c26c5a833656ed0
parent3958a9fc1ef99b474373415d5d46d596293764f6
GDBusConnection: check for initializedness in most public API

The only exceptions are those of the trivial getters/setters that don't
already need the initialization check for its secondary role as a memory
barrier (this is consistent with GSocket, where trivial getters/setters
don't check):

* g_dbus_connection_set_exit_on_close
* g_dbus_connection_get_exit_on_close
* g_dbus_connection_is_closed

g_dbus_connection_set_exit_on_close needs to be safe for
use before initialization anyway, so it can be set at construct-time.

Bug: https://bugzilla.gnome.org/show_bug.cgi?id=661689
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Reviewed-by: David Zeuthen <davidz@redhat.com>
gio/gdbusconnection.c