27 May
2013
27 May
'13
3:11 a.m.
On Sunday 26 May 2013 23:45:48 Vicente J. Botet Escriba wrote:
Le 26/05/13 22:28, Gaetano Mendola a écrit :
Hi, I saw that the destructor of ~mutex doesn't have a BOOST_VERIFY anymore on the return value of pthread_mutex_destroy. From SVN logs I can see it was removed in the commit 75882 to manage the EINTR due to some bugged POSIX implementation.
I will reintroduce the BOOST_VERIFY like this: ~mutex() {
int ret; do {
ret = pthread_mutex_destroy(&m);
} while (ret == EINTR); BOOST_VERIFY(!ret);
}
What do you want to verify?
Checking the result may be useful for detecting incorrect operation sequence (e.g. when the mutex is destroyed with a blocked thread on it).