On Mon, 2018-10-08 at 13:09 +0100, Daniel P. Berrangé wrote:
This patch is doing two things. It is moving the code block earlier,
to let you drop the duplicated virQEMUCapsCacheLookup(). Second it is
removing the array iteration & just checking one single path instead.
I'd suggest we keep the array iteration, and just move the code.
The patch has already been merged, so you'd have to partially revert
it to achieve what you suggest.
As explained elsewhere in the thread, the probability we would ever
need more than one entry in the array is basically zero, so why have
it? If it ever comes the time when we actually need a second entry,
then sure, but now? Just in case? That's pretty much a textbook
example of over-engineering IMHO.
Anyway, I feel like I've spent way too much time arguing over what
is ultimately a very, very minor detail already, and at the end of
the day I just don't care enough to spend more energy on it. If
either you or Peter want to reintroduce the array, then by all means
go ahead.
--
Andrea Bolognani / Red Hat / Virtualization