Added compatibility with other extensions modifying zend_error_cb

Since Xdebug doesn't call the previously defined error callback but replaces it, find a way to make it coexist with other extensions that replaces the error callback at RINIT, like APM.