Skip to content

Commit

Permalink
Fix signal handling that didn't work on Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
bernardnormier committed Jan 19, 2021
1 parent 3ce1789 commit e1258b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/Ice/async/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ async def main():
loop = asyncio.get_running_loop()

# Install a signal handler to initiate communicator shutdown on Ctrl+C.
loop.add_signal_handler(signal.SIGINT, communicator.shutdown)
signal.signal(signal.SIGINT, lambda signum, frame: communicator.shutdown())

adapter = communicator.createObjectAdapter("Hello")
adapter.add(HelloI(loop), Ice.stringToIdentity("hello"))
Expand Down

0 comments on commit e1258b3

Please sign in to comment.