diff options
Diffstat (limited to 'plugins/check_ntp_peer.c')
-rw-r--r-- | plugins/check_ntp_peer.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/check_ntp_peer.c b/plugins/check_ntp_peer.c index 73ba8990..6963fde5 100644 --- a/plugins/check_ntp_peer.c +++ b/plugins/check_ntp_peer.c @@ -183,10 +183,10 @@ char *extract_value(const char *varlist, const char *name){ char *tmp=NULL, *value=NULL; int i; - /* Strip any leading space */ - while (1) { + /* Strip any leading space */ for (varlist; isspace(varlist[0]); varlist++); + if (strncmp(name, varlist, strlen(name)) == 0) { varlist += strlen(name); /* strip trailing spaces */ |