[PATCH v1 3/4] dnsproxy: add command line switch

Marcel Holtmann marcel at holtmann.org
Tue Jan 25 04:07:02 PST 2011


Hi Daniel,

>  src/main.c |   10 ++++++++--
>  1 files changed, 8 insertions(+), 2 deletions(-)
> 
> diff --git a/src/main.c b/src/main.c
> index a38eb60..8eaab16 100644
> --- a/src/main.c
> +++ b/src/main.c
> @@ -63,6 +63,7 @@ static gchar *option_nodevice = NULL;
>  static gchar *option_noplugin = NULL;
>  static gchar *option_wifi = NULL;
>  static gboolean option_detach = TRUE;
> +static gboolean option_dnsproxy = TRUE;
>  static gboolean option_compat = FALSE;
>  static gboolean option_version = FALSE;
>  
> @@ -94,6 +95,9 @@ static GOptionEntry options[] = {
>  	{ "nodaemon", 'n', G_OPTION_FLAG_REVERSE,
>  				G_OPTION_ARG_NONE, &option_detach,
>  				"Don't fork daemon to background" },
> +	{ "nodsnproxy", 'x', G_OPTION_FLAG_REVERSE,
> +				G_OPTION_ARG_NONE, &option_dnsproxy,
> +				"Don't enable dnsproxy" },

you realized you letter mixup with dsn ;)

Also please don't use 'x' here. We need to find a better shortcut. Since
d, n and p are taken, what about r for resolver. We could also use upper
case P since normally that is for disable (sort of).

I would vote for -r since it could mean "use resolv.conf". I know it is
a stretch, but good enough for me.

And please don't be cryptic with the description. Call it DNS Proxy as
what it is and not just the module name.

Regards

Marcel





More information about the connman mailing list