MCPcopy Create free account
hub / github.com/IIIImmmyyy/frida-il2cppDumper / drainQueue

Function drainQueue

_agent.js:3337–3359  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3335}
3336
3337function drainQueue() {
3338 if (draining) {
3339 return;
3340 }
3341 var timeout = runTimeout(cleanUpNextTick);
3342 draining = true;
3343
3344 var len = queue.length;
3345 while(len) {
3346 currentQueue = queue;
3347 queue = [];
3348 while (++queueIndex < len) {
3349 if (currentQueue) {
3350 currentQueue[queueIndex].run();
3351 }
3352 }
3353 queueIndex = -1;
3354 len = queue.length;
3355 }
3356 currentQueue = null;
3357 draining = false;
3358 runClearTimeout(timeout);
3359}
3360
3361process.nextTick = function (fun) {
3362 var args = new Array(arguments.length - 1);

Callers 1

cleanUpNextTickFunction · 0.85

Calls 2

runTimeoutFunction · 0.85
runClearTimeoutFunction · 0.85

Tested by

no test coverage detected