[unpackfs] Stub of special handling for a single file

This commit is contained in:
Adriaan de Groot 2019-10-08 15:00:25 +02:00
parent 65b81f84a5
commit d58fdaa2cd

View File

@ -303,6 +303,10 @@ class UnpackOperation:
try:
if entry.is_file():
source = entry.source
if entry.total <= 1:
# If there is one file, *and* the target does not exist (as a file or dir)
# but the dirname of the target does, we should copy just one file and rename.
pass
else:
source = imgmountdir