[PULL,15/25] python/qemu/qmp: use True/False for non/blocking modes
diff mbox series

Message ID 20200531163846.25363-16-philmd@redhat.com
State New
Headers show
  • [PULL,01/25] scripts/qemugdb: Remove shebang header
Related show

Commit Message

Philippe Mathieu-Daudé May 31, 2020, 4:38 p.m. UTC
From: John Snow <jsnow@redhat.com>

The type system doesn't want integers.

Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20200514055403.18902-15-jsnow@redhat.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
 python/qemu/qmp.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff mbox series

diff --git a/python/qemu/qmp.py b/python/qemu/qmp.py
index b91c9d5c1c..a634c4e26c 100644
--- a/python/qemu/qmp.py
+++ b/python/qemu/qmp.py
@@ -120,14 +120,14 @@  def __get_events(self, wait=False):
         # Check for new events regardless and pull them into the cache:
-        self.__sock.setblocking(0)
+        self.__sock.setblocking(False)
         except OSError as err:
             if err.errno == errno.EAGAIN:
                 # No data available
-        self.__sock.setblocking(1)
+        self.__sock.setblocking(True)
         # Wait for new events, if needed.
         # if wait is 0.0, this means "no wait" and is also implicitly false.