fix for potential crasher. we were returning pointer to a local var
authorJean-Luc Peurière <jlp@nerim.net>
Sun, 12 Dec 2004 13:29:54 +0000 (13:29 +0000)
committerJean-Luc Peurière <jlp@nerim.net>
Sun, 12 Dec 2004 13:29:54 +0000 (13:29 +0000)
source/blender/blenlib/intern/util.c

index 2bd36658abc216f8def4c1fc5d91d4a0a62b3a0d..ea666be3e45aafad40573501f48ee124f2eb8456 100644 (file)
@@ -871,7 +871,7 @@ void BLI_where_am_i(char *fullname, char *name)
 char* BLI_getbundle(void) {
        CFURLRef bundleURL;
        CFStringRef pathStr;
-       char path[MAXPATHLEN];
+       static char path[MAXPATHLEN];
        CFBundleRef mainBundle = CFBundleGetMainBundle();
 
        bundleURL = CFBundleCopyBundleURL(mainBundle);