static void s_Close(CONNECTOR connector, const STimeout* timeout, int/*bool*/ close_dispatcher) { SServiceConnector* uuu = (SServiceConnector*) connector->handle; if (uuu->name) { free((void*) uuu->name); uuu->name = 0; } if (uuu->descr) { free((void*) uuu->descr); uuu->descr = 0; } if (close_dispatcher) { if (uuu->user_header) { free((void*) uuu->user_header); uuu->user_header = 0; } if (uuu->params.reset) uuu->params.reset(uuu->params.data); s_CloseDispatcher(uuu); } if (uuu->meta.list) { SMetaConnector* meta = connector->meta; METACONN_Remove(meta, uuu->meta.list); uuu->meta.list = 0; s_Reset(meta, connector); } uuu->status = eIO_Closed; }
static EIO_Status s_Close(CONNECTOR connector, const STimeout* timeout, int/*bool*/ close_dispatcher) { SServiceConnector* uuu = (SServiceConnector*) connector->handle; EIO_Status status = eIO_Success; if (uuu->meta.close) status = uuu->meta.close(uuu->meta.c_close, timeout); if (uuu->name) { free((void*) uuu->name); uuu->name = 0; } if (close_dispatcher) { if (uuu->user_header) { free((void*) uuu->user_header); uuu->user_header = 0; } if (uuu->params.reset) uuu->params.reset(uuu->params.data); s_CloseDispatcher(uuu); } if (uuu->meta.list) { SMetaConnector* meta = connector->meta; METACONN_Remove(meta, uuu->meta.list); uuu->meta.list = 0; s_Reset(meta); } uuu->status = status; return status; }