qmp: fix __accept() in qmp.py
PATCH 1/1 qmp: fix __accept() in qmp.py
In QEMUMonitorProtocol, commit e9d17b6 removed the __sockfile creation from __negotiate_capabilities(), which breaks _accept(). This causes failures in qemu-io python based tests (i.e. tests 030 and 040).
This patch creates the sockfile in __accept() as well.
--- QMP/qmp.py | 1 + 1 file changed, 1 insertion(+)
QMP/qmp.py +1 -0
@@ -96,6 +96,7 @@ class QEMUMonitorProtocol: @raise QMPCapabilitiesError if fails to negotiate capabilities """ self.__sock, _ = self.__sock.accept() + self.__sockfile = self.__sock.makefile() return self.__negotiate_capabilities() def cmd_obj(self, qmp_cmd):
Signature · 1 line
1.7.11.4
Quoted 15 lines · Jeff Cody
In QEMUMonitorProtocol, commit e9d17b6 removed the
__sockfilecreation from__negotiate_capabilities(), which breaks_accept(). This causes failures in qemu-io python based tests (i.e. tests 030 and 040).This patch creates the sockfile in
__accept()as well.--- QMP/qmp.py | 1 + 1 file changed, 1 insertion(+)QMP/qmp.py +0
-0
QMP/qmp.py class QEMUMonitorProtocol: · line 102
Quoted 7 lines
QMP/qmp.py +1
-0@@ -96,6 +96,7 @@ class QEMUMonitorProtocol: @raise QMPCapabilitiesError if fails to negotiate capabilities """ self.__sock, _ = self.__sock.accept() + self.__sockfile = self.__sock.makefile() return self.__negotiate_capabilities() def cmd_obj(self, qmp_cmd):
Forgot the Signed-off-by: on this one, resending