From 5978fd4ed958fb751f9141248bf833971826b0d0 Mon Sep 17 00:00:00 2001 From: kpfleming Date: Wed, 31 Aug 2005 22:12:23 +0000 Subject: ensure revents fields are initialized before calling poll() git-svn-id: http://svn.digium.com/svn/asterisk/trunk@6476 f38db490-d61c-443f-a65b-d21fe96a405b --- io.c | 1 + 1 file changed, 1 insertion(+) (limited to 'io.c') diff --git a/io.c b/io.c index 9fd4e6d8a..9c9581114 100755 --- a/io.c +++ b/io.c @@ -165,6 +165,7 @@ int *ast_io_add(struct io_context *ioc, int fd, ast_io_cb callback, short events */ ioc->fds[ioc->fdcnt].fd = fd; ioc->fds[ioc->fdcnt].events = events; + ioc->fds[ioc->fdcnt].revents = 0; ioc->ior[ioc->fdcnt].callback = callback; ioc->ior[ioc->fdcnt].data = data; ioc->ior[ioc->fdcnt].id = (int *)malloc(sizeof(int)); -- cgit v1.2.3