From e29838a58e33e225a0392ee9e0e53ac328276d5d Mon Sep 17 00:00:00 2001 From: Ian Gulliver Date: Sat, 20 Jun 2015 17:42:54 +0000 Subject: [PATCH] Fix reconnect test failure. --- clients/c/test.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/clients/c/test.c b/clients/c/test.c index e83df29..9e9adfe 100644 --- a/clients/c/test.c +++ b/clients/c/test.c @@ -25,6 +25,7 @@ typedef struct { void on_connect(void *passthrough) { test_state *state = passthrough; assert(!pthread_mutex_lock(&state->lock)); + state->disconnect_fired = false; state->connect_fired = true; assert(!pthread_cond_signal(&state->cond)); assert(!pthread_mutex_unlock(&state->lock)); @@ -33,6 +34,7 @@ void on_connect(void *passthrough) { void on_disconnect(void *passthrough) { test_state *state = passthrough; assert(!pthread_mutex_lock(&state->lock)); + state->connect_fired = false; state->disconnect_fired = true; assert(!pthread_cond_signal(&state->cond)); assert(!pthread_mutex_unlock(&state->lock));