|
a/src/mediaserver/cdplugins/uprcl/uprclfolders.py |
|
b/src/mediaserver/cdplugins/uprcl/uprclfolders.py |
|
... |
|
... |
346 |
return "/"
|
346 |
return "/"
|
347 |
|
347 |
|
348 |
lpath = []
|
348 |
lpath = []
|
349 |
while True:
|
349 |
while True:
|
350 |
fathidx = self._dirvec[diridx][".."][0]
|
350 |
fathidx = self._dirvec[diridx][".."][0]
|
|
|
351 |
found = False
|
351 |
for nm, ids in self._dirvec[fathidx].items():
|
352 |
for nm, ids in self._dirvec[fathidx].items():
|
352 |
if ids[0] == diridx:
|
353 |
if ids[0] == diridx:
|
353 |
lpath.append(nm)
|
354 |
lpath.append(nm)
|
|
|
355 |
found = True
|
354 |
break
|
356 |
break
|
|
|
357 |
# End for
|
|
|
358 |
if not found:
|
|
|
359 |
uplog("uprclfolders: pwd failed for %s \
|
|
|
360 |
(father not found), returning /" % objid)
|
|
|
361 |
return "/"
|
|
|
362 |
if len(lpath) > 200:
|
|
|
363 |
uplog("uprclfolders: pwd failed for %s \
|
|
|
364 |
(looping), returning /" % objid)
|
|
|
365 |
return "/"
|
|
|
366 |
|
355 |
diridx = fathidx
|
367 |
diridx = fathidx
|
356 |
if diridx == 0:
|
368 |
if diridx == 0:
|
357 |
break
|
369 |
break
|
358 |
|
370 |
|
359 |
if not lpath:
|
371 |
if not lpath:
|
360 |
path = "/"
|
372 |
path = "/"
|
361 |
else:
|
373 |
else:
|
362 |
path = ""
|
374 |
path = ""
|