Add getNativeHandle functions

This commit is contained in:
Alex Hultman
2020-06-20 23:36:27 +02:00
parent 030758c2a9
commit aac11b07fb
3 changed files with 11 additions and 1 deletions
+5
View File
@@ -35,6 +35,11 @@ struct AsyncSocket {
friend struct TopicTree;
protected:
/* Returns SSL pointer or FD as pointer */
void *getNativeHandle() {
return us_socket_get_native_handle(SSL, (us_socket_t *) this);
}
/* Get loop data for socket */
LoopData *getLoopData() {
return (LoopData *) us_loop_ext(us_socket_context_loop(SSL, us_socket_context(SSL, (us_socket_t *) this)));