CoreCommunity ExtensionsIncubatorDistributionsTYPO3 4.5 ProjectsTYPO3 4.7 ProjectsTYPO3 6.0 ProjectsTYPO3 6.1 ProjectsTYPO3 6.2 Projects (+)

Bug #33618

PHP Warning: Invalid argument supplied for foreach() in class.tx_webkitpdf_pi1.php

Added by Tobias Schaefer over 1 year ago. Updated over 1 year ago.

Status:Resolved Start date:2012-02-02
Priority:Should have Due date:
Assignee:Reinhard Führicht % Done:

100%

Category:-
Target version:-
Votes: 0

Description

Hi,

I'm getting an PHP warning in apache-error_log each time I convert a pdf:
PHP Warning: Invalid argument supplied for foreach() in pi1/class.tx_webkitpdf_pi1.php
The error is caused in function processStdWraps by a missing typecast:
foreach ($tsSettings as $key => $value) {
If I change it to:
foreach ((array)$tsSettings as $key => $value) {
the error doesn't occur anymore.

Cheers, Tobias

Patch__33618.patch (453 Bytes) Julian Hofmann, 2012-02-17 12:49

Associated revisions

Revision 58519
Added by Reinhard Führicht over 1 year ago

Fixed PHP warning (fixes #33618)

Revision 58519
Added by Reinhard Führicht over 1 year ago

Fixed PHP warning (fixes #33618)

History

Updated by Julian Hofmann over 1 year ago

It is not cased be a missing typecast, but by an unnecessary call of processStdWraps in case of missing/empty scriptparams.

Should be fixed by checking the parameter before calling the method.

Updated by Reinhard Führicht over 1 year ago

  • Status changed from New to Resolved
  • Assignee set to Reinhard Führicht
  • % Done changed from 0 to 100

Fixed in trunk.

Also available in: Atom PDF