Yasuo Ohgaki wrote:
> I will change code so that ob_end_clean() (and other similar
> functions) may not be called from inside ob_start() call back
> function. It's easy one to fix :)
>
> This code does not make sense to me, but I may miss
> something. Do you want any usefulness in this code?

  Yasuo,

  of course the code snippet I posted makes no obvious sense, it is after
  all only the shortest snippet of code that reproduces the segfault I
  encountered.

  I am currently working on an application that registers a callback via
  ob_start() and gets called this way with the whole output, which
  happens to be XML, of the rest of the script as its input data.

  In this callback, I use the ext/xml functions to parse this XML data.
  Now when, for instance, a parse error occurs, I need to emit an
  appropriate error messsage, hence I need to stop the output buffering
  and output something. And, at this point, it segfaults.

  I would rather see the possibility of calling ob_end_clean() in a
  ob_start() callback function than removing this feature.

-- 
  Sebastian Bergmann
  http://sebastian-bergmann.de/                 http://phpOpenTracker.de/

  Did I help you? Consider a gift: http://wishlist.sebastian-bergmann.de/

-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to