mirror of
https://github.com/opencv/opencv.git
synced 2026-07-21 19:33:03 +04:00
f831c94309b6ab6db79bdaeefd483dec4e5183f0
MlasThreadedBufAlloc() and its ThreadedBufHolder guarded the _aligned_malloc / _aligned_free path on _MSC_VER. Non-MSVC Windows toolchains (MinGW, clang) therefore fell through to posix_memalign(), which the Windows CRT does not provide, so the build failed with "'posix_memalign' was not declared in this scope". Guard the aligned-allocation path on _WIN32 instead, in both the holder declaration (mlasi.h) and definition (platform.cpp) so the unique_ptr deleter type stays consistent across translation units, and include <malloc.h> on Windows since MinGW only declares the _aligned_* functions there. The non-Windows posix_memalign / aligned_alloc fallback is unchanged. Fixes #29350
OpenCV: Open Source Computer Vision Library
Resources
- Homepage: https://opencv.org
- Courses: https://opencv.org/courses
- Docs: https://docs.opencv.org/5.x/
- Q&A forum: https://forum.opencv.org
- previous forum (read only): http://answers.opencv.org
- Issue tracking: https://github.com/opencv/opencv/issues
- Additional OpenCV functionality: https://github.com/opencv/opencv_contrib
- Donate to OpenCV: https://opencv.org/support/
Contributing
Please read the contribution guidelines before starting work on a pull request.
Summary of the guidelines:
- One pull request per issue;
- Choose the right base branch;
- Include tests and documentation;
- Clean up "oops" commits before submitting;
- Follow the coding style guide.
Additional Resources
- Submit your OpenCV-based project for inclusion in Community Friday on opencv.org
- Subscribe to the OpenCV YouTube Channel featuring OpenCV Live, an hour-long streaming show
- Follow OpenCV on LinkedIn for daily posts showing the state-of-the-art in computer vision & AI
- Apply to be an OpenCV Volunteer to help organize events and online campaigns as well as amplify them
- Follow OpenCV on Mastodon in the Fediverse
- Follow OpenCV on Twitter
- OpenCV.ai: Computer Vision and AI development services from the OpenCV team.
Description
Languages
C++
87.6%
C
3.2%
Python
2.9%
CMake
2%
Java
1.5%
Other
2.6%