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

ss: client: add sspc_to_user_obj

Helper api exists in direct lws_ss_ apis but not in lws_sspc_, align it.
This commit is contained in:
Jed Lu 2020-07-07 15:14:30 +01:00 committed by Andy Green
parent e09430c48d
commit ed528b59f7
2 changed files with 11 additions and 0 deletions

View file

@ -55,6 +55,7 @@
#define lws_ss_get_est_peer_tx_credit lws_sspc_get_est_peer_tx_credit
#define lws_ss_start_timeout lws_sspc_start_timeout
#define lws_ss_cancel_timeout lws_sspc_cancel_timeout
#define lws_ss_to_user_object lws_sspc_to_user_object
#endif
@ -178,3 +179,7 @@ lws_sspc_start_timeout(struct lws_sspc_handle *h, unsigned int timeout_ms);
LWS_VISIBLE LWS_EXTERN void
lws_sspc_cancel_timeout(struct lws_sspc_handle *h);
LWS_VISIBLE LWS_EXTERN void *
lws_sspc_to_user_object(struct lws_sspc_handle *h);

View file

@ -617,3 +617,9 @@ lws_sspc_cancel_timeout(struct lws_sspc_handle *h)
{
lws_sspc_start_timeout(h, (unsigned int)-1);
}
void *
lws_sspc_to_user_object(struct lws_sspc_handle *h)
{
return (void *)&h[1];
}