[Lldb-commits] [lldb] [lldb] Fix and re-enable TestUseSourceCache.py (PR #111237)
Igor Kudrin via lldb-commits
lldb-commits at lists.llvm.org
Mon Oct 7 16:12:23 PDT 2024
igorkudrin wrote:
> I don't see any relevant changes on those files, so I don't know the where `openNativeFileInternal()` comes into the picture.
`getFileAux()` calls `openNativeFileForRead()` first and then passes the file descriptor to `getOpenFileImpl()`. `openNativeFileForRead()` eventually calls `openNativeFileInternal()`, which passes `FILE_SHARE_DELETE` to `::CreateFileW()`, and that was already like that in times of [D76806](https://reviews.llvm.org/D76806) `Remove m_last_file_sp from SourceManager`, so I don't know why the opened file was locked for deletion back then.
The only change in the sequence I can see was replacing `WritableMemoryBuffer` with `MemoryBuffer`, caused by [D122856](https://reviews.llvm.org/D122856), `[lldb] Refactor DataBuffer so we can map files as read-only`, but the file was still opened with the `FILE_SHARE_DELETE` mode.
https://github.com/llvm/llvm-project/pull/111237
More information about the lldb-commits
mailing list