]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
doveadm-server: http: Moved client_connection_destroy_http().
authorStephan Bosch <stephan.bosch@dovecot.fi>
Sat, 7 Oct 2017 15:07:58 +0000 (17:07 +0200)
committerStephan Bosch <stephan.bosch@dovecot.fi>
Tue, 24 Oct 2017 20:29:19 +0000 (22:29 +0200)
src/doveadm/client-connection-http.c

index 9731aa041054c5d8a6e4f6016df9aaba17db54a0..aac00c3c91555d1f23a52255c63a3879df3b5c7e 100644 (file)
@@ -116,6 +116,18 @@ static struct doveadm_http_server_mount doveadm_http_server_mounts[] = {
 
 static void doveadm_http_server_send_response(void *context);
 
+void client_connection_destroy_http(struct client_connection *conn)
+{
+       struct client_connection_http *hconn =
+               (struct client_connection_http *)conn;
+
+       if (hconn->http_client != NULL) {
+               /* We're not in the lib-http/server's connection destroy callback. */
+               http_server_connection_close(&hconn->http_client,
+                       "Server shutting down");
+       }
+}
+
 struct client_connection *
 client_connection_http_create(int fd, bool ssl)
 {
@@ -137,18 +149,6 @@ client_connection_http_create(int fd, bool ssl)
        return &conn->conn;
 }
 
-void client_connection_destroy_http(struct client_connection *conn)
-{
-       struct client_connection_http *hconn =
-               (struct client_connection_http *)conn;
-
-       if (hconn->http_client != NULL) {
-               /* We're not in the lib-http/server's connection destroy callback. */
-               http_server_connection_close(&hconn->http_client,
-                       "Server shutting down");
-       }
-}
-
 static void
 doveadm_http_server_connection_destroy(void *context,
        const char *reason ATTR_UNUSED)