aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2019-11-26 15:10:45 +0000
committerPeter Maydell <peter.maydell@linaro.org>2019-11-26 15:10:45 +0000
commit3c48f6daeda5a364ff04e24b3d99d26fba9c0250 (patch)
tree1438fc8f937e4aa897e6f2444c5eb4a3a16b662c
parent8e6a243a85faf25fc277211e1695fbcabb5edaa0 (diff)
parente8d0ac5801edda91412e52fb82f291eed5171c2c (diff)
Merge remote-tracking branch 'remotes/ehabkost/tags/python-next-pull-request' into staging
vmstate-static-checker fix for 4.2 # gpg: Signature made Mon 25 Nov 2019 22:51:23 GMT # gpg: using RSA key 5A322FD5ABC4D3DBACCFD1AA2807936F984DC5A6 # gpg: issuer "ehabkost@redhat.com" # gpg: Good signature from "Eduardo Habkost <ehabkost@redhat.com>" [full] # Primary key fingerprint: 5A32 2FD5 ABC4 D3DB ACCF D1AA 2807 936F 984D C5A6 * remotes/ehabkost/tags/python-next-pull-request: vmstate-static-checker: Fix for current python Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
-rwxr-xr-xscripts/vmstate-static-checker.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/scripts/vmstate-static-checker.py b/scripts/vmstate-static-checker.py
index d3467288dc..f8b7b8f772 100755
--- a/scripts/vmstate-static-checker.py
+++ b/scripts/vmstate-static-checker.py
@@ -375,9 +375,11 @@ def main():
help_text = "Parse JSON-formatted vmstate dumps from QEMU in files SRC and DEST. Checks whether migration from SRC to DEST QEMU versions would break based on the VMSTATE information contained within the JSON outputs. The JSON output is created from a QEMU invocation with the -dump-vmstate parameter and a filename argument to it. Other parameters to QEMU do not matter, except the -M (machine type) parameter."
parser = argparse.ArgumentParser(description=help_text)
- parser.add_argument('-s', '--src', type=file, required=True,
+ parser.add_argument('-s', '--src', type=argparse.FileType('r'),
+ required=True,
help='json dump from src qemu')
- parser.add_argument('-d', '--dest', type=file, required=True,
+ parser.add_argument('-d', '--dest', type=argparse.FileType('r'),
+ required=True,
help='json dump from dest qemu')
parser.add_argument('--reverse', required=False, default=False,
action='store_true',