[Nagios-devel] [PATCH] Avoiding unnecessary variable attribution

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
Guest

[Nagios-devel] [PATCH] Avoiding unnecessary variable attribution

Post by Guest »

We actually don't need update_status variable.
OK? Comments?



--- base/commands.c (revision 2021)
+++ base/commands.c (working copy)
@@ -97,7 +97,6 @@
/* checks for the existence of the external command file and processes all commands found in it */
int check_for_external_commands(void) {
char *buffer = NULL;
- int update_status = FALSE;

log_debug_info(DEBUGL_FUNCTIONS, 0, "check_for_external_commands()\n");

@@ -110,11 +109,7 @@

/* update the status log with new program information */
/* go easy on the frequency of this if we're checking often - only update program status every 10 seconds.... */
- if(last_command_check = (last_command_status_update + 10)) {
last_command_status_update = last_command_check;
update_program_status(FALSE);
}






This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]
Locked