huceke/omxplayer — pull request #49 by torarin (2012-09-06 16:23:26+00:00)
Title: Fix for issue #45, player exits early

It turns out that audio_render sends EOS before it has played out all its buffers. So in addition, we need to wait for OMX_IndexConfigAudioRenderingLatency to reach zero before destroying.

I commented out the timeouts in WaitCompletion lest they may cut short pathological files. I will find time later to move this logic into the main loop so that it can be properly aborted by the user.