Skip to content

Commit 50b30ca

Browse files
jpsn123artonge
authored andcommitted
Fix(previews): movie preview bug fix, in some case stream reading functions may block indefinitel
1 parent 77194d5 commit 50b30ca

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

lib/private/Preview/Movie.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -307,6 +307,8 @@ private function generateThumbNail(int $maxX, int $maxY, string $absPath, int $s
307307
$returnCode = -1;
308308
$output = '';
309309
if (is_resource($proc)) {
310+
stream_set_blocking($pipes[1], false);
311+
stream_set_blocking($pipes[2], false);
310312
$stderr = trim(stream_get_contents($pipes[2]));
311313
$stdout = trim(stream_get_contents($pipes[1]));
312314
$returnCode = proc_close($proc);

0 commit comments

Comments
 (0)