]> git.ipfire.org Git - thirdparty/libvirt.git/commit
virPolkitCheckAuth: Avoid virStringListLength in loop condition
authorPeter Krempa <pkrempa@redhat.com>
Fri, 5 Feb 2021 16:53:05 +0000 (17:53 +0100)
committerPeter Krempa <pkrempa@redhat.com>
Thu, 11 Feb 2021 16:05:34 +0000 (17:05 +0100)
commit1114cf5e7e2238b124172774444f0df73f2b29bf
treefc8043fd1b6aa7341ce65fe74a99b9c8f8cf1638
parent2f9b2c0cdd911382c6f5fb081c5c33d768f3500b
virPolkitCheckAuth: Avoid virStringListLength in loop condition

Don't re-calculate the string list length on every iteration. Convert
the loop to NULL-terminated iteration.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
src/util/virpolkit.c