'Strip the chroot if applicable from the path.'

def unchroot(self, path):

    if (not self.chroot):
        return path
    if path.startswith(self.chroot):
        return path[len(self.chroot):]
    else:
        return path
