-
-
Save GuillaumeLeclerc/b41349096e9ac7a9c3fb to your computer and use it in GitHub Desktop.
Workarround for https://github.com/kripken/emscripten/issues/3675
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
bool fixed_is_directory(std::string path) { | |
boost::system::error_code errorCode; | |
bool result = boost::filesystem::is_directory(path, errorCode); | |
if (errorCode.value() != 0) { | |
//this second call will fire the correct exception | |
boost::filesystem::is_directory(path); | |
} else { | |
return result; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment