amlvideo2: screenshot buffer leak. [1/1]

PD#TV-7948

Problem:
Amlvideo2 will not put the last buffer of vdin back.

Solution:
Return temp vf to vdin in amlvideo2.

Verify:
on X301

Change-Id: I6f7f604a8a0fa8f577d50e242968e0aa52450cda
Signed-off-by: renjiang.han <renjiang.han@amlogic.com>
This commit is contained in:
renjiang.han
2019-07-24 19:56:12 +08:00
parent ed94e98d08
commit 0178c2ae2d

View File

@@ -4035,7 +4035,14 @@ static int amlvideo2_thread(void *data)
}
/*msleep(10);*/
node->tmp_vf = NULL;
if (node->tmp_vf != NULL) {
if ((node->recv.name != NULL) &&
(!vf_get_receiver(node->recv.name))) {
vf_put(node->tmp_vf, node->recv.name);
}
node->tmp_vf = NULL;
}
if (amlvideo2_dbg_en) {
if (node->vid == 0)
pr_info("amlvideo2.0 thread exit.\n");