Show More
@@ -539,10 +539,12 b' def push(repo, remote, force=False, revs' | |||
|
539 | 539 | # get lock as we might write phase data |
|
540 | 540 | wlock = lock = None |
|
541 | 541 | try: |
|
542 |
# bundle2 push may receive a reply bundle touching bookmarks |
|
|
543 |
# |
|
|
542 | # bundle2 push may receive a reply bundle touching bookmarks | |
|
543 | # requiring the wlock. Take it now to ensure proper ordering. | |
|
544 | 544 | maypushback = pushop.ui.configbool('experimental', 'bundle2.pushback') |
|
545 |
if (not _forcebundle1(pushop)) and |
|
|
545 | if ((not _forcebundle1(pushop)) and | |
|
546 | maypushback and | |
|
547 | not bookmod.bookmarksinstore(repo)): | |
|
546 | 548 | wlock = pushop.repo.wlock() |
|
547 | 549 | lock = pushop.repo.lock() |
|
548 | 550 | pushop.trmanager = transactionmanager(pushop.repo, |
@@ -1548,7 +1550,10 b' def pull(repo, remote, heads=None, force' | |||
|
1548 | 1550 | raise error.Abort(msg) |
|
1549 | 1551 | |
|
1550 | 1552 | pullop.trmanager = transactionmanager(repo, 'pull', remote.url()) |
|
1551 | with repo.wlock(), repo.lock(), pullop.trmanager: | |
|
1553 | wlock = util.nullcontextmanager() | |
|
1554 | if not bookmod.bookmarksinstore(repo): | |
|
1555 | wlock = repo.wlock() | |
|
1556 | with wlock, repo.lock(), pullop.trmanager: | |
|
1552 | 1557 | # Use the modern wire protocol, if available. |
|
1553 | 1558 | if remote.capable('command-changesetdata'): |
|
1554 | 1559 | exchangev2.pull(pullop) |
@@ -2395,7 +2400,8 b' def unbundle(repo, cg, heads, source, ur' | |||
|
2395 | 2400 | try: |
|
2396 | 2401 | def gettransaction(): |
|
2397 | 2402 | if not lockandtr[2]: |
|
2398 |
|
|
|
2403 | if not bookmod.bookmarksinstore(repo): | |
|
2404 | lockandtr[0] = repo.wlock() | |
|
2399 | 2405 | lockandtr[1] = repo.lock() |
|
2400 | 2406 | lockandtr[2] = repo.transaction(source) |
|
2401 | 2407 | lockandtr[2].hookargs['source'] = source |
General Comments 0
You need to be logged in to leave comments.
Login now