Properly queue net events for tls-proxy example

This commit is contained in:
Joris Vink 2016-01-22 15:07:33 +01:00
parent a958627837
commit 340bcb3b0d
1 changed files with 8 additions and 2 deletions

View File

@ -166,7 +166,8 @@ client_setup(struct connection *c)
int
backend_handle_connect(struct connection *c)
{
int ret;
int ret;
struct connection *src;
/* We will get a write notification when we can progress. */
if (!(c->flags & CONN_WRITE_POSSIBLE))
@ -208,7 +209,12 @@ backend_handle_connect(struct connection *c)
kore_connection_start_idletimer(c);
kore_platform_event_all(c->fd, c);
return (KORE_RESULT_OK);
/* Allow events from source now. */
src = c->hdlr_extra;
kore_platform_event_all(src->fd, src);
/* Now lets start. */
return (c->handle(c));
}
/*