~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/store.py

  • Committer: Martin Pool
  • Date: 2005-06-20 03:47:46 UTC
  • Revision ID: mbp@sourcefrog.net-20050620034746-9170a4b9ab12164e
- better check for invalid store ids

Show diffs side-by-side

added added

removed removed

Lines of Context:
68
68
        self._basedir = basedir
69
69
 
70
70
    def _path(self, id):
71
 
        assert '/' not in id
 
71
        if '\\' in id or '/' in id:
 
72
            raise ValueError("invalid store id %r" % id)
72
73
        return os.path.join(self._basedir, id)
73
74
 
74
75
    def __repr__(self):