Skip to content

Commit

Permalink
Initialize mutex object for listen_state
Browse files Browse the repository at this point in the history
Uninitialized mutex object will cause the whole memcached process
crashing as soon as it processes stats command.
  • Loading branch information
bcui6611 authored and dustin committed May 3, 2011
1 parent d454134 commit 5b4120a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion daemon/memcached.c
Expand Up @@ -341,7 +341,7 @@ struct {
bool disabled;
ssize_t count;
uint64_t num_disable;
} listen_state;
} listen_state = { .mutex = PTHREAD_MUTEX_INITIALIZER };

static bool is_listen_disabled(void) {
bool ret;
Expand Down

0 comments on commit 5b4120a

Please sign in to comment.