1
0
Fork 0
mirror of https://github.com/warmcat/libwebsockets.git synced 2025-03-09 00:00:04 +01:00

lws_get_tsi

Get thread service index wsi belong to
This commit is contained in:
Sun Dro 2019-10-29 13:06:15 +04:00 committed by Andy Green
parent 1d618e8793
commit 10bb008dd4
2 changed files with 14 additions and 1 deletions

View file

@ -579,6 +579,15 @@ lws_dir(const char *dirpath, void *user, lws_dir_callback_function cb);
*/
size_t lws_get_allocated_heap(void);
/**
* lws_get_tsi() - Get thread service index wsi belong to
* \param wsi: websocket connection to check
*
* Returns more than zero (or zero if only one service thread as is the default).
*/
LWS_VISIBLE LWS_EXTERN int
lws_get_tsi(struct lws *wsi);
/**
* lws_is_ssl() - Find out if connection is using SSL
* \param wsi: websocket connection to check

View file

@ -400,7 +400,11 @@ lws_adjust_protocol_psds(struct lws *wsi, size_t new_size)
return wsi->user_space;
}
LWS_VISIBLE int
lws_get_tsi(struct lws *wsi)
{
return (int)wsi->tsi;
}
LWS_VISIBLE int
lws_is_ssl(struct lws *wsi)