From 2ef4bfd34b5badca1c314c76fee1d6e4af2e36eb Mon Sep 17 00:00:00 2001 From: Asish Ganesh Date: Tue, 2 Jul 2019 11:01:59 +0530 Subject: [PATCH] [FIX] Usability bug fix in server_ctt - At present the check "help" in argv to call the usage() function is not handled as expected - In either case the the code goes into the if condition and returns EXIT_SUCCESS - Fix the minor issue so that code returns this status if it identifies --help or -h Change-Id: I56876ac562647076a5b33259b2ea398b3bc5e584 Signed-off-by: Asish Ganesh --- examples/server_ctt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/server_ctt.c b/examples/server_ctt.c index b384e6e4a..b728f52aa 100644 --- a/examples/server_ctt.c +++ b/examples/server_ctt.c @@ -456,7 +456,7 @@ int main(int argc, char **argv) { signal(SIGTERM, stopHandler); for(int i = 1; i < argc; i++) { - if(strcmp(argv[i], "--help") || + if(strcmp(argv[i], "--help") == 0 || strcmp(argv[i], "-h") == 0) { usage(); return EXIT_SUCCESS;