net engine: termination fixes
authorJens Axboe <jens.axboe@oracle.com>
Mon, 19 Jan 2009 11:38:27 +0000 (12:38 +0100)
committerJens Axboe <jens.axboe@oracle.com>
Mon, 19 Jan 2009 11:38:27 +0000 (12:38 +0100)
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
engines/net.c

index afb3265..700f162 100644 (file)
@@ -43,7 +43,7 @@ static int poll_wait(struct thread_data *td, int fd, short events)
                ret = poll(&pfd, 1, -1);
                if (ret < 0) {
                        if (errno == EINTR)
-                               continue;
+                               break;
 
                        td_verror(td, errno, "poll");
                        return -1;
@@ -55,8 +55,6 @@ static int poll_wait(struct thread_data *td, int fd, short events)
 
        if (pfd.revents & events)
                return 1;
-       else if (td->terminate)
-               return 1;
 
        return -1;
 }