OSDN Git Service

qcow2_format.py: drop new line printing at end of dump()
authorVladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Sat, 6 Jun 2020 08:17:57 +0000 (11:17 +0300)
committerEric Blake <eblake@redhat.com>
Tue, 9 Jun 2020 20:47:09 +0000 (15:47 -0500)
This will simplify further conversion. To compensate, print this empty
line directly in cmd_dump_header().

Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: Andrey Shinkevich <andrey.shinkevich@virtuozzo.com>
Message-Id: <20200606081806.23897-5-vsementsov@virtuozzo.com>
Signed-off-by: Eric Blake <eblake@redhat.com>
tests/qemu-iotests/qcow2.py
tests/qemu-iotests/qcow2_format.py

index e968869..8c187e9 100755 (executable)
@@ -27,6 +27,7 @@ from qcow2_format import (
 def cmd_dump_header(fd):
     h = QcowHeader(fd)
     h.dump()
+    print()
     h.dump_extensions()
 
 
index 0e517c1..2b6c961 100644 (file)
@@ -155,7 +155,6 @@ class QcowHeader:
                 value_str = f[1] % value
 
             print("%-25s" % f[2], value_str)
-        print("")
 
     def dump_extensions(self):
         for ex in self.extensions: