On 04/14/2010 10:14 AM, Jim Meyering wrote: > Eric Blake wrote: >> * tests/virt-aa-helper-test (testme): Use printf instead. >> --- >> >> - echo -n " $outstr: " >$output >> - echo -n " '$extra_args $args" >$output >> + printf " $outstr: " >$output >> + printf " '$extra_args $args" >$output > > These are fine if you know that the printf arguments > never (and will never) contain the likes of "%" and "\". > If you add a "%s" argument, then we don't even have to think about it: > > printf %s " $outstr: " >$output > printf %s " '$extra_args $args" >$output Okay, I modified 2/2 to use %s as you suggested, and pushed (I've already ditched 1/2, as discussed elsewhere in the thread). -- Eric Blake eblake@xxxxxxxxxx +1-801-349-2682 Libvirt virtualization library http://libvirt.org
Attachment:
signature.asc
Description: OpenPGP digital signature
-- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list