/** * Implementation of the exception that was originally thrown by PHP * code or the zend engine, and that could or could not be picked * up by C++ code * * @author Emiel Bruijntjes * @copyright 2013 Copernica BV */ #include "includes.h" /** * Set up namespace */ namespace Php { /** * Destructor */ OrigException::~OrigException() noexcept { // skip if the exception was restored if (_restored) return; // we need the tsrm_ls var TSRMLS_FETCH(); // clean up the exception, because it was handled in C++ code zend_clear_exception(TSRMLS_C); } /** * End of namespace */ }