X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;ds=sidebyside;f=src%2Fprotocol_misc.c;fp=src%2Fprotocol_misc.c;h=dde4bbb4db377445cda34c3b6e028ebb8268237f;hb=84b73f52bf0465de74ef92f8a3496503a52c2a89;hp=8855d20e22a6ada4967c6bd8df759103173ccf2e;hpb=54bc3549c6e109051428147dd62ba15fb3b31f28;p=meshlink diff --git a/src/protocol_misc.c b/src/protocol_misc.c index 8855d20e..dde4bbb4 100644 --- a/src/protocol_misc.c +++ b/src/protocol_misc.c @@ -91,9 +91,10 @@ bool pong_h(meshlink_handle_t *mesh, connection_t *c, const char *request) { /* Successful connection, reset timeout if this is an outgoing connection. */ + // TODO: completely remove this outgoing, let the autoconnect algorithm handle it if(c->outgoing) { c->outgoing->timeout = 0; - c->outgoing->cfg = NULL; + c->outgoing->state = OUTGOING_START; if(c->outgoing->ai) { freeaddrinfo(c->outgoing->ai);