diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-04-18 13:12:18 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-04-18 13:12:18 +0400 |
commit | 45441c07d4609493aecf265b64ad0c108722e9db (patch) | |
tree | 47ccd4e9dff0d6521181a3997c7fdc49a651eda3 /source/blender/blenkernel/intern/writeffmpeg.c | |
parent | 01e2de7c538d4b0bbddefae7f5272af93a30319b (diff) |
various minor fixes
- collada export would run MEM_freeN on an un-initialized pointer in some cases.
- makesrna was missing a call to close a file.
- text cursor update function was missing a NULL check for st->text.
- possible (unlikely) un-initialized return value for bge python lamp.type, set error instead.
- possible (unlikely) missing NULL terminator with strncpy for ffmpeg.
Diffstat (limited to 'source/blender/blenkernel/intern/writeffmpeg.c')
-rw-r--r-- | source/blender/blenkernel/intern/writeffmpeg.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/writeffmpeg.c b/source/blender/blenkernel/intern/writeffmpeg.c index ff6ebcc487f..a1cdced9074 100644 --- a/source/blender/blenkernel/intern/writeffmpeg.c +++ b/source/blender/blenkernel/intern/writeffmpeg.c @@ -382,7 +382,7 @@ static void set_ffmpeg_property_option(AVCodecContext* c, IDProperty * prop) fprintf(stderr, "FFMPEG expert option: %s: ", prop->name); - strncpy(name, prop->name, 128); + BLI_strncpy(name, prop->name, sizeof(name)); param = strchr(name, ':'); @@ -1078,7 +1078,7 @@ int ffmpeg_property_add_string(RenderData *rd, const char * type, const char * s avcodec_get_context_defaults(&c); - strncpy(name_, str, 128); + strncpy(name_, str, sizeof(name_)); name = name_; while (*name == ' ') name++; |