qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Hajnoczi <stefanha@gmail.com>
To: Christophe Fergeau <cfergeau@redhat.com>
Cc: qemu-devel@nongnu.org, Markus Armbruster <armbru@redhat.com>,
	Stefan Hajnoczi <stefanha@redhat.com>,
	Max Reitz <mreitz@redhat.com>
Subject: Re: [Qemu-devel] [PATCH v6 2/2] log: Make glib logging go through QEMU
Date: Tue, 29 Jan 2019 11:34:28 +0800	[thread overview]
Message-ID: <20190129033428.GF3264@stefanha-x1.localdomain> (raw)
In-Reply-To: <20190125172229.23025-2-cfergeau@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 1415 bytes --]

On Fri, Jan 25, 2019 at 06:22:29PM +0100, Christophe Fergeau wrote:
> This commit adds a qemu_init_logging() helper which calls
> g_log_set_default_handler() so that glib logs (g_log, g_warning, ...)
> are handled similarly to other QEMU logs. This means they will get a
> timestamp if timestamps are enabled, and they will go through the
> HMP monitor if one is configured.
> This commit also adds a call to qemu_init_logging() to the binaries
> installed by QEMU.
> glib debug messages are enabled through G_MESSAGES_DEBUG similarly to
> glib default log handler.
> 
> At the moment, this change will mostly impact SPICE logging if your
> spice version is >= 0.14.1. With older spice versions, this is not going
> to work as expected, but will not have any ill effect, so this call is
> not conditional on the SPICE version.
> 
> Signed-off-by: Christophe Fergeau <cfergeau@redhat.com>
> ---
>  bsd-user/main.c             |  2 ++
>  include/qemu/error-report.h |  3 ++-
>  linux-user/main.c           |  2 ++
>  qemu-img.c                  |  2 +-
>  qemu-io.c                   |  2 +-
>  qemu-nbd.c                  |  2 +-
>  scsi/qemu-pr-helper.c       |  1 +
>  util/qemu-error.c           | 48 ++++++++++++++++++++++++++++++++++++-
>  vl.c                        |  2 +-
>  9 files changed, 58 insertions(+), 6 deletions(-)

Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 455 bytes --]

  reply	other threads:[~2019-01-29  3:34 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-25 17:22 [Qemu-devel] [PATCH v6 1/2] qemu-io: Use error_[gs]et_progname() Christophe Fergeau
2019-01-25 17:22 ` [Qemu-devel] [PATCH v6 2/2] log: Make glib logging go through QEMU Christophe Fergeau
2019-01-29  3:34   ` Stefan Hajnoczi [this message]
2019-01-29 18:17   ` Markus Armbruster
2019-01-25 20:37 ` [Qemu-devel] [PATCH v6 1/2] qemu-io: Use error_[gs]et_progname() Eric Blake
2019-01-29  3:34 ` Stefan Hajnoczi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190129033428.GF3264@stefanha-x1.localdomain \
    --to=stefanha@gmail.com \
    --cc=armbru@redhat.com \
    --cc=cfergeau@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).