diff options
Diffstat (limited to 'main.py')
-rwxr-xr-x | main.py | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -186,11 +186,13 @@ def _Main(argv): | |||
186 | repo._Run(argv) | 186 | repo._Run(argv) |
187 | except KeyboardInterrupt: | 187 | except KeyboardInterrupt: |
188 | sys.exit(1) | 188 | sys.exit(1) |
189 | except RepoChangedException: | 189 | except RepoChangedException, rce: |
190 | # If the repo or manifest changed, re-exec ourselves. | 190 | # If repo changed, re-exec ourselves. |
191 | # | 191 | # |
192 | argv = list(sys.argv) | ||
193 | argv.extend(rce.extra_args) | ||
192 | try: | 194 | try: |
193 | os.execv(__file__, sys.argv) | 195 | os.execv(__file__, argv) |
194 | except OSError, e: | 196 | except OSError, e: |
195 | print >>sys.stderr, 'fatal: cannot restart repo after upgrade' | 197 | print >>sys.stderr, 'fatal: cannot restart repo after upgrade' |
196 | print >>sys.stderr, 'fatal: %s' % e | 198 | print >>sys.stderr, 'fatal: %s' % e |