Add dict check for setTime and allow pass 'seconds' parameter
commit3d1d3fd52a60d9ab4159e4f9f8680b92dd7a9866
authorLuyao Huang <lhuang@redhat.com>
Fri, 31 Oct 2014 02:02:16 +0000 (31 10:02 +0800)
committerMichal Privoznik <mprivozn@redhat.com>
Tue, 11 Nov 2014 14:58:12 +0000 (11 15:58 +0100)
tree876d0c5619469eb6b8ea70cd546193cd7690a648
parent8dcdc7f2b4d8ebe7c892a2f92c23f77c59106189
Add dict check for setTime and allow pass 'seconds' parameter

When pass None or a empty dictionary to time, it will report
error. This commit allows a one-element dictionary which contains
just 'seconds' field, which results in the same as passing 0 for
'nseconds' field. Moreover, dict is checked for unknown fields.

Signed-off-by: Luyao Huang <lhuang@redhat.com>
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
libvirt-override-virDomain.py
libvirt-override.c