nl = mnl_socket_open(NETLINK_NETFILTER);
if(!nl) {
error("nfacct.plugin: mnl_socket_open() failed");
+ pthread_exit(NULL);
return NULL;
}
if(mnl_socket_bind(nl, 0, MNL_SOCKET_AUTOPID) < 0) {
mnl_socket_close(nl);
error("nfacct.plugin: mnl_socket_bind() failed");
+ pthread_exit(NULL);
return NULL;
}
portid = mnl_socket_get_portid(nl);
if(!nlh) {
mnl_socket_close(nl);
error("nfacct.plugin: nfacct_nlmsg_build_hdr() failed");
+ pthread_exit(NULL);
return NULL;
}
if(mnl_socket_sendto(nl, nlh, nlh->nlmsg_len) < 0) {
error("nfacct.plugin: mnl_socket_send");
+ pthread_exit(NULL);
return NULL;
}
if (ret == -1) {
error("nfacct.plugin: error communicating with kernel.");
+ pthread_exit(NULL);
return NULL;
}
}
mnl_socket_close(nl);
+ pthread_exit(NULL);
return NULL;
}
#endif
fp = mypopen(buffer, &tc_child_pid);
if(!fp) {
error("TC: Cannot popen(\"%s\", \"r\").", buffer);
+ pthread_exit(NULL);
return NULL;
}
if(netdata_exit) {
tc_device_free_all();
+ pthread_exit(NULL);
return NULL;
}
sleep((unsigned int) rrd_update_every);
}
+ pthread_exit(NULL);
return NULL;
}
cd->pid = 0;
cd->enabled = 0;
cd->obsolete = 1;
+ pthread_exit(NULL);
return NULL;
}
}
cd->obsolete = 1;
+ pthread_exit(NULL);
return NULL;
}
dir = opendir(dir_name);
if(unlikely(!dir)) {
error("Cannot open directory '%s'.", dir_name);
+ pthread_exit(NULL);
return NULL;
}
sleep((unsigned int) scan_frequency);
}
+ pthread_exit(NULL);
return NULL;
}