From: spam at burgestrand dot se Operating system: Mac OS 10.5.7 PHP version: 5.3.0 PHP Bug Type: SPL related Bug description: IteratorIterator seek() causes bus error
Description: ------------ After using seek() on an IteratorIterator containing an ArrayIterator the next() call results in a bus error. Also, the seek() method doesnt seem to advance the key to the specified position on the inner iterator (unless issuing getInnerIterator()->seek(x) directly and calling getInnerIterator()->current()). Reproduce code: --------------- <?php $iiter = new IteratorIterator(new ArrayIterator(range(0, 5))); $iiter->rewind(); $iiter->seek(2); var_dump($iiter->current()); $iiter->next(); // bus error var_dump($iiter->current()); /* End of file */ Expected result: ---------------- int(2) int(3) Actual result: -------------- int(0) -- Edit bug report at http://bugs.php.net/?id=48816&edit=1 -- Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=48816&r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=48816&r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=48816&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=48816&r=fixedcvs Fixed in CVS and need be documented: http://bugs.php.net/fix.php?id=48816&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=48816&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=48816&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=48816&r=needscript Try newer version: http://bugs.php.net/fix.php?id=48816&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=48816&r=support Expected behavior: http://bugs.php.net/fix.php?id=48816&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=48816&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=48816&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=48816&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=48816&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=48816&r=dst IIS Stability: http://bugs.php.net/fix.php?id=48816&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=48816&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=48816&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=48816&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=48816&r=mysqlcfg