s3:utils: Use C99 initializer for poptOption in smbtree
authorAndreas Schneider <asn@samba.org>
Fri, 11 Jan 2019 13:53:36 +0000 (14:53 +0100)
committerAndreas Schneider <asn@cryptomilk.org>
Mon, 28 Jan 2019 09:29:14 +0000 (10:29 +0100)
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
source3/utils/smbtree.c

index fb0f165a18d735fd561ddc5a435f2c3563b91c8a..9f589b4060f2e22c4207da2aebda05297f9978d5 100644 (file)
@@ -292,9 +292,30 @@ int main(int argc, char *argv[])
        const char **argv_const = discard_const_p(const char *, argv);
        struct poptOption long_options[] = {
                POPT_AUTOHELP
-               { "broadcast", 'b', POPT_ARG_VAL, &use_bcast, True, "Use broadcast instead of using the master browser" },
-               { "domains", 'D', POPT_ARG_VAL, &level, LEV_WORKGROUP, "List only domains (workgroups) of tree" },
-               { "servers", 'S', POPT_ARG_VAL, &level, LEV_SERVER, "List domains(workgroups) and servers of tree" },
+               {
+                       .longName   = "broadcast",
+                       .shortName  = 'b',
+                       .argInfo    = POPT_ARG_VAL,
+                       .arg        = &use_bcast,
+                       .val        = True,
+                       .descrip    = "Use broadcast instead of using the master browser" ,
+               },
+               {
+                       .longName   = "domains",
+                       .shortName  = 'D',
+                       .argInfo    = POPT_ARG_VAL,
+                       .arg        = &level,
+                       .val        = LEV_WORKGROUP,
+                       .descrip    = "List only domains (workgroups) of tree" ,
+               },
+               {
+                       .longName   = "servers",
+                       .shortName  = 'S',
+                       .argInfo    = POPT_ARG_VAL,
+                       .arg        = &level,
+                       .val        = LEV_SERVER,
+                       .descrip    = "List domains(workgroups) and servers of tree" ,
+               },
                POPT_COMMON_SAMBA
                POPT_COMMON_CREDENTIALS
                POPT_TABLEEND