static void client_close(NBDClient *client)

{

    if (client->closing) {

        return;

    }



    client->closing = true;



    /* Force requests to finish.  They will drop their own references,

     * then we'll close the socket and free the NBDClient.

     */

    qio_channel_shutdown(client->ioc, QIO_CHANNEL_SHUTDOWN_BOTH,

                         NULL);



    /* Also tell the client, so that they release their reference.  */

    if (client->close) {

        client->close(client);

    }

}

static void client_close(NBDClient *client)

{

    if (client->closing) {

        return;

    }



    client->closing = true;



    





    qio_channel_shutdown(client->ioc, QIO_CHANNEL_SHUTDOWN_BOTH,

                         NULL);



    

    if (client->close) {

        client->close(client);

    }

}

static void client_close(NBDClient *client)     if (client->close) {         client->close(client);
static void FUNC_0(NBDClient *VAR_0)

{

    if (VAR_0->closing) {

        return;

    }



    VAR_0->closing = true;



    





    qio_channel_shutdown(VAR_0->ioc, QIO_CHANNEL_SHUTDOWN_BOTH,

                         NULL);



    

    if (VAR_0->close) {

        VAR_0->close(VAR_0);

    }

}

static void FUNC_0(NBDClient *VAR_0)
{ if (VAR_0->closing) { return; } VAR_0->closing = true; qio_channel_shutdown(VAR_0->ioc, QIO_CHANNEL_SHUTDOWN_BOTH,
NULL); if (VAR_0->close) { VAR_0->close(VAR_0); } }