qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Blue Swirl <blauwirbel@gmail.com>
To: Markus Armbruster <armbru@redhat.com>
Cc: qemu-devel@nongnu.org, lcapitulino@redhat.com
Subject: Re: [Qemu-devel] [PATCH 5/6] error: Link qemu-img, qemu-nbd, qemu-io with qemu-error.o
Date: Thu, 18 Mar 2010 19:58:00 +0200	[thread overview]
Message-ID: <f43fc5581003181058j1020f6e2x419e35b51ab11763@mail.gmail.com> (raw)
In-Reply-To: <m3y6hqsl4z.fsf@blackfin.pond.sub.org>

On 3/17/10, Markus Armbruster <armbru@redhat.com> wrote:
> Blue Swirl <blauwirbel@gmail.com> writes:
>
>  > On 3/17/10, Markus Armbruster <armbru@redhat.com> wrote:
>  >> The location tracking interface is used by code shared with qemi-img,
>  >>  qemu-nbd and qemu-io, so it needs to be available there.  Commit
>  >>  827b0813 provides it in a rather hamfisted way: it adds a dummy
>  >>  implementation to qemu-tool.c.
>  >>
>  >>  It's cleaner to provide the real thing, and put a few more dummy
>  >>  monitor functions into qemu-tool.c.
>  >>
>  >>  Signed-off-by: Markus Armbruster <armbru@redhat.com>
>  >>  ---
>  >>   Makefile    |    6 +++---
>  >>   qemu-tool.c |   50 ++++++++++++++++----------------------------------
>  >>   2 files changed, 19 insertions(+), 37 deletions(-)
>  >>
>  >>  diff --git a/Makefile b/Makefile
>  >>  index 2066c12..aad361e 100644
>  >>  --- a/Makefile
>  >>  +++ b/Makefile
>  >>  @@ -129,11 +129,11 @@ bt-host.o: QEMU_CFLAGS += $(BLUEZ_CFLAGS)
>  >>   qemu-img.o: qemu-img-cmds.h
>  >>   qemu-img.o qemu-tool.o qemu-nbd.o qemu-io.o: $(GENERATED_HEADERS)
>  >>
>  >>  -qemu-img$(EXESUF): qemu-img.o qemu-tool.o $(block-obj-y) $(qobject-obj-y)
>  >>  +qemu-img$(EXESUF): qemu-img.o qemu-tool.o qemu-error.o $(block-obj-y) $(qobject-obj-y)
>  >>
>  >>  -qemu-nbd$(EXESUF): qemu-nbd.o qemu-tool.o $(block-obj-y) $(qobject-obj-y)
>  >>  +qemu-nbd$(EXESUF): qemu-nbd.o qemu-tool.o qemu-error.o $(block-obj-y) $(qobject-obj-y)
>  >>
>  >>  -qemu-io$(EXESUF): qemu-io.o qemu-tool.o cmd.o $(block-obj-y) $(qobject-obj-y)
>  >>  +qemu-io$(EXESUF): qemu-io.o cmd.o qemu-tool.o qemu-error.o $(block-obj-y) $(qobject-obj-y)
>  >>
>  >>   qemu-img-cmds.h: $(SRC_PATH)/qemu-img-cmds.hx
>  >>         $(call quiet-command,sh $(SRC_PATH)/hxtool -h < $< > $@,"  GEN   $@")
>  >>  diff --git a/qemu-tool.c b/qemu-tool.c
>  >>  index 97ca949..8d6d0ef 100644
>  >>  --- a/qemu-tool.c
>  >>  +++ b/qemu-tool.c
>  >>  @@ -15,7 +15,6 @@
>  >>   #include "monitor.h"
>  >>   #include "qemu-timer.h"
>  >>   #include "qemu-log.h"
>  >>  -#include "qemu-error.h"
>  >>
>  >>   #include <sys/time.h>
>  >>
>  >>  @@ -33,6 +32,22 @@ void qemu_service_io(void)
>  >>   {
>  >>   }
>  >>
>  >>  +Monitor *cur_mon;
>  >>  +
>  >>  +int monitor_cur_is_qmp(void)
>  >>  +{
>  >>  +    return 0;
>  >>  +}
>  >>  +
>  >>  +void monitor_set_error(Monitor *mon, QError *qerror)
>  >>  +{
>  >>  +    assert(0);
>  >
>  > Please use abort().
>
>
> Why?

Because assert(0) does not abort when compiled with -DNDEBUG.

  reply	other threads:[~2010-03-18 17:58 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-17 17:56 [Qemu-devel] [PATCH 0/6] error: Clean up after recent changes Markus Armbruster
2010-03-17 17:56 ` [Qemu-devel] [PATCH 1/6] error: Trim includes after "Move qemu_error & friends..." Markus Armbruster
2010-03-18 21:30   ` [Qemu-devel] " Luiz Capitulino
2010-03-19 21:31     ` Markus Armbruster
2010-03-22  0:40       ` Luiz Capitulino
2010-03-22  8:38         ` Markus Armbruster
2010-03-17 17:56 ` [Qemu-devel] [PATCH 2/6] error: Trim includes in qerror.c Markus Armbruster
2010-03-18 21:32   ` [Qemu-devel] " Luiz Capitulino
2010-03-19 21:33     ` Markus Armbruster
2010-03-22  0:38       ` Luiz Capitulino
2010-03-17 17:56 ` [Qemu-devel] [PATCH 3/6] error: Trim includes after "Infrastructure to track locations..." Markus Armbruster
2010-03-17 17:56 ` [Qemu-devel] [PATCH 4/6] error: Make use of error_set_progname() optional Markus Armbruster
2010-03-17 17:56 ` [Qemu-devel] [PATCH 5/6] error: Link qemu-img, qemu-nbd, qemu-io with qemu-error.o Markus Armbruster
2010-03-17 19:53   ` Blue Swirl
2010-03-17 21:17     ` Markus Armbruster
2010-03-18 17:58       ` Blue Swirl [this message]
2010-03-18 18:09         ` Markus Armbruster
2010-03-18 18:20           ` Blue Swirl
2010-03-18 18:55             ` Markus Armbruster
2010-03-18 19:32               ` Blue Swirl
2010-03-22  9:37                 ` Markus Armbruster
2010-03-17 17:56 ` [Qemu-devel] [PATCH 6/6] error: Move qerror_report() from qemu-error.[ch] to qerror.[ch] Markus Armbruster

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=f43fc5581003181058j1020f6e2x419e35b51ab11763@mail.gmail.com \
    --to=blauwirbel@gmail.com \
    --cc=armbru@redhat.com \
    --cc=lcapitulino@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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).