[Libguestfs] [PATCH] builder, sysprep: initialise the random generator

Richard W.M. Jones rjones at redhat.com
Tue Jan 28 14:51:02 UTC 2014


On Tue, Jan 28, 2014 at 03:10:29PM +0100, Pino Toscano wrote:
> virt-builder and virt-sysprep may make use of
> Common_utils.string_random8 (which uses Random.int) for constructing
> temporary paths; not initialising the random generator means that every
> invocation will reuse the same name used previously (!).
> Thus just call Random.self_init, just like virt-sparsify already does.
> 
> Expand the test-virt-sysprep-script.sh test to ensure that virt-sysprep
> is not affected again by this issue.

ACK.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Fedora Windows cross-compiler. Compile Windows programs, test, and
build Windows installers. Over 100 libraries supported.
http://fedoraproject.org/wiki/MinGW




More information about the Libguestfs mailing list