qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v5] Add timestamp to error_report()


From: Stefan Hajnoczi
Subject: Re: [Qemu-devel] [PATCH v5] Add timestamp to error_report()
Date: Wed, 3 Jul 2013 11:13:42 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

On Tue, Jul 02, 2013 at 02:09:24PM +0000, Seiji Aguchi wrote:
> 
> 
> > > +DEF("msg", HAS_ARG, QEMU_OPTION_msg,
> > > +    "-msg [timestamp=on|off]\n"
> > > +    "  change the format of messages\n"
> > > +    "  timestamp=on|off enables leading timestamps (default:on)\n",
> > > +    QEMU_ARCH_ALL)
> > > +STEXI
> > > address@hidden -msg timestamp=on|off
> > > address@hidden -msg
> > > +prepend a timestamp to each log message.
> > > +(disabled by default)
> > > +ETEXI
> > 
> > I am confused.  If the user specifies -msg then enable_timestamp_msg is
> > on by default.  If the user does not specify -msg then
> > enable_timestmap_msg is off.  Did I get that right?
> 
> Yes.
> 
> > 
> > This means that the default behavior of QEMU does not change but you can
> > add -msg to enable timestamps.
> > 
> > I'm happy with this but find the documentation confusing.
> 
> I can remove "(disabled by default)" if needed.

Perhaps the simplest solution is timestamp=off by default.  Then there
can be no confusion and users must do -msg timestamp=on to enable
timestamps.

If you really want to keep -msg as a shortcut for -msg timestamp=on,
then please document explicitly that:
1. Without -msg timestamps are off.
1. With -msg timestamps are on.
2. -msg timestamp=off can be used to turn timestamps off again.

Stefan



reply via email to

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