|
Lines 2241-2249
def generate_tarball_header(out, name, s
Link Here
|
| 2241 |
out.write(block) |
2241 |
out.write(block) |
| 2242 |
|
2242 |
|
| 2243 |
def generate_tarball_cvs(out, request, tar_top, rep_top, reldir, tag, stack=[]): |
2243 |
def generate_tarball_cvs(out, request, tar_top, rep_top, reldir, tag, stack=[]): |
| 2244 |
if (rep_top == '' and 0 < len(reldir) and |
2244 |
if (0 < len(rep_top) and rep_top[0] == 'CVSROOT' and cfg.options.hide_cvsroot): |
| 2245 |
((reldir[0] == 'CVSROOT' and cfg.options.hide_cvsroot) |
2245 |
return |
| 2246 |
or cfg.is_forbidden(reldir[0]))): |
2246 |
if (0 < len(reldir) and reldir[0] == 'CVSROOT' and cfg.options.hide_cvsroot): |
|
|
2247 |
return |
| 2248 |
|
| 2249 |
if (rep_top == [] and 0 < len(reldir) and cfg.is_forbidden(reldir[0])): |
| 2247 |
return |
2250 |
return |
| 2248 |
|
2251 |
|
| 2249 |
rep_path = rep_top + reldir |
2252 |
rep_path = rep_top + reldir |
|
Lines 2347-2352
def download_tarball(request):
Link Here
|
| 2347 |
query_dict = request.query_dict |
2350 |
query_dict = request.query_dict |
| 2348 |
rep_top = tar_top = request.path_parts |
2351 |
rep_top = tar_top = request.path_parts |
| 2349 |
tag = query_dict.get('only_with_tag') |
2352 |
tag = query_dict.get('only_with_tag') |
|
|
2353 |
if len(rep_top): |
| 2354 |
tar_top = rep_top[-1] |
| 2355 |
if cfg.is_forbidden(tar_top): |
| 2356 |
raise debug.ViewCVSException('Access to "%s" is forbidden.' |
| 2357 |
% tar_top, '403 Forbidden') |
| 2358 |
else: |
| 2359 |
tar_top = request.path_parts |
| 2350 |
|
2360 |
|
| 2351 |
### look for GZIP binary |
2361 |
### look for GZIP binary |
| 2352 |
|
2362 |
|