diff options
author | Andrea Weikert <elubie@gmx.net> | 2008-09-14 20:22:03 +0400 |
---|---|---|
committer | Andrea Weikert <elubie@gmx.net> | 2008-09-14 20:22:03 +0400 |
commit | 2eb8eb4e7eedece1f3233aa0d9889993c8575d3e (patch) | |
tree | ba95279ceb56d4e76c6e3560c42484d7d6e45b0e /source/gameengine/Converter/KX_ConvertActuators.cpp | |
parent | 6977816ff3a1777906bb5f8f16d2bad3f983dc2c (diff) |
Bugfix: avoid crash with too long pathname.
Diffstat (limited to 'source/gameengine/Converter/KX_ConvertActuators.cpp')
-rw-r--r-- | source/gameengine/Converter/KX_ConvertActuators.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/source/gameengine/Converter/KX_ConvertActuators.cpp b/source/gameengine/Converter/KX_ConvertActuators.cpp index 799506aecaa..e8be8de95ed 100644 --- a/source/gameengine/Converter/KX_ConvertActuators.cpp +++ b/source/gameengine/Converter/KX_ConvertActuators.cpp @@ -74,6 +74,8 @@ #include "BKE_text.h" #include "BLI_blenlib.h" +#define FILE_MAX 240 // repeated here to avoid dependency from BKE_utildefines.h + #include "KX_NetworkMessageActuator.h" #ifdef WIN32 @@ -362,7 +364,7 @@ void BL_ConvertActuators(char* maggiename, if (soundact->sound) { /* Need to convert the samplename into absolute path * before checking if its loaded */ - char fullpath[sizeof(soundact->sound->name)]; + char fullpath[FILE_MAX]; /* dont modify soundact->sound->name, only change a copy */ BLI_strncpy(fullpath, soundact->sound->name, sizeof(fullpath)); |