[wrs_core]Fix hang when port disable called for empty port.

BZ: 148867

This issue was found when using gstreamer with Intel OMX Core
using the gst-omx plugin. In gst-omx playback, when transitioning
component to idle state the output port is disabled. The call to
disable output port hangs in WaitPortBufferCompletion() in the OMX
IL Core. This is due to a bug where WaitPortBufferCompletion() waits for
buffer free operation to complete on an empty port. Since port
is empty buffer free will never be called. Added check on buffer
count before doing the wait to avoid the hang.

Change-Id: If34c3388be978bcec5d33100858d343468d835f9
Signed-off-by: Sameer Kibey <sameer.kibey@intel.com>
1 file changed
tree: 2cc79d041b33b054afcf81762cae21a9242a9266
  1. base/
  2. core/
  3. utils/
  4. .gitignore
  5. Android.mk
  6. AUTHORS
  7. ebuild.mk
  8. README