Commit 4a999da2 authored by Yuxuan Shui's avatar Yuxuan Shui Committed by Tobias Hieta
Browse files

[lldb][windows] _wsopen_s does not accept bits other than `_S_IREAD | _S_IWRITE`

When sending file from a Linux host to a Windows remote, Linux host will try to copy the source file's permission bits, which will contain `_S_I?GRP` and `_S_I?OTH` bits. Those bits are rejected by `_wsopen_s`, causing it to return EINVAL.

This patch masks out the rejected bits.

GitHub issue: #64313

Reviewed By: jasonmolenda, DavidSpickett

Differential Revision: https://reviews.llvm.org/D156817

(cherry picked from commit 9a4b3fdb)
parent 1b111373
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment