Changeset 12e055f6e6c1a79693f1c61739270ebcb1c0a118
- Timestamp:
- 29/05/07 11:45:21
(1 year ago)
- Author:
- Olivier Aubert <olivier.aubert@liris.cnrs.fr>
- git-committer:
- Olivier Aubert <olivier.aubert@liris.cnrs.fr> 1180431921 +0000
- git-parent:
[11884b884c536d7f6305ff3459f630bb458ebda2]
- git-author:
- Olivier Aubert <olivier.aubert@liris.cnrs.fr> 1180431921 +0000
- Message:
python bindings, vlc_instance.c: fix memleak + use PyObject?_DEL (patch
by Jan David Mol)
-
Files:
-
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
| r5b8066f |
r12e055f |
|
| 83 | 83 | int i_size = 0; |
|---|
| 84 | 84 | |
|---|
| 85 | | self = PyObject_New( vlcInstance, &vlcInstance_Type ); |
|---|
| 86 | | |
|---|
| 87 | | |
|---|
| 88 | 85 | if( PyArg_ParseTuple( args, "O", &py_list ) ) |
|---|
| 89 | 86 | { |
|---|
| … | … | |
| 98 | 95 | PyErr_Clear( ); |
|---|
| 99 | 96 | } |
|---|
| | 97 | |
|---|
| | 98 | self = PyObject_New( vlcInstance, &vlcInstance_Type ); |
|---|
| 100 | 99 | |
|---|
| 101 | 100 | Py_BEGIN_ALLOW_THREADS |
|---|
| … | … | |
| 115 | 114 | libvlc_exception_t ex; |
|---|
| 116 | 115 | libvlc_destroy( LIBVLC_INSTANCE->p_instance, &ex ); |
|---|
| 117 | | PyMem_DEL( self ); |
|---|
| | 116 | PyObject_DEL( self ); |
|---|
| 118 | 117 | } |
|---|
| 119 | 118 | |
|---|