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

Commit 5496aa40 authored by Daichi Hirono's avatar Daichi Hirono Committed by android-build-merger
Browse files

Merge "Change the CHECK failure into function failure." into oc-dev am: bf6e9497

am: 4847c7f7

Change-Id: Iea6c547dc36ab3910f4100d0dbf60a56201a0107
parents 82a5c4f2 4847c7f7
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -119,7 +119,12 @@ ResultOrAgain WriteInternal(const FuseMessage<T>* self, int fd, int sockflag, co
                    return ResultOrAgain::kFailure;
            }
        }
        CHECK(static_cast<uint32_t>(result) == header.len);

        if (static_cast<unsigned int>(result) != header.len) {
            LOG(ERROR) << "Written bytes " << result << " is different from length in header "
                       << header.len;
            return ResultOrAgain::kFailure;
        }
        return ResultOrAgain::kSuccess;
    }
}