diff options
author | Peter Schlaile <peter@schlaile.de> | 2008-10-12 16:00:26 +0400 |
---|---|---|
committer | Peter Schlaile <peter@schlaile.de> | 2008-10-12 16:00:26 +0400 |
commit | 3110f63162b3194c0fd059f8e8cd2096cb97df74 (patch) | |
tree | 74850311f6e6c9892605b137bc9fc76d1c847884 | |
parent | f8d60578086e0405d56244b783d966c3d872b21a (diff) |
== Sequencer ==
This fixes (works around):
[#13598] LOAD / SAVE: Segfault after attempting to load surround encoded file
-rw-r--r-- | source/blender/src/hddaudio.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/source/blender/src/hddaudio.c b/source/blender/src/hddaudio.c index 506a9b1b8aa..7e6b314f296 100644 --- a/source/blender/src/hddaudio.c +++ b/source/blender/src/hddaudio.c @@ -150,6 +150,15 @@ struct hdaudio * sound_open_hdaudio(char * filename) return 0; } + if (pCodecCtx->channels > 2) { + fprintf(stderr, "Sorry, audio file has too many channels." + " Will fix in future, but resampler doesn't support " + "this.\n"); + avcodec_close(pCodecCtx); + av_close_input_file(pFormatCtx); + return 0; + } + rval = (struct hdaudio *)MEM_mallocN(sizeof(struct hdaudio), "hdaudio struct"); |