python/machine.py: Close QMP socket in cleanup