We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent aafdd67 commit d49cffeCopy full SHA for d49cffe
Common/FileUtil.cpp
@@ -135,7 +135,9 @@ bool Exists(const std::string &filename)
135
{
136
// Make sure Windows will no longer handle critical errors, which means no annoying "No disk" dialog
137
// Save the old error mode
138
+#ifdef _WIN32
139
int OldMode = SetErrorMode(SEM_FAILCRITICALERRORS);
140
+#endif
141
142
struct stat64 file_info;
143
#if defined(_WIN32) && defined(UNICODE)
@@ -151,7 +153,9 @@ bool Exists(const std::string &filename)
151
153
#endif
152
154
155
// Set the old error mode
156
157
SetErrorMode(OldMode);
158
159
160
return (result == 0);
161
}
0 commit comments