qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] qemu exec.c monitor.c
@ 2007-06-30 13:53 Paul Brook
  2007-07-01 17:29 ` Stefan Weil
  0 siblings, 1 reply; 3+ messages in thread
From: Paul Brook @ 2007-06-30 13:53 UTC (permalink / raw)
  To: qemu-devel

CVSROOT:	/sources/qemu
Module name:	qemu
Changes by:	Paul Brook <pbrook>	07/06/30 13:53:24

Modified files:
	.              : exec.c monitor.c 

Log message:
	Allow changing log filename.
	Close logfile when logging is disabled.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemu/exec.c?cvsroot=qemu&r1=1.101&r2=1.102
http://cvs.savannah.gnu.org/viewcvs/qemu/monitor.c?cvsroot=qemu&r1=1.74&r2=1.75

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Qemu-devel] qemu exec.c monitor.c
  2007-06-30 13:53 [Qemu-devel] qemu exec.c monitor.c Paul Brook
@ 2007-07-01 17:29 ` Stefan Weil
  2007-07-01 18:26   ` Paul Brook
  0 siblings, 1 reply; 3+ messages in thread
From: Stefan Weil @ 2007-07-01 17:29 UTC (permalink / raw)
  To: qemu-devel

ANSI / POSIX do not define "wa" as mode string for fopen.
I have no idea how many implementations of libc
will fail with this mode which was introduced by
the latest version of exec.c.

The standard mode for append is just "a".
Even better (because it is faster and creates smaller
log files for Windows) is "ab" for append and "wb"
otherwise.

Stefan

Paul Brook schrieb:
> CVSROOT: /sources/qemu
> Module name: qemu
> Changes by: Paul Brook <pbrook> 07/06/30 13:53:24
>
> Modified files:
> . : exec.c monitor.c
>
> Log message:
> Allow changing log filename.
> Close logfile when logging is disabled.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Qemu-devel] qemu exec.c monitor.c
  2007-07-01 17:29 ` Stefan Weil
@ 2007-07-01 18:26   ` Paul Brook
  0 siblings, 0 replies; 3+ messages in thread
From: Paul Brook @ 2007-07-01 18:26 UTC (permalink / raw)
  To: qemu-devel

On Sunday 01 July 2007, Stefan Weil wrote:
> ANSI / POSIX do not define "wa" as mode string for fopen.
> I have no idea how many implementations of libc
> will fail with this mode which was introduced by
> the latest version of exec.c.
>
> The standard mode for append is just "a".

You are correct. I've fixed this.

> Even better (because it is faster and creates smaller
> log files for Windows) is "ab" for append and "wb"
> otherwise.

We're writing human-readable text, so opening in binary mode is IMHO fairly 
dubious. If you really want fast logs/traces there are better ways to speed 
it up.

Paul

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-07-01 18:26 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-06-30 13:53 [Qemu-devel] qemu exec.c monitor.c Paul Brook
2007-07-01 17:29 ` Stefan Weil
2007-07-01 18:26   ` Paul Brook

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).