* c++ -I/usr/local/include -o time-test time-test.c -L/usr/local/lib -levent
*
*
- * Wed 2006-12-27 - Modified by Leandro Lucarella <llucarella@integratech.com.ar>
+ * Wed 2006-12-27 - Modified by Leandro Lucarella <llucax+eventxx@gmail.com>
*
* Adapted to test the C++ inteface.
*
#include <cstring>
#include <cerrno>
-#include <event>
+#include <eventxx>
int test_okay = 1;
int called = 0;
-event::dispatcher d;
-event::cevent* ev;
+eventxx::dispatcher d;
+eventxx::cevent* ev;
void
read_cb(int fd, short event, void *arg)
int
main (int argc, char **argv)
{
- char *test = "test string";
+ const char* test = "test string";
int pair[2];
if (socketpair(AF_UNIX, SOCK_STREAM, 0, pair) == -1)
shutdown(pair[0], SHUT_WR);
/* Initalize one event */
- ev = new event::cevent(pair[1], EV_READ, read_cb, NULL);
+ ev = new eventxx::cevent(pair[1], eventxx::READ, read_cb, NULL);
d.add(*ev);