From 9a2114ca574658fd200d0e966ebf7064e531dc8f Mon Sep 17 00:00:00 2001 From: Gilles Peskine Date: Fri, 30 Jul 2021 13:01:52 +0200 Subject: [PATCH] load_roots: properly error out on an invalid option Signed-off-by: Gilles Peskine --- programs/x509/load_roots.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/programs/x509/load_roots.c b/programs/x509/load_roots.c index 2dff95175..7e52957d8 100644 --- a/programs/x509/load_roots.c +++ b/programs/x509/load_roots.c @@ -168,7 +168,11 @@ int main( int argc, char *argv[] ) opt.iterations = atoi( q ) != 0; } else + { mbedtls_printf( "Unknown option: %s\n", p ); + mbedtls_printf( USAGE ); + goto exit; + } } opt.filenames = (const char**) argv + i;