[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2 12/14] qlit: improve QLit list vs qlist compa
From: |
Marc-André Lureau |
Subject: |
Re: [Qemu-devel] [PATCH v2 12/14] qlit: improve QLit list vs qlist comparison |
Date: |
Thu, 31 Aug 2017 10:37:48 -0400 (EDT) |
Hi
----- Original Message -----
> Markus Armbruster <address@hidden> writes:
>
> > Marc-André Lureau <address@hidden> writes:
> >
> >> Use QLIST_FOREACH_ENTRY() to simplify the code and break earlier.
> >>
> >> Check that the QLit list has the same size as the qlist, this should
> >> ensure that we have an exact match when iterating over qlist for
> >> comparing the elements.
> >>
> >> Signed-off-by: Marc-André Lureau <address@hidden>
> >
> > Reviewed-by: Markus Armbruster <address@hidden>
>
> I'm updating the commit message so it continues to match the previous
> commit's message:
>
> qlit: Tighten QLit list vs QList comparison
>
> We check that all members of the QLit list are also in the QList. We
> neglect to check the other direction. Fix that.
>
> While there, use QLIST_FOREACH_ENTRY() to simplify the code and break
> the loop on the first mismatch.
>
> Hope that's okay with you.
Works for me, thanks a lot.