diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2016-04-01 21:37:24 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2016-04-01 21:39:07 +0300 |
commit | e02d0de36e89cf2419dbbf36afd36d8d25b94c55 (patch) | |
tree | 9c50cf74f01d521eb637c5b18cbba8b324d6031c /intern/cycles/util | |
parent | ce44ffd74f749cebdaf2141486b4773bd98b0a41 (diff) |
Fix T47505: Cycles OpenCL rendering crash on Windows.
Restore the boost bug workaround, but without changing the locale.
Diffstat (limited to 'intern/cycles/util')
-rw-r--r-- | intern/cycles/util/util_path.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/intern/cycles/util/util_path.cpp b/intern/cycles/util/util_path.cpp index 196e2c49dcb..7b936d341d1 100644 --- a/intern/cycles/util/util_path.cpp +++ b/intern/cycles/util/util_path.cpp @@ -19,6 +19,7 @@ #include "util_path.h" #include "util_string.h" +#include <OpenImageIO/filesystem.h> #include <OpenImageIO/strutil.h> #include <OpenImageIO/sysutil.h> @@ -334,6 +335,13 @@ void path_init(const string& path, const string& user_path) { cached_path = path; cached_user_path = user_path; + +#ifdef _MSC_VER + // workaround for https://svn.boost.org/trac/boost/ticket/6320 + // indirectly init boost codec here since it's not thread safe, and can + // cause crashes when it happens in multithreaded image load + OIIO::Filesystem::exists(path); +#endif } string path_get(const string& sub) |