mirror of
https://github.com/videolan/vlc.git
synced 2024-12-14 20:24:21 +08:00
python bindings: use mediacontrol_StreamInformation__free + fix
memleak in MediaControl_snapshot
This commit is contained in:
parent
a5623bf38f
commit
62f24677c1
@ -406,6 +406,8 @@ MediaControl_snapshot( PyObject *self, PyObject *args )
|
||||
PyDict_SetItemString( py_obj, "date",
|
||||
Py_BuildValue( "L", p_retval->date ) );
|
||||
|
||||
mediacontrol_RGBPicture__free( p_retval );
|
||||
|
||||
return py_obj;
|
||||
}
|
||||
|
||||
@ -463,8 +465,7 @@ MediaControl_get_stream_information( PyObject *self, PyObject *args )
|
||||
PyDict_SetItemString( py_obj, "length",
|
||||
Py_BuildValue( "L", retval->length ) );
|
||||
|
||||
free( retval->url );
|
||||
free( retval );
|
||||
mediacontrol_StreamInformation__free( retval );
|
||||
|
||||
return py_obj;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user