qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH 4/5] migration: Make find_dirty_block() return a single param


From: Juan Quintela
Subject: Re: [PATCH 4/5] migration: Make find_dirty_block() return a single parameter
Date: Tue, 26 Jul 2022 18:23:31 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.1 (gnu/linux)

"Dr. David Alan Gilbert" <dgilbert@redhat.com> wrote:
> * Juan Quintela (quintela@redhat.com) wrote:
>> We used to return two bools, just return a single int with the
>> following meaning:
>> 
>> old return / again / new return
>> false        false   0
>> false        true    1
>> true         true    2  /* We don't care about again at all */
>
> We shouldn't use magic numbers; if you want to return it in a single
> value then it should be an enum so it is clear.

I need to also return an error in the following patches.
I am not sure if it clearer to try to change to an enum.
Will try and see.

Later, Juan.




reply via email to

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