On Tue, May 28, 2019 at 09:58:45AM -0500, Eric Blake wrote:
h.zero (64*1024, 0, nbd.CMD_FLAG_FUA, nbd.CMD_FLAG_NO_HOLE)
instead (two arguments, each with one flag, which the glue code then
combines into a single integer; compared to the existing approach of
letting Python do the bitwise math and pass in a single integer up front).
We check the Flags argument appears only once at the end, but while
that means this is possible it will make the generator a bit more
complicated because it loses the one-to-one mapping of args with
Python arguments.
Rich.
--
Richard Jones, Virtualization Group, Red Hat
http://people.redhat.com/~rjones
Read my programming and virtualization blog:
http://rwmj.wordpress.com
virt-builder quickly builds VMs from scratch
http://libguestfs.org/virt-builder.1.html