diff options
author | Marc-André Lureau <marcandre.lureau@redhat.com> | 2022-03-23 19:57:20 +0400 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2022-04-06 10:50:38 +0200 |
commit | d709bbf3b17f43c91e82c3807a39f2c349d27934 (patch) | |
tree | 30e0ae475c7716d412000b7c2403092363a8afaf /qobject/qnum.c | |
parent | 7773e13fa729bbd2b106121b6c63b11a46c7d0c4 (diff) | |
download | qemu-d709bbf3b17f43c91e82c3807a39f2c349d27934.zip qemu-d709bbf3b17f43c91e82c3807a39f2c349d27934.tar.gz qemu-d709bbf3b17f43c91e82c3807a39f2c349d27934.tar.bz2 |
include/qapi: add g_autoptr support for qobject types
Need wrappers for qobject_unref() calls, which is a macro.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20220323155743.1585078-10-marcandre.lureau@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'qobject/qnum.c')
-rw-r--r-- | qobject/qnum.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/qobject/qnum.c b/qobject/qnum.c index 5dd6693..2bbeaed 100644 --- a/qobject/qnum.c +++ b/qobject/qnum.c @@ -239,3 +239,8 @@ void qnum_destroy_obj(QObject *obj) assert(obj != NULL); g_free(qobject_to(QNum, obj)); } + +void qnum_unref(QNum *q) +{ + qobject_unref(q); +} |