diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-07-23 16:49:30 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-07-23 16:49:30 +0400 |
commit | 3ff3d1bc0fa6979d0745dbd7526cbb5c35c1fcbf (patch) | |
tree | 99df5ec67111abede3cb2e29b469bb7a1ff2b3ae /source/gameengine/GamePlayer/ghost/GPG_ghost.cpp | |
parent | a5bc02194345de1eb21f843b73ce24799677aea1 (diff) |
replace use of strcat() where the string offset is known.
also correct bad logic with converting a textblock to 3d-text, bytes-vs-number of chars wasn't handled right.
Diffstat (limited to 'source/gameengine/GamePlayer/ghost/GPG_ghost.cpp')
-rw-r--r-- | source/gameengine/GamePlayer/ghost/GPG_ghost.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp b/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp index f1edb71f4fe..817a4d8efac 100644 --- a/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp +++ b/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp @@ -813,9 +813,8 @@ int main(int argc, char** argv) if (!bfd) { // just add "//" in front of it - char temppath[242]; - strcpy(temppath, "//"); - strcat(temppath, basedpath); + char temppath[FILE_MAX] = "//"; + BLI_strncpy(temppath + 2, basedpath, FILE_MAX - 2); BLI_path_abs(temppath, pathname); bfd = load_game_data(temppath); |