summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrzej Hajda <a.hajda@samsung.com>2013-05-20 07:24:23 (GMT)
committerAndrzej Hajda <a.hajda@samsung.com>2013-05-22 14:14:13 (GMT)
commitbccf89a62a2e45cd45f4bf5d4adff9ec8a16b3bd (patch)
treec3506bd4c28a4be00ee9410ba372e2ac32f39ebf
parent353398b2161303052df7d9dc70a89dc7cffaf8fc (diff)
Do not stop encoding after empty buffers
Signed-off-by: Andrzej Hajda <a.hajda@samsung.com>
-rw-r--r--v4l2-mfc-encoder/func_dev.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/v4l2-mfc-encoder/func_dev.c b/v4l2-mfc-encoder/func_dev.c
index c3fff54..3cddef1 100644
--- a/v4l2-mfc-encoder/func_dev.c
+++ b/v4l2-mfc-encoder/func_dev.c
@@ -76,13 +76,13 @@ int func_deq_buf(struct io_dev *dev, enum io_dir dir)
for (i = 0; i < bufs->nplanes; ++i)
bufs->bytesused[bufs->nplanes * idx + i] = lens[i];
- dbg("Dequeued buffer %d/%d from %d:%d", idx, bufs->count, dev->fd, dir);
+ dbg("Dequeued buffer %d/%d from %d:%d ret=%d", idx, bufs->count, dev->fd, dir, ret);
--dev->io[dir].nbufs;
++dev->io[dir].counter;
- if (ret <= 0 || (dev->io[dir].limit &&
+ if (ret < 0 || (dev->io[dir].limit &&
dev->io[dir].limit <= dev->io[dir].counter)) {
dev->io[dir].state = FS_END;
dbg("End on %d:%d", dev->fd, dir);

Privacy Policy