| 357 | } |
| 358 | |
| 359 | void internal_deinit(internal_context_t* ctx) { |
| 360 | // how to destroy connection factory |
| 361 | if (!ctx) return; |
| 362 | |
| 363 | libwebsocket_context_destroy( ctx->websocket ); |
| 364 | if( ctx->webrtc ) |
| 365 | libwebrtc_destroy_context( ctx->webrtc ); |
| 366 | |
| 367 | delete ctx; |
| 368 | } |
| 369 | |
| 370 | void internal_set_data(internal_socket_t* socket, void* user_data) { |
| 371 | socket->user_data = user_data; |