]> xenbits.xensource.com Git - libvirt.git/commit
virTypedParamsFilter: Adjust return type and docs
authorPeter Krempa <pkrempa@redhat.com>
Fri, 27 Sep 2024 08:55:00 +0000 (10:55 +0200)
committerPeter Krempa <pkrempa@redhat.com>
Tue, 1 Oct 2024 10:57:02 +0000 (12:57 +0200)
commit933ab93e8f7bb7779717305b602ef5d08cd72bed
treeec19099a28982a447065464cc02cc6423b438240
parent165b30e06a6d14e8719c82af290d3b20e4cbc462
virTypedParamsFilter: Adjust return type and docs

The 'virTypedParamsFilter' function can't fail and thus it never returns
negative values. Change the return type to 'size_t' and adjust callers
to not check the return value for being negative.

Adjust the docs to hilight this and also the fact that the filtered
typed param list returned via @ret is not a deep copy and thus callers
must not use the common function to free it.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
src/util/virtypedparam.c
src/util/virtypedparam.h