On Wed, Jul 29, 2009 at 9:18 AM, Avi Kivity<a...@redhat.com> wrote:
> On 07/16/2009 01:26 PM, Yolkfull Chow wrote:
>>
>> Signed-off-by: Yolkfull Chow<yz...@redhat.com>
>> ---
>>  client/tests/kvm/kvm_vm.py |   11 +++++++++++
>>  1 files changed, 11 insertions(+), 0 deletions(-)
>>
>> diff --git a/client/tests/kvm/kvm_vm.py b/client/tests/kvm/kvm_vm.py
>> index 503f636..895049e 100644
>> --- a/client/tests/kvm/kvm_vm.py
>> +++ b/client/tests/kvm/kvm_vm.py
>> @@ -113,6 +113,13 @@ class VM:
>>          self.qemu_path = qemu_path
>>          self.image_dir = image_dir
>>          self.iso_dir = iso_dir
>> +
>> +        if params.get("uuid"):
>> +            if params.get("uuid") == "random":
>> +                uuid = os.popen("cat
>> /proc/sys/kernel/random/uuid").readline()
>> +                self.uuid = uuid.strip()
>>
>
> instead of os.popen("cat ..."), you can open the file directly:
>
>   uuid = file('/proc/.../uuid').readline()

Oooops... I didn't notice this little issue. Will make a quick patch
to change it, thanks Avi!
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to