Show More
@@ -102,6 +102,7 class SimpleHg(object): | |||
|
102 | 102 | return HTTPForbidden()(environ, start_response) |
|
103 | 103 | |
|
104 | 104 |
#log action |
|
105 | if action in ('push', 'pull', 'clone'): | |
|
105 | 106 | proxy_key = 'HTTP_X_REAL_IP' |
|
106 | 107 | def_key = 'REMOTE_ADDR' |
|
107 | 108 | ipaddr = environ.get(proxy_key, environ.get(def_key, '0.0.0.0')) |
@@ -165,14 +166,14 class SimpleHg(object): | |||
|
165 | 166 | |
|
166 | 167 | def __get_action(self, environ): |
|
167 | 168 | """ |
|
168 | Maps mercurial request commands into a pull or push command. | |
|
169 |
This should return |
|
|
169 | Maps mercurial request commands into a clone,pull or push command. | |
|
170 | This should always return a valid command string | |
|
170 | 171 | :param environ: |
|
171 | 172 | """ |
|
172 | 173 | mapping = {'changegroup': 'pull', |
|
173 | 174 | 'changegroupsubset': 'pull', |
|
174 | 175 | 'stream_out': 'pull', |
|
175 | 'listkeys': 'pull', | |
|
176 | #'listkeys': 'pull', | |
|
176 | 177 | 'unbundle': 'push', |
|
177 | 178 | 'pushkey': 'push', } |
|
178 | 179 | for qry in environ['QUERY_STRING'].split('&'): |
General Comments 0
You need to be logged in to leave comments.
Login now