xref: /PHP-7.3/ext/opcache/tests/bug76275.phpt (revision d5e20662)
1--TEST--
2Bug #76275: Assertion failure in file cache when unserializing empty try_catch_array
3--INI--
4opcache.enabled=1
5opcache.enable_cli=1
6opcache.file_cache="{TMP}"
7--SKIPIF--
8<?php require_once('skipif.inc'); ?>
9--FILE--
10<?php
11if (PHP_VERSION_ID >= 70000) {
12    echo "Done";
13    return;
14}
15if (!is_callable('random_bytes')) {
16    try {
17    } catch (com_exception $e) {
18    }
19    function random_bytes($length)
20    {
21        throw new Exception(
22            'There is no suitable CSPRNG installed on your system'
23        );
24        return '';
25    }
26}
27--EXPECT--
28Done
29