qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH 5/5] hw: Remove mentions of NDEBUG


From: Richard Henderson
Subject: Re: [PATCH 5/5] hw: Remove mentions of NDEBUG
Date: Tue, 21 Feb 2023 14:10:03 -1000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.7.1

On 2/21/23 13:25, Philippe Mathieu-Daudé wrote:
Since commit 262a69f428 ("osdep.h: Prohibit disabling
assert() in supported builds") 'NDEBUG' can not be defined.

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
  hw/scsi/mptsas.c   | 2 --
  hw/virtio/virtio.c | 2 --
  2 files changed, 4 deletions(-)

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~


diff --git a/hw/scsi/mptsas.c b/hw/scsi/mptsas.c
index c485da792c..5b373d3ed6 100644
--- a/hw/scsi/mptsas.c
+++ b/hw/scsi/mptsas.c
@@ -1240,8 +1240,6 @@ static void *mptsas_load_request(QEMUFile *f, SCSIRequest 
*sreq)
      n = qemu_get_be32(f);
      /* TODO: add a way for SCSIBusInfo's load_request to fail,
       * and fail migration instead of asserting here.
-     * This is just one thing (there are probably more) that must be
-     * fixed before we can allow NDEBUG compilation.
       */
      assert(n >= 0);
diff --git a/hw/virtio/virtio.c b/hw/virtio/virtio.c
index f35178f5fc..c6b3e3fb08 100644
--- a/hw/virtio/virtio.c
+++ b/hw/virtio/virtio.c
@@ -1898,8 +1898,6 @@ void *qemu_get_virtqueue_element(VirtIODevice *vdev, 
QEMUFile *f, size_t sz)
/* TODO: teach all callers that this can fail, and return failure instead
       * of asserting here.
-     * This is just one thing (there are probably more) that must be
-     * fixed before we can allow NDEBUG compilation.
       */
      assert(ARRAY_SIZE(data.in_addr) >= data.in_num);
      assert(ARRAY_SIZE(data.out_addr) >= data.out_num);




reply via email to

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