summaryrefslogtreecommitdiff
path: root/ext/dom/document.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/dom/document.c')
-rw-r--r--ext/dom/document.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/ext/dom/document.c b/ext/dom/document.c
index 89f6358775..aa1d99ebd2 100644
--- a/ext/dom/document.c
+++ b/ext/dom/document.c
@@ -1681,7 +1681,9 @@ static void _dom_document_schema_validate(INTERNAL_FUNCTION_PARAMETERS, int type
sptr = xmlSchemaParse(parser);
xmlSchemaFreeParserCtxt(parser);
if (!sptr) {
- php_error_docref(NULL, E_WARNING, "Invalid Schema");
+ if (!EG(exception)) {
+ php_error_docref(NULL, E_WARNING, "Invalid Schema");
+ }
RETURN_FALSE;
}