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

Commit 9c4fda6c authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "adb: "support" O_CLOEXEC in adb_open on Windows."

parents 151499e4 4b019a5f
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -356,6 +356,9 @@ int adb_open(const char* path, int options) {
    DWORD desiredAccess = 0;
    DWORD shareMode = FILE_SHARE_READ | FILE_SHARE_WRITE;

    // CreateFileW is inherently O_CLOEXEC by default.
    options &= ~O_CLOEXEC;

    switch (options) {
        case O_RDONLY:
            desiredAccess = GENERIC_READ;