Beispiel #1
0
semaphore::semaphore(const semaphore& other)
{
	i32 value = other.value();
#if defined(CRAP_PLATFORM_WIN)
	_semaphore = CreateSemaphore( 0, value, LMAXIMUMCOUNT, 0 );
#else
	sem_init( &_semaphore, 0, value );
#endif
}
Beispiel #2
0
void semaphore::operator=( const semaphore& other )
{
	reset( other.value() );
}