1
0
mirror of https://github.com/payden/libwsclient synced 2024-10-27 17:54:01 +00:00
This commit is contained in:
Demchenko Eugene 2020-06-15 11:34:19 +08:00 committed by GitHub
commit 1f44320bc3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -109,6 +109,7 @@ typedef struct _wsclient {
wsclient_frame *current_frame;
struct sockaddr_un helper_sa;
int helper_sock;
void *user_data;
#ifdef HAVE_LIBSSL
SSL_CTX *ssl_ctx;
SSL *ssl;
@ -137,6 +138,12 @@ void libwsclient_close(wsclient *c);
int libwsclient_helper_socket(wsclient *c, const char *path);
void *libwsclient_helper_socket_thread(void *ptr);
void libwsclient_onclose(wsclient *client, int (*cb)(wsclient *c));
void libwsclient_onopen(wsclient *client, int (*cb)(wsclient *c));
void libwsclient_onmessage(wsclient *client, int (*cb)(wsclient *c, wsclient_message *msg));
void libwsclient_onerror(wsclient *client, int (*cb)(wsclient *c, wsclient_error *err));
int libwsclient_send(wsclient *client, char *strdata);
//Define errors
char *errors[] = {
"Unknown error occured",