[PATCH 5/6] mfplat: Add a warning for buffer method failure (Coverity).

Nikolay Sivov nsivov at codeweavers.com
Mon Mar 30 06:21:28 CDT 2020


Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
---
 dlls/mfplat/buffer.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/dlls/mfplat/buffer.c b/dlls/mfplat/buffer.c
index 4bbb36b683..1a31299d24 100644
--- a/dlls/mfplat/buffer.c
+++ b/dlls/mfplat/buffer.c
@@ -1211,7 +1211,8 @@ static HRESULT sample_copy_to_buffer(struct sample *sample, IMFMediaBuffer *buff
         }
     }
 
-    IMFMediaBuffer_SetCurrentLength(buffer, dst_current_length);
+    if (FAILED(IMFMediaBuffer_SetCurrentLength(buffer, dst_current_length)))
+        WARN("Failed to set buffer length.\n");
 
     if (locked)
         IMFMediaBuffer_Unlock(buffer);
-- 
2.25.1




More information about the wine-devel mailing list