|
|
|
@ -746,6 +746,7 @@ static void *__sntll_thread(void *b)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
__finish:
|
|
|
|
|
co->flags |= SNSX_CLOSED;
|
|
|
|
|
__connection_destroy(co);
|
|
|
|
|
__sntll_bundle_destroy(b); /* destroy bundle */
|
|
|
|
|
return NULL;
|
|
|
|
@ -1143,3 +1144,20 @@ conn_t *connection_link(conn_sys_t *ssys, const char *host,
|
|
|
|
|
return NULL;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
int connection_close(conn_t *co)
|
|
|
|
|
{
|
|
|
|
|
sntllv2_head_t mhead;
|
|
|
|
|
|
|
|
|
|
memset(&mhead, 0, sizeof(sntllv2_head_t));
|
|
|
|
|
/* setup header */
|
|
|
|
|
mhead.attr = SXMSG_LINK | SXMSG_CLOSED;
|
|
|
|
|
|
|
|
|
|
pthread_mutex_lock(&(co->sslinout[1]));
|
|
|
|
|
__conn_write(co, &mhead, sizeof(sntllv2_head_t));
|
|
|
|
|
pthread_mutex_unlock(&(co->sslinout[1]));
|
|
|
|
|
|
|
|
|
|
/* we will not wait anything */
|
|
|
|
|
co->flags |= SNSX_CLOSED;
|
|
|
|
|
|
|
|
|
|
return SNE_SUCCESS;
|
|
|
|
|
}
|
|
|
|
|