changeset 28603:f467073cd798

chgserver: drop bundle.mainreporoot config Before this patch, although chgserver drops repo object by setting it to None, there is another side effect loading a repo: setting bundle.mainreporoot. This patch explicitly sets it to empty to undo the side effect. It will make chg pass test-strip.t.
author Jun Wu <quark@fb.com>
date Sun, 20 Mar 2016 15:11:34 -0700
parents 83127a9fe76e
children d4d8a3c89e6d
files hgext/chgserver.py
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/chgserver.py	Sun Mar 20 10:44:15 2016 -0700
+++ b/hgext/chgserver.py	Sun Mar 20 15:11:34 2016 -0700
@@ -640,7 +640,10 @@
 
 class chgunixservice(commandserver.unixservice):
     def init(self):
-        self.repo = None
+        if self.repo:
+            # one chgserver can serve multiple repos. drop repo infomation
+            self.ui.setconfig('bundle', 'mainreporoot', '', 'repo')
+            self.repo = None
         self._inithashstate()
         self._checkextensions()
         class cls(AutoExitMixIn, SocketServer.ForkingMixIn,