summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2018-03-24 23:55:56 +0000
committerCarl Hetherington <cth@carlh.net>2018-03-24 23:55:56 +0000
commit7b16280edec019d0583b52fab25549a91c3676e6 (patch)
tree76577b70c9594d77ab16f953a829f6966c71e6b0 /src/lib
parent85176cead21efe9667441800912d7aeedb9cf1d2 (diff)
Fix crash when changing DCP audio channel count.
Without this we ask the AudioMerger to merge new buffers with N channels with old buffers with M channels, which it can't do. I'm not convinced this is the best solution but I think it will do for now.
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/player.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/lib/player.cc b/src/lib/player.cc
index e8005c655..7e2f8ad08 100644
--- a/src/lib/player.cc
+++ b/src/lib/player.cc
@@ -283,6 +283,8 @@ Player::film_changed (Film::Property p)
if (_film->audio_processor ()) {
_audio_processor = _film->audio_processor()->clone (_film->audio_frame_rate ());
}
+ } else if (p == Film::AUDIO_CHANNELS) {
+ _audio_merger.clear ();
}
}