fix one minor bug with the disconnct function

master
jp9000 2013-12-26 04:33:16 -07:00
parent 03e1aaad3e
commit 3b48f79442
1 changed files with 1 additions and 1 deletions

View File

@ -182,7 +182,7 @@ void signal_handler_disconnect(signal_handler_t handler, const char *signal,
pthread_mutex_lock(&sig->mutex);
idx = signal_get_callback_idx(sig, callback, data);
if (idx == DARRAY_INVALID)
if (idx != DARRAY_INVALID)
da_erase(sig->callbacks, idx);
pthread_mutex_unlock(&sig->mutex);