X-Git-Url: https://git.cweiske.de/phancap.git/blobdiff_plain/32e0675a8175758595310e87e0a784063906aed5..c2039a447e4bd044eedf31258bace2cc3f03fc29:/src/phancap/Adapter/Cutycapt.php diff --git a/src/phancap/Adapter/Cutycapt.php b/src/phancap/Adapter/Cutycapt.php index 13f972e..a757b07 100644 --- a/src/phancap/Adapter/Cutycapt.php +++ b/src/phancap/Adapter/Cutycapt.php @@ -117,6 +117,11 @@ class Adapter_Cutycapt // we kill it if it does not exit itself Executor::runForSomeTime($xvfbcmd . ' ' . $cmd, $maxWaitTime); + //cutycapt does not report timeouts via exit status + if (!file_exists($tmpPath)) { + throw new \Exception('Error running cutycapt (wait timeout)', 1); + } + $this->resize($tmpPath, $img, $options); }