On 03/10/2014 01:31 AM, Chunyan Liu wrote: > This patch series is to replace QEMUOptionParameter with QemuOpts, so that > only > one Qemu Option structure is kept in QEMU code.
Uggh. The more I learn about QemuOpts while reviewing this patch, the more I KNOW it has lurking bugs waiting to bite us. Case in point: $ touch oddname,id=1 $ qemu-system-x86_64 -drive id=a,file=oddname,,id=1 # starts $ # now, swap the two arguments: $ qemu-system-x86_64 -drive file=oddname,,id=1,id=a qemu-system-x86_64: -drive file=oddname,,id=1,id=a: Parameter 'id' expects an identifier $ Gross. opts_parse uses strncmp() for checking for a leading 'id=', but strstr() for checking for an intermediate ',id='. And strstr() can have false positives, including in the middle of my filename that was properly escaped. This is a long-standing bug - as a bug, you can fix it after freeze, but as it is long-standing, it's not the end of the world if it misses 2.0. But it underscores my plea that this series is not fully baked until you add a testsuite. -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature