Re: [PATCH 29/31] virPCIVPDParseVPDLargeResourceFields: Refactor return logic

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On a Tuesday in 2024, Peter Krempa wrote:
Rewrite the conditions after exiting the parser so that they are easier
to understand. This partially decreases the granularity of "error"
messages as they are not strictly necessary albeit for debugging.

As it was already observed in this code the logic itself often does
something else than the comment claims, thus the code logic is
preserved.

Changes:
- any case when not all data was processed is agregated together and

*aggregated

Jano

  gets a common "error" message
- absence of 'checksum' field is checked separately
- helper variables are removed as they are no longer needed

Signed-off-by: Peter Krempa <pkrempa@xxxxxxxxxx>
---
src/util/virpcivpd.c | 32 +++++++++++++-------------------
1 file changed, 13 insertions(+), 19 deletions(-)

Reviewed-by: Ján Tomko <jtomko@xxxxxxxxxx>

Jano

Attachment: signature.asc
Description: PGP signature

_______________________________________________
Devel mailing list -- devel@xxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxx

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux