[Bf-blender-cvs] [535a6cde64b] master: Cleanup: redundant 'static' variable

Campbell Barton noreply at git.blender.org
Fri Aug 11 00:48:04 CEST 2017


Commit: 535a6cde64bc4f2d3c52d55ae7aa6c5b3078c281
Author: Campbell Barton
Date:   Fri Aug 11 08:48:15 2017 +1000
Branches: master
https://developer.blender.org/rB535a6cde64bc4f2d3c52d55ae7aa6c5b3078c281

Cleanup: redundant 'static' variable

Also use BLI_snprintf.

===================================================================

M	source/blender/blenkernel/intern/appdir.c

===================================================================

diff --git a/source/blender/blenkernel/intern/appdir.c b/source/blender/blenkernel/intern/appdir.c
index 48012bd9e90..9afabdc0b4f 100644
--- a/source/blender/blenkernel/intern/appdir.c
+++ b/source/blender/blenkernel/intern/appdir.c
@@ -212,8 +212,8 @@ static bool get_path_local(
 	/* try EXECUTABLE_DIR/2.5x/folder_name - new default directory for local blender installed files */
 #ifdef __APPLE__
 	/* due new codesign situation in OSX > 10.9.5 we must move the blender_version dir with contents to Resources */
-	static char osx_resourses[FILE_MAX];
-	sprintf(osx_resourses, "%s../Resources", bprogdir);
+	char osx_resourses[FILE_MAX];
+	BLI_snprintf(osx_resourses, sizeof(osx_resourses), "%s../Resources", bprogdir);
 	/* Remove the '/../' added above. */
 	BLI_cleanup_path(NULL, osx_resourses);
 	return test_path(targetpath, targetpath_len, osx_resourses, blender_version_decimal(ver), relfolder);




More information about the Bf-blender-cvs mailing list