Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2011-05-06 05:03:36 +0400
committerCampbell Barton <ideasman42@gmail.com>2011-05-06 05:03:36 +0400
commit8751d1d92749a6ddf8a15031212ad26a50b41328 (patch)
treebfc886a7bf99292c79055a5f3379a7039ebc076b
parent53096ebad5502afc667af61866157272087952ad (diff)
[#26715] Blender2.57 crash when opening in Windows, non-latin char in path
this isn't a fix but GetModuleFileName is returning a name that doesn't exist, so finding python after this isn't working. Show a popup that the path has an invalid name so at least the user can move it.
-rw-r--r--source/blender/blenlib/intern/path_util.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/blenlib/intern/path_util.c b/source/blender/blenlib/intern/path_util.c
index e8e8127be0c..1f4b0ffdd5c 100644
--- a/source/blender/blenlib/intern/path_util.c
+++ b/source/blender/blenlib/intern/path_util.c
@@ -1692,6 +1692,10 @@ void BLI_where_am_i(char *fullname, const size_t maxlen, const char *name)
#ifdef _WIN32
if(GetModuleFileName(0, fullname, maxlen)) {
GetShortPathName(fullname, fullname, maxlen);
+ if(!BLI_exists(fullname)) {
+ printf("path can't be found: \"%.*s\"\n", maxlen, fullname);
+ MessageBox(NULL, "path constains invalid characters or is too long (see console)", "Error", MB_OK);
+ }
return;
}
#endif