1
0
Fork 0

Add support for PREG_JIT_STACKLIMIT_ERROR, refs #5104

pull/5106/head
Jordi Boggiano 2016-03-24 16:00:44 +00:00
parent a8e9df55dc
commit 2217f4e09e
1 changed files with 6 additions and 0 deletions

View File

@ -422,6 +422,12 @@ class JsonManipulator
throw new \RuntimeException('Failed to execute regex: PREG_BAD_UTF8_ERROR', PREG_BAD_UTF8_ERROR);
case PREG_BAD_UTF8_OFFSET_ERROR:
throw new \RuntimeException('Failed to execute regex: PREG_BAD_UTF8_OFFSET_ERROR', PREG_BAD_UTF8_OFFSET_ERROR);
case 6: // PREG_JIT_STACKLIMIT_ERROR
if (PHP_VERSION_ID > 70000) {
throw new \RuntimeException('Failed to execute regex: PREG_JIT_STACKLIMIT_ERROR', 6);
}
// fallthrough
default:
throw new \RuntimeException('Failed to execute regex: Unknown error');
}