aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
diff options
context:
space:
mode:
authorMed Ismail Bennani <medismail.bennani@gmail.com>2020-04-23 15:43:54 +0200
committerMed Ismail Bennani <medismail.bennani@gmail.com>2020-05-04 17:33:55 +0200
commit015117411e11458f9816ba4359246132164a4297 (patch)
treef517cc6006cc89a67d32b0318934814f029d6f6b /llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
parent307cfdf5338641e3a895857ef02dc9da35cd0eb6 (diff)
downloadllvm-015117411e11458f9816ba4359246132164a4297.zip
llvm-015117411e11458f9816ba4359246132164a4297.tar.gz
llvm-015117411e11458f9816ba4359246132164a4297.tar.bz2
[lldb/Host] Improve error messages on unowned read files
When trying to read a core file that is not owned by the user running lldb and that doesn't have read permission on the file, lldb shows a misleading error message: ``` Unable to find process plug-in for core file ``` This is due to the fact that currently, lldb doesn't check the file ownership. And when trying to to open and read a core file, the syscall fails, which prevents a process to be created. Since lldb already have a portable `open` syscall interface, lets take advantage of that and delegate the error handling to the syscall itself. This way, no matter if the file exists or if the user has proper ownership, lldb will always try to open the file, and behave accordingly to the error code returned. rdar://42630030 https://reviews.llvm.org/D78712 Signed-off-by: Med Ismail Bennani <medismail.bennani@gmail.com>
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp')
0 files changed, 0 insertions, 0 deletions