mirror of
https://projects.vdr-developer.org/git/vdr-plugin-streamdev.git
synced 2023-10-10 17:16:51 +00:00
fixed memory leak in libdvbmpeg read_pes (fixes #769)
This commit is contained in:
@@ -596,7 +596,10 @@ int read_pes(int f, pes_packet *p){
|
||||
|
||||
if (p->length >0){
|
||||
buf = (uint8_t *) malloc(p->length);
|
||||
if((neof = save_read(f,buf,p->length))< p->length) return -1;
|
||||
if((neof = save_read(f,buf,p->length))< p->length){
|
||||
free(buf);
|
||||
return -1;
|
||||
}
|
||||
cread_pes((char *)buf,p);
|
||||
free(buf);
|
||||
} else return 0;
|
||||
|
Reference in New Issue
Block a user