[libvirt] [PATCH 2/2] virsh: kill over-engineered asprintf failure recovery

Eric Blake eblake at redhat.com
Mon Feb 24 18:56:45 UTC 2014


On 02/24/2014 10:42 AM, Michal Privoznik wrote:
> On 21.02.2014 23:59, Eric Blake wrote:
>> I noticed this while shortning switch statements via VIR_ENUM.
>> Basically, the only ways virAsprintf can fail are if we pass a
>> bogus format string (but we're not THAT bad) or if we run out
>> of memory (but it already warns on our behalf in that case).
>> Throw away the cruft that tries too hard to diagnose a printf
>> failure.
>>
>> * tools/virsh-volume.c (cmdVolList): Simplify.
>> * tools/virsh-pool.c (cmdPoolList): Likewise.
>>
>> Signed-off-by: Eric Blake <eblake at redhat.com>
>> ---
>>   tools/virsh-pool.c   | 73
>> +++++++++++++++++-----------------------------------
>>   tools/virsh-volume.c | 66
>> ++++++++++++++---------------------------------
>>   2 files changed, 42 insertions(+), 97 deletions(-)
> 
> ACK

Thanks; I pushed the series.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 604 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20140224/c66f9463/attachment-0001.sig>


More information about the libvir-list mailing list