Closed jernst closed 3 years ago
This appears to be a rather strange bug inside Perl::Archive::Zip::Member.pm
sub _writeData
. More investigation required.
Also, we should add symlinks via code like this:
my $newMember = Archive::Zip::Member->newFromString(readlink $fileName, $newName);
$newMember->{'externalFileAttributes'} = 0xA1FF0000;
$self->addMember($newMember);
(from Archive::Zip)
This test data reproduces the problem:
drwxr-xr-x 1 http http 40 Jan 10 04:31 /ubos/lib/nextcloud/a26fd59cbd3fe71fec094976a3b38dd38daab1a5d/data/admin/files
drwxr-xr-x 1 http http 20 Jan 10 04:33 '/ubos/lib/nextcloud/a26fd59cbd3fe71fec094976a3b38dd38daab1a5d/data/admin/files/dir with space'
lrwxrwxrwx 1 root root 3 Jan 10 04:33 '/ubos/lib/nextcloud/a26fd59cbd3fe71fec094976a3b38dd38daab1a5d/data/admin/files/dir with space/Thumbnails' -> xyz
lrwxrwxrwx 1 root root 14 Jan 10 04:31 /ubos/lib/nextcloud/a26fd59cbd3fe71fec094976a3b38dd38daab1a5d/data/admin/files/foobar -> 'dir with space'
but somehow we need to have all of those components.
And