Ross Lagerwall 7d9816934e gio/tests: Prevent hangs and aborts in socket-listener
Fix two problems:
1) If g_socket_service_stop is called before the accept call is requeued,
then the reference count won't decrease and this code will hang forever:
  while (G_OBJECT (service)->ref_count == ref_count)
    g_main_context_iteration (NULL, TRUE);

2) Sometimes the testcase fails (maybe 1 in 200 times for me):
GLib-GIO:ERROR:socket-listener.c:73:connection_cb: assertion failed
(G_OBJECT (service)->ref_count == 2): (3 == 2)
Aborted (core dumped)

The problem is that depending on ordering, cancellation of the async
listener can require further main context iterations before it releases
the reference on the socket service. Furthermore, in some cases, it
requires at least one iteration.

https://bugzilla.gnome.org/show_bug.cgi?id=712570
2014-12-07 08:40:18 +02:00
..
2010-07-05 00:56:12 -04:00
2013-07-11 13:49:20 -04:00
2013-11-23 22:21:29 -05:00
2014-04-15 11:36:39 -04:00
2014-09-09 14:11:38 -04:00
2014-01-01 22:01:15 -05:00
2014-01-31 14:31:55 +01:00
2014-11-27 09:12:42 -05:00
2013-11-11 07:11:22 +01:00
2014-06-28 14:06:36 -04:00
2012-10-16 09:39:24 -04:00
2014-01-31 14:31:55 +01:00
2010-04-17 01:48:05 -04:00
2014-01-01 17:59:21 -05:00
2014-07-14 08:27:30 -04:00
2012-10-16 09:39:24 -04:00
2013-11-30 23:10:13 -05:00
2012-10-16 09:39:24 -04:00
2013-11-11 07:11:29 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2012-10-16 09:39:24 -04:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2013-09-23 16:31:40 -04:00
2014-01-13 16:12:31 -05:00
2014-06-05 08:04:47 -04:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-06-28 14:05:23 -04:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2013-03-13 09:41:09 -04:00
2013-06-02 20:02:06 -04:00
2012-10-16 09:39:24 -04:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2012-10-16 09:39:24 -04:00
2014-09-08 08:19:25 +02:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2012-01-13 17:12:53 +01:00
2012-01-13 17:12:53 +01:00
2012-01-13 17:12:53 +01:00
2012-01-13 17:12:53 +01:00
2012-01-13 17:12:53 +01:00
2012-01-13 17:12:53 +01:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2014-01-19 08:58:28 -05:00
2014-01-31 14:31:55 +01:00
2014-01-31 14:31:55 +01:00
2012-12-12 15:20:22 +01:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00