Changeset View
Changeset View
Standalone View
Standalone View
source/blender/blenlib/intern/storage.c
| Show First 20 Lines • Show All 224 Lines • ▼ Show 20 Lines | if ((len >= 3) && (tmp_16[0] == L'\\') && (tmp_16[1] == L'\\')) { | ||||
| BLI_cleanup_unc_16(tmp_16); | BLI_cleanup_unc_16(tmp_16); | ||||
| } | } | ||||
| if ((tmp_16[1] == L':') && (tmp_16[2] == L'\0')) { | if ((tmp_16[1] == L':') && (tmp_16[2] == L'\0')) { | ||||
| tmp_16[2] = L'\\'; | tmp_16[2] = L'\\'; | ||||
| tmp_16[3] = L'\0'; | tmp_16[3] = L'\0'; | ||||
| } | } | ||||
| /* change error mode so user does not get a "no disk in drive" popup | |||||
| * when looking for a file on an empty CD/DVD drive */ | |||||
| old_error_mode = SetErrorMode(SEM_FAILCRITICALERRORS | SEM_NOOPENFILEERRORBOX); | |||||
| res = BLI_wstat(tmp_16, &st); | res = BLI_wstat(tmp_16, &st); | ||||
| SetErrorMode(old_error_mode); | |||||
| free(tmp_16); | free(tmp_16); | ||||
| if (res == -1) { | if (res == -1) { | ||||
| return (0); | return (0); | ||||
| } | } | ||||
| #else | #else | ||||
| struct stat st; | struct stat st; | ||||
| BLI_assert(!BLI_path_is_rel(name)); | BLI_assert(!BLI_path_is_rel(name)); | ||||
| if (stat(name, &st)) { | if (stat(name, &st)) { | ||||
| ▲ Show 20 Lines • Show All 218 Lines • Show Last 20 Lines | |||||