MCPcopy Create free account
hub / github.com/cppla/ServerStatus / lock_create

Function lock_create

server/src/system.c:451–463  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

449#endif
450
451LOCK lock_create()
452{
453 LOCKINTERNAL *lock = (LOCKINTERNAL*)mem_alloc(sizeof(LOCKINTERNAL), 4);
454
455#if defined(CONF_FAMILY_UNIX)
456 pthread_mutex_init(lock, 0x0);
457#elif defined(CONF_FAMILY_WINDOWS)
458 InitializeCriticalSection((LPCRITICAL_SECTION)lock);
459#else
460 #error not implemented on this platform
461#endif
462 return (LOCK)lock;
463}
464
465void lock_destroy(LOCK lock)
466{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected