Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8e4e25e0 authored by Chris Weir's avatar Chris Weir
Browse files

Don't crash on pollerr

I should have checked for <=0, not == 0. Oops

Bug: 224850481
Test: TCU and HU don't burst into flames when pollerr happens.
Change-Id: I1b1d0855a588d065d29cad31b2ca40e4d981e086
parent 64e3ec21
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -55,7 +55,7 @@ void Socket::clearPollErr() {
    if (errno != EINVAL) {
        PLOG(WARNING) << "clearPollError() caught unexpected error: ";
    }
    CHECK_EQ(bytesReceived, 0) << "clearPollError() recvd " << bytesReceived << " instead of zero!";
    CHECK_LE(bytesReceived, 0) << "clearPollError() didn't find an error!";
}

bool Socket::send(const Buffer<nlmsghdr>& msg, const sockaddr_nl& sa) {