comparison mercurial/debugcommands.py @ 45837:b7b8a1538161

httpservice: move sys.exit() out of serve_forever() This is a simple refactoring to show the callers of the method, so it's easier to reason about the impact of removing the `sys.exit()` calls in subsequent patches. Differential Revision: https://phab.mercurial-scm.org/D9270
author Martin von Zweigbergk <martinvonz@google.com>
date Tue, 03 Nov 2020 20:18:26 -0800
parents 0428978bca22
children d6279c43fc60
comparison
equal deleted inserted replaced
45836:58e7ee23ddbd 45837:b7b8a1538161
3374 elif opts[b'logiofile']: 3374 elif opts[b'logiofile']:
3375 logfh = open(opts[b'logiofile'], b'ab', 0) 3375 logfh = open(opts[b'logiofile'], b'ab', 0)
3376 3376
3377 s = wireprotoserver.sshserver(ui, repo, logfh=logfh) 3377 s = wireprotoserver.sshserver(ui, repo, logfh=logfh)
3378 s.serve_forever() 3378 s.serve_forever()
3379 sys.exit(0)
3379 3380
3380 3381
3381 @command(b'debugsetparents', [], _(b'REV1 [REV2]')) 3382 @command(b'debugsetparents', [], _(b'REV1 [REV2]'))
3382 def debugsetparents(ui, repo, rev1, rev2=None): 3383 def debugsetparents(ui, repo, rev1, rev2=None):
3383 """manually set the parents of the current working directory 3384 """manually set the parents of the current working directory