[TYPO3-dev] RFC: adding debug info to stdGraphic IM_command array
Wolfgang Klinger
wolfgang at stufenlos.net
Mon Jul 9 18:21:14 CEST 2007
*hiya!*
On Jul 9, 2007, at 2:36 PM, Martin Kutschker wrote:
> Any problems adding the following function like that?
>
> function imageMagickExec($input,$output,$params) {
> if (!$this->NO_IMAGE_MAGICK) {
> $cmd = t3lib_div::imageMagickCommand('convert', $params.
> ' '.$this->wrapFileName($input).' '.$this->wrapFileName($output));
>
> // CHANGE IS HERE: added processeing of status and full program
> output
> $ret = exec($cmd.' 2>&1',$message,$status);
> $this->IM_commands[] = array($output,$cmd,$status,$message);
>
> t3lib_div::fixPermissions($this->wrapFileName($output));
>
> return $ret;
> }
> }
Should work and make no problems... at least on Unix,
I don't know what happens on Windows when executing the command
with the output channel redirects (2>&1)?
btw $ret is never used by any calling method,
maybe we can remove that here?
bye
Wolfgang
More information about the TYPO3-dev
mailing list