tools/minidumpserver: don't stop while gdb client is stopping

VELAPLATFO-16411

Signed-off-by: xinbingnan <xinbingnan@xiaomi.com>
This commit is contained in:
xinbingnan 2023-09-12 10:22:10 +08:00 committed by Xiang Xiao
parent d98367693d
commit 75e591ae4f

View File

@ -648,14 +648,16 @@ if __name__ == "__main__":
gdbserver.listen(1)
logger.info(f"Waiting GDB connection on port {args.port} ...")
logger.info("Press Ctrl+C to stop ...")
conn, remote = gdbserver.accept()
while True:
try:
conn, remote = gdbserver.accept()
if conn:
logger.info(f"Accepted GDB connection from {remote}")
gdbstub.run(conn)
conn.close()
if conn:
logger.info(f"Accepted GDB connection from {remote}")
gdbstub.run(conn)
except KeyboardInterrupt:
break
gdbserver.close()