hg-ssh
changeset 9 21d9048136dc
parent 7 2935e7232bd3
child 10 524b4a45ef0a
equal deleted inserted replaced
8:1efc50c61a26 9:21d9048136dc
    50         fail("Bad glob pattern in auth config: %s" % pattern)
    50         fail("Bad glob pattern in auth config: %s" % pattern)
    51     pattern = pattern.replace(".", r'\.')
    51     pattern = pattern.replace(".", r'\.')
    52     pattern = pattern.replace("*", "[%s]*" % allowedchars)
    52     pattern = pattern.replace("*", "[%s]*" % allowedchars)
    53     return re.compile(pattern + "$").match(match) is not None
    53     return re.compile(pattern + "$").match(match) is not None
    54 
    54 
    55 def testrule(rulefile keyname, path, applicable):
    55 def testrule(rulefile, keyname, path, applicable):
    56     goodpath(keyname)
    56     goodpath(keyname)
    57     goodpath(path)
    57     goodpath(path)
    58     f = open(rulefile)
    58     f = open(rulefile)
    59     try:
    59     try:
    60         for l in f:
    60         for l in f: