[Nagios-devel] create_job() may return NULL

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] create_job() may return NULL

Post by Guest »

Hya,

Function create_job() may return NULL in case of memory
allocation problems, so i think its valid to verify if
job is valid on wproc_run_job().

-rm

===================================================================
--- base/workers.c (revision 2479)
+++ base/workers.c (working copy)
@@ -869,6 +869,9 @@
worker_process *wp;
int ret;

+ if (!job)
+ return ERROR;
+
/*
* get_worker() also adds job to the workers list
* and sets job_id







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