[libvirt] [PATCH] virsh: change printf() calls to vshPrint()

Eric Blake eblake at redhat.com
Wed Jun 16 23:21:41 UTC 2010


On 06/16/2010 06:10 AM, Daniel P. Berrange wrote:
> On Wed, Jun 16, 2010 at 03:25:05PM +1000, Justin Clift wrote:
>> Trivial fix changing printf() calls to vshPrint() where the ctl
>> variable is available.
>> ---
>>
>> Haven't created a BZ for this yet, as I'm not sure it's important enough
>> to warrant pushing into anything other than git head.
>>
>> Should a BZ be created anyway?

Nah; since it's just cosmetic, there's no reason to file a BZ against
RHEL-6, and there's no problem if we don't backport it.

>>              case VIR_DOMAIN_SCHED_FIELD_INT:
>> -                 printf("%-15s: %d\n",  params[i].field, params[i].value.i);
>> +                 vshPrint(ctl, "%-15s: %d\n",  params[i].field, params[i].value.i);
> 
> ACK, looks fine to me. Though I do wonder why we bother having a wrapper
> around printf at all, given that it just does
> 
>   #define vshPrint(_ctl, ...)   fprintf(stdout, __VA_ARGS__)
> 
> but that's a story for another day :-)

Pushed now to git head.

-- 
Eric Blake   eblake at redhat.com    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

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


More information about the libvir-list mailing list