|
Revision 99fab9089e9e1709d9c3a4bc5ced0c137ac59134, 0.6 kB
(checked in by Rémi Denis-Courmont <rem@videolan.org>, 7 months ago)
|
Don't include config.h from the headers - refs #297.
Missing some cases that I could not test.
Also ffmpeg/chroma.c is locked, so I can but leave it broken.
Fix is for the remaining modules is obvious and the issue is easy to detect.
|
- Property mode set to
100644
|
| Line | |
|---|
| 1 |
#include "../pyunit.h" |
|---|
| 2 |
#ifdef HAVE_CONFIG_H |
|---|
| 3 |
# include "config.h" |
|---|
| 4 |
#endif |
|---|
| 5 |
|
|---|
| 6 |
#include <vlc/vlc.h> |
|---|
| 7 |
|
|---|
| 8 |
PyObject *threadvar_test( PyObject *self, PyObject *args ) |
|---|
| 9 |
{ |
|---|
| 10 |
void *p_foo = malloc(1); |
|---|
| 11 |
vlc_threadvar_t key, key2; |
|---|
| 12 |
|
|---|
| 13 |
vlc_threadvar_create( NULL, &key ); |
|---|
| 14 |
vlc_threadvar_set( &key, p_foo ); |
|---|
| 15 |
ASSERT( vlc_threadvar_get( &key ) == p_foo, "key does not match" ); |
|---|
| 16 |
|
|---|
| 17 |
vlc_threadvar_create( NULL, &key2 ); |
|---|
| 18 |
vlc_threadvar_set( &key2, NULL ); |
|---|
| 19 |
ASSERT( vlc_threadvar_get( &key2 ) == NULL, "key2 does not match" ); |
|---|
| 20 |
|
|---|
| 21 |
Py_INCREF( Py_None ); |
|---|
| 22 |
return Py_None; |
|---|
| 23 |
} |
|---|