qemu-devel
[Top][All Lists]
Advanced

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

Re: [RFC v2 02/10] Drop unused static function return values


From: Peter Maydell
Subject: Re: [RFC v2 02/10] Drop unused static function return values
Date: Wed, 3 Aug 2022 13:30:13 +0100

On Fri, 29 Jul 2022 at 14:09, Alberto Faria <afaria@redhat.com> wrote:
>
> Make non-void static functions whose return values are ignored by
> all callers return void instead.
>
> These functions were found by static-analyzer.py.
>
> Not all occurrences of this problem were fixed.
>
> Signed-off-by: Alberto Faria <afaria@redhat.com>

>  65 files changed, 248 insertions(+), 403 deletions(-)

The problem with a patch like this is that it rolls up into a
single patch changes to the API of many functions in multiple
subsystems across the whole codebase. Some of those changes
might be right; some might be wrong. No single person is going
to be in a position to review the whole lot, and a +248-403
patch email makes it very unwieldy to try to discuss.

If you want to propose some of these I think you need to:
 * split it out so that you're only suggesting changes in
   one subsystem at a time
 * look at the places you are suggesting changes, to see if
   the correct answer is actually "add the missing error
   check in the caller(s)"
 * not change places that are following standard API patterns
   like "return bool and have an Error** argument"

thanks
-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]