From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55156) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dtIBi-0004yG-Kf for qemu-devel@nongnu.org; Sat, 16 Sep 2017 14:51:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dtIBh-0000SE-St for qemu-devel@nongnu.org; Sat, 16 Sep 2017 14:51:34 -0400 From: Max Reitz Date: Sat, 16 Sep 2017 20:51:19 +0200 Message-Id: <20170916185123.29255-3-mreitz@redhat.com> In-Reply-To: <20170916185123.29255-1-mreitz@redhat.com> References: <20170916185123.29255-1-mreitz@redhat.com> Subject: [Qemu-devel] [PATCH v5 2/6] qapi/qlist: Add qlist_append_null() macro List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, Max Reitz , Markus Armbruster , Eric Blake , Kevin Wolf Signed-off-by: Max Reitz --- include/qapi/qmp/qlist.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/qapi/qmp/qlist.h b/include/qapi/qmp/qlist.h index c4b5fdad9b..59d209bbae 100644 --- a/include/qapi/qmp/qlist.h +++ b/include/qapi/qmp/qlist.h @@ -15,6 +15,7 @@ #include "qapi/qmp/qobject.h" #include "qapi/qmp/qnum.h" +#include "qapi/qmp/qnull.h" #include "qemu/queue.h" typedef struct QListEntry { @@ -37,6 +38,8 @@ typedef struct QList { qlist_append(qlist, qbool_from_bool(value)) #define qlist_append_str(qlist, value) \ qlist_append(qlist, qstring_from_str(value)) +#define qlist_append_null(qlist) \ + qlist_append(qlist, qnull()) #define QLIST_FOREACH_ENTRY(qlist, var) \ for ((var) = ((qlist)->head.tqh_first); \ -- 2.13.5