summaryrefslogtreecommitdiffstats
path: root/lib/utils_base.c
diff options
context:
space:
mode:
authorLorenz <12514511+RincewindsHat@users.noreply.github.com>2023-05-08 18:24:11 (GMT)
committerGitHub <noreply@github.com>2023-05-08 18:24:11 (GMT)
commit869cca59d857fde53b5a435cb8390f54058e8687 (patch)
treebc9aa773537691078fdac52222c0a8d34882629d /lib/utils_base.c
parent72d34baf718e12a88e978c69369b96baf63ef97a (diff)
parent6c78f0b5ea82a4bea71ae2024f27d3916175a7a2 (diff)
downloadmonitoring-plugins-869cca59d857fde53b5a435cb8390f54058e8687.tar.gz
Merge pull request #1866 from RincewindsHat/compiler_warning_part_1
Compiler warning part 1
Diffstat (limited to 'lib/utils_base.c')
-rw-r--r--lib/utils_base.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/utils_base.c b/lib/utils_base.c
index eb1823b..c458cf6 100644
--- a/lib/utils_base.c
+++ b/lib/utils_base.c
@@ -24,7 +24,7 @@
24* 24*
25*****************************************************************************/ 25*****************************************************************************/
26 26
27#include "common.h" 27#include "../plugins/common.h"
28#include <stdarg.h> 28#include <stdarg.h>
29#include "utils_base.h" 29#include "utils_base.h"
30#include <ctype.h> 30#include <ctype.h>
@@ -319,18 +319,18 @@ char *np_extract_value(const char *varlist, const char *name, char sep) {
319 319
320 while (1) { 320 while (1) {
321 /* Strip any leading space */ 321 /* Strip any leading space */
322 for (varlist; isspace(varlist[0]); varlist++); 322 for (; isspace(varlist[0]); varlist++);
323 323
324 if (strncmp(name, varlist, strlen(name)) == 0) { 324 if (strncmp(name, varlist, strlen(name)) == 0) {
325 varlist += strlen(name); 325 varlist += strlen(name);
326 /* strip trailing spaces */ 326 /* strip trailing spaces */
327 for (varlist; isspace(varlist[0]); varlist++); 327 for (; isspace(varlist[0]); varlist++);
328 328
329 if (varlist[0] == '=') { 329 if (varlist[0] == '=') {
330 /* We matched the key, go past the = sign */ 330 /* We matched the key, go past the = sign */
331 varlist++; 331 varlist++;
332 /* strip leading spaces */ 332 /* strip leading spaces */
333 for (varlist; isspace(varlist[0]); varlist++); 333 for (; isspace(varlist[0]); varlist++);
334 334
335 if (tmp = index(varlist, sep)) { 335 if (tmp = index(varlist, sep)) {
336 /* Value is delimited by a comma */ 336 /* Value is delimited by a comma */