glib/gio/tests
David Zeuthen 3c4d3dec09 GDBusConnection: Make pending calls error when the connection is lost
If the connection to the bus is lost while a method call is ongoing,
the method call does not get cancelled. Instead it just sits around
until it times out.

This is visible here on XO laptops when stopping the display manager
during shutdown. imsettings starts sending a sync message to give up
its bus name (via g_bus_unown_name()), then systemd terminates the
session bus at approximately the same time. imsettings then hangs for
about 20 seconds before timing out the message.

 http://lists.freedesktop.org/archives/dbus/2011-September/014717.html

imsettings behaviour could be improved as described in that thread,
but I think this is a glib bug. I've also come up with the attached
patch which fixes it.

Credits for the bug-fix goes to Daniel Drake <dsd@laptop.org>. The test
case was written by David Zeuthen <zeuthen@gmail.com>.

https://bugzilla.gnome.org/show_bug.cgi?id=660637

Signed-off-by: David Zeuthen <davidz@redhat.com>
2011-10-07 14:23:03 -04:00
..
gdbus-object-manager-example GDBus: Regenerate code when the codegen or options passed to it changes 2011-10-05 12:42:06 -04:00
schema-tests compile schemas test: open ranges for all types 2011-03-31 15:15:09 +05:30
.gitignore update .gitignores 2011-09-28 12:20:09 -04:00
actions.c actions: merge testcases change_state and entries 2011-06-29 16:20:52 +01:00
appinfo-test2.desktop Cleanups 2010-07-05 00:56:12 -04:00
appinfo-test-gnome.desktop Add some more appinfo tests 2010-07-04 20:51:06 -04:00
appinfo-test-notgnome.desktop Add some more appinfo tests 2010-07-04 20:51:06 -04:00
appinfo-test.c Merge the wip/gapplication branch 2010-06-07 13:48:42 -04:00
appinfo-test.desktop Add some more appinfo tests 2010-07-04 20:51:06 -04:00
appinfo.c Add tests about file associations 2010-07-30 19:51:20 -04:00
async-close-output-stream.c Add bug references to some tests 2010-08-13 21:23:23 -04:00
basic-application.c GApplication test: fix testcase to avoid fork() 2011-09-14 14:09:12 -04:00
buffered-input-stream.c Plug a mem leak in buffered-input-stream test 2010-09-03 15:57:26 -04:00
buffered-output-stream.c Improve coverage of buffered output stream tests 2010-07-30 19:51:21 -04:00
cancellable.c gio: GCancellable can be used concurrently 2011-08-19 11:13:37 +02:00
cert1.pem Added TLS PEM parser unit test 2011-07-27 16:23:33 -04:00
cert2.pem Added TLS PEM parser unit test 2011-07-27 16:23:33 -04:00
cert3.pem Added TLS PEM parser unit test 2011-07-27 16:23:33 -04:00
cert-key.pem Added TLS PEM parser unit test 2011-07-27 16:23:33 -04:00
cert-list.pem Added TLS PEM parser unit test 2011-07-27 16:23:33 -04:00
contenttype.c Misc test additions 2010-07-05 03:09:36 -04:00
contexts.c Remove g_mutex_new()/g_cond_new() in testcases 2011-10-04 19:35:27 -04:00
converter-stream.c Silence a bunch of -Wunused-but-set-variable warnings 2011-04-08 15:44:25 -04:00
data-input-stream.c GDataInputStream: Add _utf8() variants of _read_line 2011-06-16 20:03:02 -04:00
data-output-stream.c Plug a huge mem leak in data-output-stream test 2010-09-03 15:55:10 -04:00
de.po Merge GSettings tests 2010-04-17 01:48:05 -04:00
desktop-app-info.c tests: unbreak desktop-app-info test for jhbuild 2010-12-28 12:18:51 +01:00
echo-server.c Revert "Move gio tests from gio/tests/ to tests/gio/" 2009-07-05 22:49:24 -04:00
enums.xml.template GSettings: major refactor. Add enums, range. 2010-06-16 18:17:53 -04:00
file.c Silence a bunch of -Wunused-but-set-variable warnings 2011-04-08 15:44:25 -04:00
filter-cat.c Add GZIP header processing to GZlibCompressor/GZlibDecompressor 2010-08-17 17:37:32 +02:00
filter-streams.c Fix warning 2010-06-09 10:32:36 +02:00
g-file-info.c Plug a mem leak in g-file-info test 2010-09-03 15:37:08 -04:00
g-file.c Revert "Move gio tests from gio/tests/ to tests/gio/" 2009-07-05 22:49:24 -04:00
g-icon.c Make gio/tests/g-icon pass again 2010-11-27 16:56:44 -05:00
gapplication-example-actions.c Make 4 incompatible changes to the GAction API 2011-06-29 11:38:21 +01:00
gapplication-example-cmdline2.c Fix another faulty GApplicationCommandline example 2011-04-08 17:02:01 -04:00
gapplication-example-cmdline3.c Avoid an interaction between GApplication and GOption 2011-04-08 07:19:38 -04:00
gapplication-example-cmdline.c Tweak GApplication docs 2010-11-02 23:02:05 -04:00
gapplication-example-open.c Tweak GApplication docs 2010-11-02 23:02:05 -04:00
gapplication.c GApplication test: fix testcase to avoid fork() 2011-09-14 14:09:12 -04:00
gdbus-addresses.c Improve dbus address test coverage 2010-08-08 21:32:03 -04:00
gdbus-bz627724.c Add work-around for Bug 627724 2010-09-10 16:23:14 -04:00
gdbus-close-pending.c Regression test for closing a stream, slowly, while a message is queued 2011-09-16 12:00:22 -04:00
gdbus-connection-flush-helper.c Bug 618882 – No way to ensure that a message is sent 2010-07-07 15:03:03 -04:00
gdbus-connection-loss.c GDBusConnection: Make pending calls error when the connection is lost 2011-10-07 14:23:03 -04:00
gdbus-connection-slow.c Take out the timeout from the large-message test 2011-07-10 23:11:30 -04:00
gdbus-connection.c Fix build with gcc-2.*. 2011-05-23 13:05:49 -04:00
gdbus-error.c Add some more test about gdbus_error apis 2010-08-07 18:55:21 -04:00
gdbus-example-export.c remove the redundant interface_name parameter 2010-05-13 13:09:58 -04:00
gdbus-example-objectmanager-client.c gdbus-codegen: Generate GDBusObject{,Proxy,Skeleton} subtypes 2011-04-25 09:29:18 -04:00
gdbus-example-objectmanager-server.c GDBusObjectManagerServer: Allow setting :connection property 2011-05-04 03:43:52 -04:00
gdbus-example-own-name.c Strip copyright headers from examples 2010-05-11 15:50:19 -04:00
gdbus-example-peer.c GDBusServer: Make ::new-connection return whether the connection was claimed 2010-09-09 14:02:31 -04:00
gdbus-example-proxy-subclass.c Bug 621213 – GDBusProxy and well-known names 2010-06-11 18:21:27 -04:00
gdbus-example-server.c GDBus: Add GDBusSendMessageFlags 2010-07-19 16:07:57 -04:00
gdbus-example-subtree.c Update the GDBus subtree example for the new API 2010-07-19 15:03:54 -04:00
gdbus-example-unix-fd-client.c GDBus: Add GDBusSendMessageFlags 2010-07-19 16:07:57 -04:00
gdbus-example-watch-name.c Strip copyright headers from examples 2010-05-11 15:50:19 -04:00
gdbus-example-watch-proxy.c Bug 621213 – GDBusProxy and well-known names 2010-06-11 18:21:27 -04:00
gdbus-exit-on-close.c Disable two GDBus tests 2011-09-16 11:18:26 -04:00
gdbus-export.c Add a (currently failing) testcase 2011-02-15 19:49:24 -05:00
gdbus-introspection.c Fix memory leaks in the gdbus introspection parser 2011-02-15 02:29:15 -05:00
gdbus-message.c GDBusMessage: Don't reset serial number when copying 2010-09-09 15:15:13 -04:00
gdbus-names.c GDBus: fix name test cases 2010-09-23 16:28:59 -04:00
gdbus-non-socket.c Disable two GDBus tests 2011-09-16 11:18:26 -04:00
gdbus-peer.c gio/tests/gdbus-peer: make this work on non-Linux unixes 2011-08-30 09:52:46 -04:00
gdbus-proxy-threads.c Add a stress-test for GDBusProxy in threads with no default main context 2011-08-15 12:50:04 -04:00
gdbus-proxy-well-known-name.c Bug 621213 – GDBusProxy and well-known names 2010-06-11 18:21:27 -04:00
gdbus-proxy.c GDBus: disable two more GDBus tests using fork() 2011-10-05 10:56:11 -04:00
gdbus-serialization.c Fix some compiler warnings from gcc 4.6 2011-04-15 15:51:25 -04:00
gdbus-sessionbus.c Don't do < 0 on an unsigned value 2011-06-14 11:40:32 -04:00
gdbus-sessionbus.h Initial GDBus code-drop from GDBus-standalone repo 2010-05-06 14:21:32 -04:00
gdbus-test-codegen.c GDBusObjectManagerServer: Add test for export_uniquely() method 2011-09-19 17:31:21 -04:00
gdbus-tests.c GDBus: Use thread-default GMainContext in _g_assert_property_notify + friends 2011-04-11 10:51:37 -04:00
gdbus-tests.h Initial GDBus code-drop from GDBus-standalone repo 2010-05-06 14:21:32 -04:00
gdbus-testserver.py GDBusProxy: Correctly handle unknown members when having an expected interface 2011-10-05 10:45:22 -04:00
gdbus-threading.c GDBus: Add GDBusSignalFlags and use it in g_dbus_connection_signal_subscribe() 2010-07-19 15:05:10 -04:00
gschema-compile.c Adapt tests to string changes 2011-09-11 23:28:44 -04:00
gsettings.c Revert "GSettings: don't abort on missing schemas" 2011-10-03 10:19:38 -04:00
gtesttlsbackend.c Added TLS PEM parser unit test 2011-07-27 16:23:33 -04:00
gtesttlsbackend.h Added TLS PEM parser unit test 2011-07-27 16:23:33 -04:00
gtlsconsoleinteraction.c gio/tests/gtlsconsoleinteraction: Work around missing getpass() on win32 2011-08-28 16:45:53 +03:00
gtlsconsoleinteraction.h GTlsDatabase and related objects 2011-08-04 08:54:55 +02:00
httpd.c Silence a bunch of -Wunused-but-set-variable warnings 2011-04-08 15:44:25 -04:00
io-stream.c Add g_io_stream_splice_async/finish() 2010-12-13 17:36:12 +01:00
key-cert.pem Added TLS PEM parser unit test 2011-07-27 16:23:33 -04:00
key.pem Added TLS PEM parser unit test 2011-07-27 16:23:33 -04:00
live-g-file.c Silence a bunch of -Wunused-but-set-variable warnings 2011-04-08 15:44:25 -04:00
live-g-file.txt Revert "Move gio tests from gio/tests/ to tests/gio/" 2009-07-05 22:49:24 -04:00
Makefile.am GDBusConnection: Make pending calls error when the connection is lost 2011-10-07 14:23:03 -04:00
memory-input-stream.c Plug a mem leak in the memory-input-stream test 2010-09-03 15:31:37 -04:00
memory-output-stream.c Fix build with gcc-2.*. 2011-05-23 13:05:49 -04:00
mimeapps.c Add another mimeapps test 2011-09-26 16:54:23 -04:00
network-address.c g_network_address_parse: deprecate symbolic port names 2011-09-03 19:58:40 -04:00
nothing.pem Added TLS PEM parser unit test 2011-07-27 16:23:33 -04:00
org.gtk.test.gschema Merge GSettings tests 2010-04-17 01:48:05 -04:00
org.gtk.test.gschema.xml GSettings: add G_SETTINGS_BIND_INVERT_BOOLEAN flag 2010-08-03 02:09:10 -04:00
pollable.c Add pollable input/output streams 2010-11-26 15:08:08 -05:00
proxy.c Fix some compiler warnings from gcc 4.6 2011-04-15 15:51:25 -04:00
readwrite.c Plug a mem leak in readwrite test 2010-09-03 15:44:28 -04:00
resolver.c Remove !g_thread_supported() codepaths in gio 2011-09-09 12:47:39 -04:00
send-data.c GSocketClient: add a timeout property 2010-08-14 15:26:16 -04:00
simple-async-result.c Improve the async result test coverage 2010-08-08 21:32:03 -04:00
sleepy-stream.c sleepy-stream test: use a real GError domain 2011-09-30 13:17:27 +01:00
socket-client.c gio/tests/socket-client: fix a crash (and some indentation) 2011-10-04 13:19:21 -04:00
socket-common.c Add initial TLS (SSL) support to gio 2010-11-26 15:57:11 -05:00
socket-server.c tls: Make g_tls_{client|server}_connection_new() return a GIOStream 2010-12-07 19:39:24 +01:00
socket.c GSocketAddress: create IPv4 addresses for IPv6 mapped-IPv4 addresses 2011-08-29 23:42:39 -04:00
srvtarget.c Revert "Move gio tests from gio/tests/ to tests/gio/" 2009-07-05 22:49:24 -04:00
test-codegen.xml gdbus-codegen: Add support for new org.gtk.GDBus.C.UnixFD annotation 2011-07-21 16:06:18 -04:00
testenum.h Bug 622124 - implement flags for GSettings 2010-07-01 19:06:02 -04:00
tls-certificate.c Added TLS PEM parser unit test 2011-07-27 16:23:33 -04:00
tls-interaction.c Remove g_mutex_new()/g_cond_new() in testcases 2011-10-04 19:35:27 -04:00
unix-fd.c GUnixSocketAddress: handle abstract sockets with non-0-padded names 2010-04-22 11:54:41 -04:00
unix-streams.c Fix a possible deadlock 2010-08-03 10:41:21 -04:00
volumemonitor.c volume monitor: don't unref NULL 2010-10-05 02:29:47 -04:00
win32-streams.c Add GWin32InputStream and GWin32OutputStream classes 2010-04-19 11:54:56 +03:00