[Spice-devel] [PATCH] Fix callback signature for --spice-debug option handling

Hans de Goede hdegoede at redhat.com
Thu Apr 19 03:12:57 PDT 2012


Good catch, ACK.

Regards,

Hans


On 04/19/2012 12:07 PM, Daniel P. Berrange wrote:
> From: "Daniel P. Berrange"<berrange at redhat.com>
>
> The callback for option handling should return TRUE otherwise the
> option parser will think parsing failed. The current 'void' return
> type meant it was non-deterministic whether --spice-debug actually
> worked or not
>
> Signed-off-by: Daniel P. Berrange<berrange at redhat.com>
> ---
>   gtk/spice-option.c |    3 ++-
>   1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/gtk/spice-option.c b/gtk/spice-option.c
> index dbee5ac..ea5d226 100644
> --- a/gtk/spice-option.c
> +++ b/gtk/spice-option.c
> @@ -46,9 +46,10 @@ static void option_version(void)
>       exit(0);
>   }
>
> -static void option_debug(void)
> +static gboolean option_debug(void)
>   {
>       spice_util_set_debug(TRUE);
> +    return TRUE;
>   }
>
>   /**


More information about the Spice-devel mailing list