lib:texpect: Use C99 initializer for poptOption in texpect
authorAndreas Schneider <asn@samba.org>
Thu, 13 Dec 2018 10:23:00 +0000 (11:23 +0100)
committerAndreas Schneider <asn@cryptomilk.org>
Mon, 28 Jan 2019 09:29:12 +0000 (10:29 +0100)
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
lib/texpect/texpect.c

index dd786705e8e1a778dda3ce13d385355257a8eaee..3f6278bbb10595e8cc76e83dd5432d45bcff8737 100644 (file)
@@ -380,8 +380,20 @@ static int eval_parent(pid_t pid)
  */
 struct poptOption long_options[] = {
        POPT_AUTOHELP
-       {"timeout", 't', POPT_ARG_INT,  &opt_timeout, 't'},
-       {"verbose", 'v', POPT_ARG_NONE, &opt_verbose, 'v'},
+       {
+               .longName  = "timeout",
+               .shortName = 't',
+               .argInfo   = POPT_ARG_INT,
+               .arg       = &opt_timeout,
+               .val       = 't',
+       },
+       {
+               .longName  = "verbose",
+               .shortName = 'v',
+               .argInfo   = POPT_ARG_NONE,
+               .arg       = &opt_verbose,
+               .val       = 'v',
+       },
        POPT_TABLEEND
 };