From: Michal Voců Date: Thu, 22 Mar 2012 12:41:06 +0000 (+0000) Subject: candidate fix for SB#92708 X-Git-Tag: glite-jobid-api-c_R_2_1_2_1~13 X-Git-Url: http://scientific.zcu.cz/git/?a=commitdiff_plain;h=ed15a87b4e413f98d0b7cddce035b09be96ac30c;p=jra1mw.git candidate fix for SB#92708 --- diff --git a/org.glite.lb.logger/src/logd_proto.c b/org.glite.lb.logger/src/logd_proto.c index 8eca13a..f8b80b7 100644 --- a/org.glite.lb.logger/src/logd_proto.c +++ b/org.glite.lb.logger/src/logd_proto.c @@ -556,6 +556,16 @@ int edg_wll_log_proto_server(edg_wll_GssConnection *con, struct timeval *timeout else event->any.priority = 0; } + if (event->any.priority & (EDG_WLL_LOGFLAG_SYNC|EDG_WLL_LOGFLAG_SYNC_COMPAT)) { + if(init_confirmation() < 0) { + glite_common_log(LOG_CATEGORY_ACCESS,LOG_PRIORITY_WARN,"Error initializing 2nd UNIX socket (%s) for priority messages confirmation.\n",confirm_sock_name); + answer = errno; + goto edg_wll_log_proto_server_end; + } else { + glite_common_log(LOG_CATEGORY_ACCESS,LOG_PRIORITY_DEBUG,"Initializing 2nd UNIX socket (%s) for priority messages confirmation...[ok]\n",confirm_sock_name); + } + } + /* if not command, save message to file */ if(strstr(msg, "DG.TYPE=\"command\"") == NULL) { /* compose the name of the log file */ @@ -596,13 +606,6 @@ int edg_wll_log_proto_server(edg_wll_GssConnection *con, struct timeval *timeout if (!send_answer_back(con,answer,timeout)) { answer_sent = 1; } - if(init_confirmation() < 0) { - glite_common_log(LOG_CATEGORY_ACCESS,LOG_PRIORITY_WARN,"Error initializing 2nd UNIX socket (%s) for priority messages confirmation.\n",confirm_sock_name); - answer = errno; - goto edg_wll_log_proto_server_end; - } else { - glite_common_log(LOG_CATEGORY_ACCESS,LOG_PRIORITY_DEBUG,"Initializing 2nd UNIX socket (%s) for priority messages confirmation...[ok]\n",confirm_sock_name); - } } /* send message via IPC (UNIX socket) */