Closed vinaygund closed 10 months ago
This is a false positive. I'm guessing that Coverity doesn't recognise NO_THREAD_SAFETY_ANALYSIS
.
Oh, hang on. You are using an older version of RE2 that predates the Abseil dependency. NO_THREAD_SAFETY_ANALYSIS
was a no-op, which is presumably why the false positive arose. Nowadays, ABSL_NO_THREAD_SAFETY_ANALYSIS
is used and Coverity should hopefully recognise that.
Hi , in my project I use Coverity tool {Coverity is a static analysis tool used for identifying software security vulnerabilities, quality defects, and code maintenance issues in source code.}
in dfa.cc file line 1132.
this is the code and warning reported by coverity in above snapshot ,
1130// This function is marked as NO_THREAD_SAFETY_ANALYSIS because 1131// the annotations don't support lock upgrade. 1132void DFA::RWLocker::LockForWriting() NO_THREAD_SAFETY_ANALYSIS {
CID 155380 (#1 of 1): Data race condition (MISSING_LOCK)
please provide your feedback.
Regards vinay