qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [Qemu-trivial] [PATCH 3/5] qemu-char: pass bool paramet


From: li guang
Subject: Re: [Qemu-devel] [Qemu-trivial] [PATCH 3/5] qemu-char: pass bool parameter for qemu_opt_get_bool
Date: Tue, 18 Jun 2013 10:33:37 +0800

在 2013-06-11二的 15:35 +0400,Michael Tokarev写道:
> 11.06.2013 09:15, liguang wrote:
> > Signed-off-by: liguang <address@hidden>
> > ---
> >  qemu-char.c |    8 ++++----
> >  1 files changed, 4 insertions(+), 4 deletions(-)
> > 
> > diff --git a/qemu-char.c b/qemu-char.c
> > index d04b429..8092eb8 100644
> > --- a/qemu-char.c
> > +++ b/qemu-char.c
> > @@ -2767,10 +2767,10 @@ static CharDriverState 
> > *qemu_chr_open_socket(QemuOpts *opts)
> >      int is_unix;
> >      int is_telnet;
> >  
> > -    is_listen      = qemu_opt_get_bool(opts, "server", 0);
> > -    is_waitconnect = qemu_opt_get_bool(opts, "wait", 1);
> > -    is_telnet      = qemu_opt_get_bool(opts, "telnet", 0);
> > -    do_nodelay     = !qemu_opt_get_bool(opts, "delay", 1);
> > +    is_listen      = qemu_opt_get_bool(opts, "server", false);
> > +    is_waitconnect = qemu_opt_get_bool(opts, "wait", true);
> > +    is_telnet      = qemu_opt_get_bool(opts, "telnet", false);
> > +    do_nodelay     = !qemu_opt_get_bool(opts, "delay", true);
> >      is_unix        = qemu_opt_get(opts, "path") != NULL;
> >      if (!is_listen)
> >          is_waitconnect = 0;
> 
> While we're at it, all the is_* variables themselves should be made
> bool instead of int too.
> 

right,

Thanks!





reply via email to

[Prev in Thread] Current Thread [Next in Thread]