diff options
author | Campbell Barton <ideasman42@gmail.com> | 2008-10-19 08:02:37 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2008-10-19 08:02:37 +0400 |
commit | 42e287af1cc3ed2f37630f6f62c82c2d8ccc66b3 (patch) | |
tree | 6e05ba42d1aa9cd9d028a8a169675a4dcfb1aa08 /source/blender/blenlib | |
parent | 72e5ede546cd5b17e4dec2f5b9949a9a58c3f7b5 (diff) |
source/blender/blenloader/intern/readfile.c - use memmove rather then strncpy for overlapping strings.
source/blender/blenlib/intern/fileops.c - zero length strings would check for a slash before the strings first char.
source/gameengine/GameLogic/SCA_JoystickSensor.cpp - m_istrig_prev was not initialized
source/blender/src/editmesh.c - active face pointer was not set to NULL in free_editMesh()
Diffstat (limited to 'source/blender/blenlib')
-rw-r--r-- | source/blender/blenlib/intern/fileops.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/blenlib/intern/fileops.c b/source/blender/blenlib/intern/fileops.c index 76437720e45..ebd8f4be1cf 100644 --- a/source/blender/blenlib/intern/fileops.c +++ b/source/blender/blenlib/intern/fileops.c @@ -95,12 +95,12 @@ char *BLI_last_slash(const char *string) { void BLI_add_slash(char *string) { int len = strlen(string); #ifdef WIN32 - if (string[len-1]!='\\') { + if (len==0 || string[len-1]!='\\') { string[len] = '\\'; string[len+1] = '\0'; } #else - if (string[len-1]!='/') { + if (len==0 || string[len-1]!='/') { string[len] = '/'; string[len+1] = '\0'; } |