Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Schlaile <peter@schlaile.de>2011-08-28 23:58:33 +0400
committerPeter Schlaile <peter@schlaile.de>2011-08-28 23:58:33 +0400
commit80459d97c7b50cfe8f630e2e20f5ccc55f854c23 (patch)
treea5690874bc1f710023500cc15c24177e781cbfd5 /source/blender/imbuf/intern
parent28feca36d7e0a5f15d9c03f3781ba34cca8c4670 (diff)
== Sequencer / proxies ==
fixed crash pointed out by blendervse: 100%-proxy could lead to a segfault under certain conditions.
Diffstat (limited to 'source/blender/imbuf/intern')
-rw-r--r--source/blender/imbuf/intern/indexer.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/source/blender/imbuf/intern/indexer.c b/source/blender/imbuf/intern/indexer.c
index f624694b324..5a819cef652 100644
--- a/source/blender/imbuf/intern/indexer.c
+++ b/source/blender/imbuf/intern/indexer.c
@@ -573,11 +573,15 @@ static int add_to_proxy_output_ffmpeg(
ctx->frame->data, ctx->frame->linesize);
}
- ctx->frame->pts = ctx->cfra++;
+ frame = ctx->sws_ctx ? (frame ? ctx->frame : 0) : frame;
+
+ if (frame) {
+ frame->pts = ctx->cfra++;
+ }
outsize = avcodec_encode_video(
ctx->c, ctx->video_buffer, ctx->video_buffersize,
- ctx->sws_ctx ? (frame ? ctx->frame : 0) : frame);
+ frame);
if (outsize < 0) {
fprintf(stderr, "Error encoding proxy frame %d for '%s'\n",