diff --git a/platform/src/ssl_stream.cpp b/platform/src/ssl_stream.cpp index 1c99d89..b4446c2 100644 --- a/platform/src/ssl_stream.cpp +++ b/platform/src/ssl_stream.cpp @@ -764,7 +764,7 @@ static void peek_client_hello_cb(evutil_socket_t fd, short what, void * arg) peek_client_hello_ctx_free(ctx); break; } - case CHELLO_PARSE_NOT_ENOUGH_BUFF: + case CHELLO_PARSE_NOT_ENOUGH_BUFF: { ssl_chello_free(chello); chello=NULL; @@ -819,6 +819,8 @@ static void ssl_async_peek_client_hello(struct future * f, evutil_socket_t fd, s struct promise * p = future_to_promise(f); struct peek_client_hello_ctx * ctx = ALLOC(struct peek_client_hello_ctx, 1); ctx->ev = event_new(evbase, fd, EV_READ, peek_client_hello_cb, p); + ctx->evbase = evbase; + ctx->parse_client_cipher=parse_cipher; ctx->logger = logger; promise_set_ctx(p, (void *) ctx, peek_client_hello_ctx_free_cb); event_add(ctx->ev, NULL);