MCPcopy Create free account
hub / github.com/NetHack/NetHack / reentryMutexLock

Function reentryMutexLock

win/shim/winshim.c:310–316  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

308 }
309
310 function reentryMutexLock(name) {
311 globalThis.nethackGlobal = globalThis.nethackGlobal || {};
312 if(globalThis.nethackGlobal.shimFunctionRunning) {
313 console.error(`'${name}' attempting second call to 'local_callback' before '${globalThis.nethackGlobal.shimFunctionRunning}' has finished, will crash emscripten Asyncify. For details see: emscripten.org/docs/porting/asyncify.html#reentrancy`);
314 }
315 globalThis.nethackGlobal.shimFunctionRunning = name;
316 }
317
318 function reentryMutexUnlock() {
319 globalThis.nethackGlobal.shimFunctionRunning = null;

Callers 1

winshim.cFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected