From c0f4bbb3083b56bf4f1e089a40ab059233b88495 Mon Sep 17 00:00:00 2001 From: Vincent Sanders Date: Sat, 6 Aug 2016 10:27:32 +0100 Subject: remove erroneous parameter check to nsoption_snoptionf The API check and bounds check for option indexes was from an unsigned enum so checking for negative numbers was causing "comparison is always false" errors in compilation. --- utils/nsoption.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'utils') diff --git a/utils/nsoption.c b/utils/nsoption.c index 6754d2131..92ecfc176 100644 --- a/utils/nsoption.c +++ b/utils/nsoption.c @@ -826,7 +826,7 @@ nsoption_snoptionf(char *string, return -1; } - if ((option_idx < 0) || (option_idx >= NSOPTION_LISTEND)) { + if (option_idx >= NSOPTION_LISTEND) { return -1; } -- cgit v1.2.3