Commit 2a7a5f84 authored by jan.koester's avatar jan.koester
Browse files

test

parent 17fdf27b
Loading
Loading
Loading
Loading
+9 −2
Changes for src/event/kqueue.cpp: 9 added lines, 2 removed lines.
Original line number Diff line number Diff line
@@ -133,10 +133,17 @@ namespace netplus {
        };

        int getEventFlags(int pos) {
            // Check for error/hangs (EPOLLHUP/EPOLLERR)
            if (_Events[pos].flags & (EV_EOF | EV_ERROR)) {
                NetException e;
                e[NetException::Error] <<  "getEventFlags: som error";
                e[NetException::Error] << "getEventFlags: event error detected.";

                if (_Events[pos].flags & EV_EOF) {
                    e[NetException::Error] << " Connection closed by remote peer (EV_EOF/Hangup).";
                }
                if (_Events[pos].flags & EV_ERROR) {
                    e[NetException::Error] << " Unrecoverable I/O error (EV_ERROR).";
                }

                throw e;
            }
            return _Events[pos].filter;