X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;f=src%2Fprotocol.c;h=b4cb5ad5e2af15ebdd8c83812e5f965ab05990ff;hb=0b6635bd9460ba2f9aeafddd2aef79929cd417a1;hp=3886e357a83b91a7349d80d1314d4ea601282600;hpb=9cde0d32cf209388cc59b06b7dcb0c3432f97da5;p=meshlink diff --git a/src/protocol.c b/src/protocol.c index 3886e357..b4cb5ad5 100644 --- a/src/protocol.c +++ b/src/protocol.c @@ -129,7 +129,6 @@ void forward_request(meshlink_handle_t *mesh, connection_t *from, submesh_t *s, bool receive_request(meshlink_handle_t *mesh, connection_t *c, const char *request) { assert(request); - assert(*request); if(c->outgoing && mesh->proxytype == PROXY_HTTP && c->allow_request == ID) { if(!request[0] || request[0] == '\r') { @@ -209,7 +208,7 @@ static void age_past_requests(event_loop_t *loop, void *data) { if(left) { timeout_set(&mesh->loop, &mesh->past_request_timeout, &(struct timeval) { - 10, rand() % 100000 + 10, prng(mesh, TIMER_FUDGE) }); } } @@ -230,7 +229,7 @@ bool seen_request(meshlink_handle_t *mesh, const char *request) { if(!mesh->past_request_tree->head) { timeout_set(&mesh->loop, &mesh->past_request_timeout, &(struct timeval) { - 10, rand() % 100000 + 10, prng(mesh, TIMER_FUDGE) }); }