[v2,2/3] tests/kvargs: fix check of invalid cases

Message ID 20200327080955.19571-3-olivier.matz@6wind.com (mailing list archive)
State Accepted, archived
Delegated to: David Marchand
Headers
Series kvargs fixes |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK

Commit Message

Olivier Matz March 27, 2020, 8:09 a.m. UTC
  The return was not properly placed, and only the first test case
was validated.

Fixes: e495f5435524 ("kvargs: add test case in app/test")
Cc: stable@dpdk.org

Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
---
 app/test/test_kvargs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Patch

diff --git a/app/test/test_kvargs.c b/app/test/test_kvargs.c
index d3db88a57..f823b771f 100644
--- a/app/test/test_kvargs.c
+++ b/app/test/test_kvargs.c
@@ -230,8 +230,8 @@  static int test_invalid_kvargs(void)
 			rte_kvargs_free(kvlist);
 			goto fail;
 		}
-		return 0;
 	}
+	return 0;
 
  fail:
 	printf("while processing <%s>", *args);