[PATCH 2/5] virsh: domain: refactoring of small functions

Ján Tomko jtomko at redhat.com
Thu Sep 23 16:13:02 UTC 2021


On a Thursday in 2021, Kristina Hanicova wrote:
>This patch includes:
>* fix of a mistake in cmdMigrateSetMaxDowntime() - function
>  returned false when it should have returned true

Ideally, refactors should not alter behavior, so fixes should be
separated.

Jano

>* use of an early return in case of an error
>* removal of unnecessary variables and extra labels
>* returning value directly
>
>Signed-off-by: Kristina Hanicova <khanicov at redhat.com>
>---
> tools/virsh-domain.c | 250 +++++++++++++++++--------------------------
> 1 file changed, 98 insertions(+), 152 deletions(-)
>
-------------- 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/20210923/960d0a73/attachment-0001.sig>


More information about the libvir-list mailing list