mirror of
https://github.com/samba-team/samba.git
synced 2025-08-04 08:22:08 +03:00
s3:netapi: Use C99 initializer for poptOption in netapi example
Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
This commit is contained in:
committed by
Andreas Schneider
parent
1cde483c96
commit
025b32e525
@ -57,11 +57,40 @@ void popt_common_callback(poptContext con,
|
||||
}
|
||||
|
||||
struct poptOption popt_common_netapi_examples[] = {
|
||||
{ NULL, 0, POPT_ARG_CALLBACK|POPT_CBFLAG_PRE|POPT_CBFLAG_POST, (void *)popt_common_callback },
|
||||
{ "user", 'U', POPT_ARG_STRING, NULL, 'U', "Username used for connection", "USERNAME" },
|
||||
{ "password", 'p', POPT_ARG_STRING, NULL, 'p', "Password used for connection", "PASSWORD" },
|
||||
{ "debuglevel", 'd', POPT_ARG_STRING, NULL, 'd', "Debuglevel", "DEBUGLEVEL" },
|
||||
{ "kerberos", 'k', POPT_ARG_NONE, NULL, 'k', "Use Kerberos", NULL },
|
||||
{
|
||||
.argInfo = POPT_ARG_CALLBACK|POPT_CBFLAG_PRE|POPT_CBFLAG_POST,
|
||||
.arg = (void *)popt_common_callback,
|
||||
},
|
||||
{
|
||||
.longName = "user",
|
||||
.shortName = 'U',
|
||||
.argInfo = POPT_ARG_STRING,
|
||||
.val = 'U',
|
||||
.descrip = "Username used for connection",
|
||||
.argDescrip = "USERNAME",
|
||||
},
|
||||
{
|
||||
.longName = "password",
|
||||
.shortName = 'p',
|
||||
.argInfo = POPT_ARG_STRING,
|
||||
.val = 'p',
|
||||
.descrip = "Password used for connection",
|
||||
.argDescrip = "PASSWORD",
|
||||
},
|
||||
{
|
||||
.longName = "debuglevel",
|
||||
.shortName = 'd',
|
||||
.argInfo = POPT_ARG_STRING,
|
||||
.val = 'd',
|
||||
.descrip = "Debuglevel",
|
||||
.argDescrip = "DEBUGLEVEL",
|
||||
},
|
||||
{
|
||||
.longName = "kerberos",
|
||||
.shortName = 'k',
|
||||
.argInfo = POPT_ARG_NONE,
|
||||
.val = 'k',
|
||||
.descrip = "Use Kerberos",
|
||||
},
|
||||
POPT_TABLEEND
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user