2
0
mirror of https://github.com/boostorg/thread.git synced 2026-01-19 04:42:13 +00:00

Fix for ticket #1547 --- Change use of NULL to 0

[SVN r43268]
This commit is contained in:
Anthony Williams
2008-02-15 17:56:13 +00:00
parent 7fd3fb48b1
commit 7caec1ec33
3 changed files with 7 additions and 7 deletions

View File

@@ -94,9 +94,9 @@ namespace boost
detail::int_to_string(win32::GetCurrentProcessId(), mutex_name + once_mutex_name_fixed_length + sizeof(void*)*2);
#ifdef BOOST_NO_ANSI_APIS
return win32::CreateMutexW(NULL, 0, mutex_name);
return win32::CreateMutexW(0, 0, mutex_name);
#else
return win32::CreateMutexA(NULL, 0, mutex_name);
return win32::CreateMutexA(0, 0, mutex_name);
#endif
}

View File

@@ -57,12 +57,12 @@ namespace boost
{
if(old_state.exclusive_waiting)
{
BOOST_VERIFY(detail::win32::ReleaseSemaphore(exclusive_sem,1,NULL)!=0);
BOOST_VERIFY(detail::win32::ReleaseSemaphore(exclusive_sem,1,0)!=0);
}
if(old_state.shared_waiting || old_state.exclusive_waiting)
{
BOOST_VERIFY(detail::win32::ReleaseSemaphore(unlock_sem,old_state.shared_waiting + (old_state.exclusive_waiting?1:0),NULL)!=0);
BOOST_VERIFY(detail::win32::ReleaseSemaphore(unlock_sem,old_state.shared_waiting + (old_state.exclusive_waiting?1:0),0)!=0);
}
}
@@ -215,7 +215,7 @@ namespace boost
{
if(old_state.upgrade)
{
BOOST_VERIFY(detail::win32::ReleaseSemaphore(upgrade_sem,1,NULL)!=0);
BOOST_VERIFY(detail::win32::ReleaseSemaphore(upgrade_sem,1,0)!=0);
}
else
{

View File

@@ -181,9 +181,9 @@ namespace boost
inline handle create_anonymous_semaphore(long initial_count,long max_count)
{
#if !defined(BOOST_NO_ANSI_APIS)
handle const res=CreateSemaphoreA(NULL,initial_count,max_count,NULL);
handle const res=CreateSemaphoreA(0,initial_count,max_count,0);
#else
handle const res=CreateSemaphoreW(NULL,initial_count,max_count,NULL);
handle const res=CreateSemaphoreW(0,initial_count,max_count,0);
#endif
if(!res)
{