gresource: Make extract work better
[platform/upstream/glib.git] / gio / gsocketservice.c
index 934d60e..81053f0 100644 (file)
@@ -47,9 +47,9 @@
  * If you are interested in writing connection handlers that contain
  * blocking code then see #GThreadedSocketService.
  *
- * The socket service runs on the main loop of the <link
- * linkend="g-main-context-push-thread-default-context">thread-default
- * context</link> of the thread it is created in, and is not
+ * The socket service runs on the main loop of the 
+ * [thread-default context][g-main-context-push-thread-default-context]
+ * of the thread it is created in, and is not
  * threadsafe in general. However, the calls to start and stop the
  * service are thread-safe so these can be used from threads that
  * handle incoming clients.
@@ -129,11 +129,7 @@ g_socket_service_changed (GSocketListener *listener)
       if (service->priv->outstanding_accept)
        g_cancellable_cancel (service->priv->cancellable);
       else
-       {
-         g_socket_listener_accept_async (listener, service->priv->cancellable,
-                                         g_socket_service_ready, NULL);
-         service->priv->outstanding_accept = TRUE;
-       }
+       do_accept (service);
     }
 
   G_UNLOCK (active);
@@ -203,6 +199,12 @@ g_socket_service_start (GSocketService *service)
  * This call is thread-safe, so it may be called from a thread
  * handling an incoming client request.
  *
+ * Note that this only stops accepting new connections; it does not
+ * close the listening sockets, and you can call
+ * g_socket_service_start() again later to begin listening again. To
+ * close the listening sockets, call g_socket_listener_close(). (This
+ * will happen automatically when the #GSocketService is finalized.)
+ *
  * Since: 2.22
  */
 void