equal
deleted
inserted
replaced
196 The extension (e.g. '.i' or '.d') is preserved. |
196 The extension (e.g. '.i' or '.d') is preserved. |
197 |
197 |
198 The string 'data/' at the beginning is replaced with 'dh/', if the hashed |
198 The string 'data/' at the beginning is replaced with 'dh/', if the hashed |
199 encoding was used. |
199 encoding was used. |
200 ''' |
200 ''' |
201 if not path.startswith('data/'): |
|
202 return path |
|
203 res = '/'.join(auxencode(encodefilename(path))) |
201 res = '/'.join(auxencode(encodefilename(path))) |
204 if len(res) > _maxstorepathlen: |
202 if len(res) > _maxstorepathlen: |
205 path = encodedir(path) |
203 path = encodedir(path) |
206 digest = _sha(path).hexdigest() |
204 digest = _sha(path).hexdigest() |
207 parts = auxencode(lowerencode(path))[1:] |
205 parts = auxencode(lowerencode(path))[1:] |