1
mirror of https://github.com/jedisct1/libsodium.git synced 2024-12-19 10:05:05 -07:00

Add no-ops for very old browsers without the performance API

This commit is contained in:
Frank Denis 2017-10-05 01:46:02 +02:00
parent 37d9f09f5b
commit e784a3fb40

View File

@ -28,6 +28,15 @@ body {
<h1></h1>
<section class="test" id="test-res"></section>
<script>
var performance;
if (typeof performance !== 'object') {
performance = {
mark: function() { },
measure: function() { },
getEntriesByName: function() { return [ -1 ] }
};
}
var Module = { preRun: function() { performance.mark('bench_start') } };
function runTest(tname) {