[PATCH 05/12] qemuAgentGetUsers: Fix return value on success

Ján Tomko jtomko at redhat.com
Mon Mar 16 12:29:08 UTC 2020


On a Monday in 2020, Peter Krempa wrote:
>Return 0 on success as per documentation and due to the fact that
>callers don't check the value.

-EPARSE

Return 0 on success to match the documentation.
The callers only check for negative values.

>
>Signed-off-by: Peter Krempa <pkrempa at redhat.com>
>---
> src/qemu/qemu_agent.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
>diff --git a/src/qemu/qemu_agent.c b/src/qemu/qemu_agent.c
>index bc5d57ab94..c55b989467 100644
>--- a/src/qemu/qemu_agent.c
>+++ b/src/qemu/qemu_agent.c
>@@ -2406,7 +2406,7 @@ qemuAgentGetUsers(qemuAgentPtr agent,
>             return -1;
>     }
>
>-    return ndata;
>+    return 0;
> }
>
> /* Returns: 0 on success

Reviewed-by: Ján Tomko <jtomko at redhat.com>

Jano
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20200316/1b98c353/attachment-0001.sig>


More information about the libvir-list mailing list