Commit 4a5bc483 authored by jan.koester's avatar jan.koester
Browse files

test

parent 5430ed4e
Loading
Loading
Loading
Loading
+6 −4
Changes for src/event/kqueue.cpp: 6 added lines, 4 removed lines.
Original line number Diff line number Diff line
@@ -197,10 +197,12 @@ namespace netplus {

            ccon->lasteventime = time(nullptr);

            struct kevent setevent {};
            setevent.udata = ccon.release();
            con *sccon= ccon.release();

            con *sccon=setevent.udata;
            struct kevent setevent {0};
            setevent.udata =sccon;

            setevent.udata;

            EV_SET(&setevent, ccon->csock->fd(), EVFILT_READ, EV_ADD | EV_ONESHOT,0,0,sccon);

@@ -213,7 +215,7 @@ namespace netplus {
                throw exception;
            }

            evconnection ->ConnectEvent(sccon,tid,args);
            evconnection ->ConnectEvent(*sccon,tid,args);
            {
                std::lock_guard<std::mutex> clock(sccon->event_mutex),global_lock(POLL_HANDLER_MUTEX);
                CONNECTIONS.emplace(sccon->csock->fd(),sccon);