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

Commit 4031e1a4 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Stop using SO_SNDBUFFORCE" into pi-dev

parents 5f96d515 3d95d88b
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -149,8 +149,8 @@ bool SetupMessageSockets(base::unique_fd (*result)[2]) {
    }

    constexpr int kMaxMessageSize = sizeof(FuseBuffer);
    if (setsockopt(fds[0], SOL_SOCKET, SO_SNDBUFFORCE, &kMaxMessageSize, sizeof(int)) != 0 ||
        setsockopt(fds[1], SOL_SOCKET, SO_SNDBUFFORCE, &kMaxMessageSize, sizeof(int)) != 0) {
    if (setsockopt(fds[0], SOL_SOCKET, SO_SNDBUF, &kMaxMessageSize, sizeof(int)) != 0 ||
        setsockopt(fds[1], SOL_SOCKET, SO_SNDBUF, &kMaxMessageSize, sizeof(int)) != 0) {
        PLOG(ERROR) << "Failed to update buffer size for socket";
        return false;
    }
+1 −1
Original line number Diff line number Diff line
@@ -25,7 +25,7 @@ namespace fuse {

// The numbers came from sdcard.c.
// Maximum number of bytes to write/read in one request/one reply.
constexpr size_t kFuseMaxWrite = 256 * 1024;
constexpr size_t kFuseMaxWrite = 128 * 1024;
constexpr size_t kFuseMaxRead = 128 * 1024;
constexpr int32_t kFuseSuccess = 0;