opencv/modules/imgproc
Vincent Rabaud 06f62a3dd1
Merge pull request #24581 from vrabaud:tsan
Fix race condition in color_lab.cpp initLabTabs(). #24581

There is a race condition between when the static bool is initialized (which is thread safe) and its value check. This PR changes the static bool to a static lambda call to make it thread safe. The static_cast<void> in the end is to prevent unused variables warnings.

### Pull Request Readiness Checklist

See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request

- [x] I agree to contribute to the project under Apache 2 License.
- [x] To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV
- [x] The PR is proposed to the proper branch
- [x] There is a reference to the original bug report and related work
2023-11-28 15:01:41 +03:00
..
doc Backport C-API cleanup (imgproc) from 5.x 2023-01-16 23:29:50 +03:00
include/opencv2 Merge pull request #24333 from definitelyuncertain:CvtRGB2YUV422 2023-10-12 10:18:24 +03:00
misc Merge pull request #24234 from dkurt:distanceTransform_max_dist 2023-10-03 17:23:32 +03:00
perf Ensure interarea algorithm usage in resize perfomance test. 2023-10-17 09:43:15 +03:00
src Merge pull request #24581 from vrabaud:tsan 2023-11-28 15:01:41 +03:00
test Merge pull request #24527 from MaximSmolskiy:fix-out-of-image-corners-in-cv-cornersubpix 2023-11-21 15:36:43 +03:00
CMakeLists.txt Merge pull request #24179 from Kumataro:fix24145 2023-08-23 22:53:11 +03:00