mirror of
https://github.com/monitoring-plugins/monitoring-plugins.git
synced 2026-04-29 18:20:03 -04:00
Merge pull request #1552 from madpilot78/Avoid_passing_NULL_to_vprintf
Avoid passing NULL to vprintf().
This commit is contained in:
commit
82a634f7bf
1 changed files with 7 additions and 4 deletions
|
|
@ -87,10 +87,13 @@ void _get_monitoring_plugin( monitoring_plugin **pointer ){
|
|||
void
|
||||
die (int result, const char *fmt, ...)
|
||||
{
|
||||
va_list ap;
|
||||
va_start (ap, fmt);
|
||||
vprintf (fmt, ap);
|
||||
va_end (ap);
|
||||
if(fmt!=NULL) {
|
||||
va_list ap;
|
||||
va_start (ap, fmt);
|
||||
vprintf (fmt, ap);
|
||||
va_end (ap);
|
||||
}
|
||||
|
||||
if(this_monitoring_plugin!=NULL) {
|
||||
np_cleanup();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue