diff options
author | Andrea Weikert <elubie@gmx.net> | 2008-03-30 20:18:01 +0400 |
---|---|---|
committer | Andrea Weikert <elubie@gmx.net> | 2008-03-30 20:18:01 +0400 |
commit | d9de141077873c9379d0bd6ea745b60f5180c4d2 (patch) | |
tree | 36c40794cad938487904814b022f886b9eef9cc9 /source/gameengine | |
parent | cc4858cde045d17cef5ea9c847484e3168364bd4 (diff) |
== bugfix ==
fix for [#6950] Blender crashes when .blog file top line is 160 characters or more
- made sure BLI_convertstringcode doesn't return more than 240 chars
- went through all callers and fixed places where string passed to BLI_convertstringcode was too short
- TODO: look into increasing sample->name and sound->name too, I prevented crashes, but filename might get shortened.
Diffstat (limited to 'source/gameengine')
-rw-r--r-- | source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp | 4 | ||||
-rw-r--r-- | source/gameengine/GamePlayer/ghost/GPG_ghost.cpp | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp b/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp index 0e0d8982527..3b7f610b783 100644 --- a/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp +++ b/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp @@ -258,7 +258,7 @@ extern "C" void StartKetsjiShell(struct ScrArea *area, exitrequested = KX_EXIT_REQUEST_NO_REQUEST; if (bfd) BLO_blendfiledata_free(bfd); - char basedpath[160]; + char basedpath[240]; // base the actuator filename with respect // to the original file working directory if (exitstring != "") @@ -271,7 +271,7 @@ extern "C" void StartKetsjiShell(struct ScrArea *area, if (!bfd) { // just add "//" in front of it - char temppath[162]; + char temppath[242]; strcpy(temppath, "//"); strcat(temppath, basedpath); diff --git a/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp b/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp index 0993446c77b..cf45c513098 100644 --- a/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp +++ b/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp @@ -577,7 +577,7 @@ int main(int argc, char** argv) // if we got an exitcode 3 (KX_EXIT_REQUEST_START_OTHER_GAME) load a different file if (exitcode == KX_EXIT_REQUEST_START_OTHER_GAME) { - char basedpath[160]; + char basedpath[240]; // base the actuator filename with respect // to the original file working directory |