[Pkg-nagios-changes] [SCM] Debian packaging for mod gearman. branch, master, updated. f5edd3e88aa2138dcf6d044c835fbd0ada944168
Sven Nierlein
sven at nierlein.de
Fri Feb 11 11:18:40 UTC 2011
The following commit has been merged in the master branch:
commit a548211aa03ab51978bf4e6480a0d93ce6f38e52
Author: Sven Nierlein <sven at nierlein.de>
Date: Wed Feb 2 11:58:37 2011 +0100
fixed problem with dup server when initial gearmand is not running
diff --git a/common/gearman.c b/common/gearman.c
index 99a15f5..c9a25c0 100644
--- a/common/gearman.c
+++ b/common/gearman.c
@@ -83,7 +83,7 @@ int create_client_dup( char ** server_list, gearman_client_st *client ) {
gearman_return_t ret;
int x = 0;
- gm_log( GM_LOG_TRACE, "create_gearman_client_dup()\n" );
+ gm_log( GM_LOG_TRACE, "create_client_dup()\n" );
signal(SIGPIPE, SIG_IGN);
@@ -120,7 +120,7 @@ int create_client( char ** server_list, gearman_client_st *client ) {
gearman_return_t ret;
int x = 0;
- gm_log( GM_LOG_TRACE, "create_gearman_client()\n" );
+ gm_log( GM_LOG_TRACE, "create_client()\n" );
signal(SIGPIPE, SIG_IGN);
diff --git a/common/utils.c b/common/utils.c
index 9a7c862..3991cfe 100644
--- a/common/utils.c
+++ b/common/utils.c
@@ -355,7 +355,7 @@ int parse_args_line(mod_gm_opt_t *opt, char * arg, int recursion_level) {
opt->active = parse_yes_or_no(value, GM_ENABLED);
return(GM_OK);
}
- else if ( value == NULL || !strcmp(value, "" ) ) {
+ else if ( value == NULL ) {
gm_log( GM_LOG_ERROR, "unknown switch '%s'\n", key );
return(GM_OK);
}
diff --git a/tools/send_multi.c b/tools/send_multi.c
index d43747f..08ec197 100644
--- a/tools/send_multi.c
+++ b/tools/send_multi.c
@@ -344,7 +344,7 @@ int read_multi_stream(FILE *stream) {
int read_child_check(char *bufstart, char *bufend) {
char *attribute = NULL;
char *attribute2 = NULL;
- char *error = NULL;
+ char *error = NULL;
char temp_buffer[GM_BUFFERSIZE];
/* child check number */
diff --git a/worker/worker_client.c b/worker/worker_client.c
index 277e6bd..38d8958 100644
--- a/worker/worker_client.c
+++ b/worker/worker_client.c
@@ -108,7 +108,8 @@ void worker_loop() {
gearman_job_free_all( &worker );
gearman_worker_free( &worker );
gearman_client_free( &client );
- if( mod_gm_opt->dupserver_num ) gearman_client_free( &client_dup );
+ if( mod_gm_opt->dupserver_num )
+ gearman_client_free( &client_dup );
/* sleep on error to avoid cpu intensive infinite loops */
sleep(sleep_time_after_error);
@@ -119,7 +120,8 @@ void worker_loop() {
/* create new connections */
set_worker( &worker );
create_client( mod_gm_opt->server_list, &client );
- create_client( mod_gm_opt->dupserver_list, &client_dup );
+ if( mod_gm_opt->dupserver_num )
+ create_client_dup( mod_gm_opt->dupserver_list, &client_dup );
}
}
--
Debian packaging for mod gearman.
More information about the Pkg-nagios-changes
mailing list