diff options
author | Edward Hervey <bilboed@bilboed.com> | 2009-05-19 11:20:19 +0200 |
---|---|---|
committer | Edward Hervey <bilboed@bilboed.com> | 2009-05-19 11:20:19 +0200 |
commit | 65c046b1eac3c20497ec14c35d3f114dad090fa4 (patch) | |
tree | 562f8210515c8d30589e7ed0ca2b577bad21f70b | |
parent | 94ca1b005ee770830dd9545acb5ebb352cae7c38 (diff) |
audioresample: Don't drain remaining buffers after a flush.
If we were resetted (due to a flush), we can not drain the remaining
buffers since they would be pushed before a valid new newsegment event.
-rw-r--r-- | gst/audioresample/gstaudioresample.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gst/audioresample/gstaudioresample.c b/gst/audioresample/gstaudioresample.c index 20e43c1cc..8fa04577e 100644 --- a/gst/audioresample/gstaudioresample.c +++ b/gst/audioresample/gstaudioresample.c @@ -778,6 +778,10 @@ gst_audio_resample_push_drain (GstAudioResample * resample) if (!resample->state) return; + /* Don't drain samples if we were resetted. */ + if (resample->next_ts == -1) + return; + need_convert = (resample->funcs->width != resample->width); resample->funcs->get_ratio (resample->state, &num, &den); |