Browse Source

avdevice/iec61883: free packet on buffer allocation error

Fixes Coverity CID 1396416.

Signed-off-by: Marton Balint <cus@passwd.hu>
(cherry picked from commit 4556dad2b7379a527134db519ab60111abefaf10)
tags/n3.2.11
Marton Balint James Almer 9 years ago
parent
commit
1fd992af60
1 changed files with 1 additions and 0 deletions
  1. +1
    -0
      libavdevice/iec61883.c

+ 1
- 0
libavdevice/iec61883.c View File

@@ -120,6 +120,7 @@ static int iec61883_callback(unsigned char *data, int length,

packet->buf = av_malloc(length);
if (!packet->buf) {
av_free(packet);
ret = -1;
goto exit;
}


Loading…
Cancel
Save