remote-bzr: fix order of locking in CustomTree