Avoid using tevent_util.h, which won't be available if we use the system
authorJelmer Vernooij <jelmer@samba.org>
Sun, 1 Mar 2009 15:38:07 +0000 (16:38 +0100)
committerJelmer Vernooij <jelmer@samba.org>
Sun, 1 Mar 2009 15:38:07 +0000 (16:38 +0100)
tevent.

lib/tevent/pytevent.c

index 4c0cbfd3cd1cf837cb2a82d0f924ac4b87d78a56..fe7e7e3e3826b7540fab7a9f54e80cfcfe9f942f 100644 (file)
@@ -29,7 +29,6 @@
 
 #include <tevent.h>
 #include <stdbool.h>
 
 #include <tevent.h>
 #include <stdbool.h>
-#include <tevent_util.h>
 
 typedef struct {
        PyObject_HEAD
 
 typedef struct {
        PyObject_HEAD
@@ -54,7 +53,8 @@ static PyObject *py_backend_list(PyObject *self)
     PyObject *ret;
     int i, len;
 
     PyObject *ret;
     int i, len;
 
-    len = ev_str_list_length(backends);
+    for (len = 0; backends[len]; len++);
+
     ret = PyList_New(len);
     for (i = 0; i < len; i++)
         PyList_SetItem(ret, i, PyString_FromString(backends[i]));
     ret = PyList_New(len);
     for (i = 0; i < len; i++)
         PyList_SetItem(ret, i, PyString_FromString(backends[i]));