Skip to content
This repository was archived by the owner on Nov 4, 2024. It is now read-only.

Commit 0c081cf

Browse files
authored
Merge pull request #1562 from sevmonster/patch-1
Properly escape path separator in `tar.php` file list regex
2 parents 9ec8ac8 + c73736a commit 0c081cf

File tree

1 file changed

+1
-1
lines changed
  • snappymail/v/0.0.0/app/libraries/snappymail

1 file changed

+1
-1
lines changed

snappymail/v/0.0.0/app/libraries/snappymail/tar.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ public function extractTo(string $directory, $files = null, bool $overwrite = fa
2929
}
3030

3131
if ($files) {
32-
$files = '/^(' . \implode('|', \array_map('preg_quote', \is_array($files) ? $files : [$files])) . ')/u';
32+
$files = '/^(' . \implode('|', \array_map(fn($x): string => preg_quote($x, '/'), \is_array($files) ? $files : [$files])) . ')/u';
3333
}
3434

3535
\clearstatcache(true);

0 commit comments

Comments
 (0)