Fix Issue 275#276
Merged
viboes merged 1 commit intoboostorg:developfrom Apr 2, 2019
Merged
Conversation
* Re-fixed the EINTR bug that exists in some pthreads implementations. It was originally fixed in https://svn.boost.org/trac10/ticket/6200 and was accidentally disabled in 5b209c2. * Made sure that the fix for the EINTR bug was consistently applied to all code in the library. * Made sure that all pthread_mutex_*() and pthread_cond_*() function calls in the library were consistently decorated with BOOST_THREAD_DISABLE_THREAD_SAFETY_ANALYSIS.
Kojoley
reviewed
Apr 2, 2019
| ret = pthread_cond_destroy(&cond); | ||
| } while (ret == EINTR); | ||
| ret = posix::pthread_cond_destroy(&cond); | ||
| BOOST_ASSERT(!ret); |
Contributor
There was a problem hiding this comment.
Please change both BOOST_ASSERT into BOOST_VERIFY if everything is ok with the logic itself.
gcc.compile.c++ ../../../../bin.v2/libs/spirit/classic/test/grammar_mt_tests.test/gcc-8/release/cxxstd-03-iso/threadapi-pthread/threading-multi/visibility-hidden/grammar_mt_tests.o
In file included from ../../../../boost/thread/pthread/thread_data.hpp:14,
from ../../../../boost/thread/thread_only.hpp:17,
from ../../../../boost/thread/thread.hpp:12,
from grammar_mt_tests.cpp:33:
../../../../boost/thread/pthread/condition_variable_fwd.hpp: In destructor ‘boost::condition_variable::~condition_variable()’:
../../../../boost/thread/pthread/condition_variable_fwd.hpp:79:17: error: variable ‘ret’ set but not used [-Werror=unused-but-set-variable]
int ret;
^~~
cc1plus: all warnings being treated as errors
"ccache" "g++-8" -std=c++03 -fvisibility-inlines-hidden -fPIC -m64 -pthread -O3 -finline-functions -Wno-inline -Wall -Wextra -Werror -fvisibility=hidden -Wno-maybe-uninitialized -Wno-sign-compare -Wno-implicit-fallthrough -DBOOST_ALL_NO_LIB -DBOOST_ALL_NO_LIB=1 -DBOOST_CHRONO_DYN_LINK=1 -DBOOST_THREAD_BUILD_DLL=1 -DBOOST_THREAD_POSIX -DBOOST_THREAD_USE_DLL=1 -DNDEBUG -I"." -I"../../../.." -c -o "../../../../bin.v2/libs/spirit/classic/test/grammar_mt_tests.test/gcc-8/release/cxxstd-03-iso/threadapi-pthread/threading-multi/visibility-hidden/grammar_mt_tests.o" "grammar_mt_tests.cpp"
Contributor
Author
There was a problem hiding this comment.
Ok, I'll submit another PR for this.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
It was originally fixed in https://svn.boost.org/trac10/ticket/6200 and
was accidentally disabled in 5b209c2.
all code in the library.
calls in the library were consistently decorated with
BOOST_THREAD_DISABLE_THREAD_SAFETY_ANALYSIS.