diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-04-21 11:59:16 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-04-21 11:59:16 +0400 |
commit | 0430572deef05ce96e5b62536dd9ed4f9e37f25c (patch) | |
tree | 5770a2dcea352ffdf0c0763546cf34ead418522c | |
parent | 9c69a8028bac859bd5b429cdd4e7a652dd1d6d15 (diff) |
bugfix [#22098] Binreloc buffer overrun
from Dan Eicher (dna)
there are many of these in blender however this case could happen quite easily.
-rw-r--r-- | source/blender/blenlib/intern/path_util.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/blenlib/intern/path_util.c b/source/blender/blenlib/intern/path_util.c index fa77b2138da..05b1bc5fca7 100644 --- a/source/blender/blenlib/intern/path_util.c +++ b/source/blender/blenlib/intern/path_util.c @@ -1312,7 +1312,7 @@ void BLI_where_am_i(char *fullname, const char *name) /* linux uses binreloc since argv[0] is not relyable, call br_init( NULL ) first */ path = br_find_exe( NULL ); if (path) { - strcpy(fullname, path); + BLI_strncpy(fullname, path, sizeof(fullname)); free(path); return; } |