]> git.sesse.net Git - vlc/blobdiff - test/native/gc.c
Some initial work for streaming profiles
[vlc] / test / native / gc.c
index eaa5ff28206e55405edd433b0cbc712634d088b9..de198de2f4c5daaf79a89a8803ba8e1a4ecabc5d 100644 (file)
@@ -1,8 +1,6 @@
 #include "../pyunit.h"
 #include <vlc/vlc.h>
 
-#include <vlc_common.h>
-
 struct mygc
 {
     VLC_GC_MEMBERS;
@@ -21,9 +19,8 @@ static PyObject *gc_test( PyObject *self, PyObject *args )
 {
      mygc *gc = (mygc *)malloc( sizeof( mygc ) );
 
-     vlc_gc_init( gc, mygc_destructor );
-     gc->i_gc_refcount = 0;
-
+     vlc_gc_init( gc, mygc_destructor, NULL );
+     ASSERT( gc->i_gc_refcount == 0, "Refcount should be 0" );
      vlc_gc_incref( gc );
      ASSERT( gc->i_gc_refcount == 1, "Refcount should be 1" );
      vlc_gc_incref( gc );