Skip to content

Commit

Permalink
Fix crash during shutdown of cgroups internal plugin. (#10614)
Browse files Browse the repository at this point in the history
  • Loading branch information
mfundul committed Feb 8, 2021
1 parent d206b16 commit 9ba79d3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion collectors/cgroups.plugin/sys_fs_cgroup.c
Expand Up @@ -3937,9 +3937,10 @@ static void cgroup_main_cleanup(void *ptr) {

if (!discovery_thread.exited) {
info("stopping discovery thread worker");
uv_mutex_unlock(&discovery_thread.mutex);
uv_mutex_lock(&discovery_thread.mutex);
discovery_thread.start_discovery = 1;
uv_cond_signal(&discovery_thread.cond_var);
uv_mutex_unlock(&discovery_thread.mutex);
}

while (!discovery_thread.exited && max > 0) {
Expand Down

0 comments on commit 9ba79d3

Please sign in to comment.