aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Target/RISCV/Disassembler/RISCVDisassembler.cpp
diff options
context:
space:
mode:
authorYuval Deutscher <yuvald@sweet.security>2025-03-31 18:20:40 +0300
committerGitHub <noreply@github.com>2025-03-31 08:20:40 -0700
commit945c494e2c3c078e26ff521ef3e9455e0ff764ac (patch)
treeb98af5d83cf18d081905a9f635f64cf7674708a6 /llvm/lib/Target/RISCV/Disassembler/RISCVDisassembler.cpp
parent50949ebf523cc09cc911a12691fb79b6ac97102a (diff)
downloadllvm-945c494e2c3c078e26ff521ef3e9455e0ff764ac.zip
llvm-945c494e2c3c078e26ff521ef3e9455e0ff764ac.tar.gz
llvm-945c494e2c3c078e26ff521ef3e9455e0ff764ac.tar.bz2
[lldb] Use correct path for lldb-server executable (#131519)
Hey, This solves an issue where running lldb-server-20 with a non-absolute path (for example, when it's installed into `/usr/bin` and the user runs it as `lldb-server-20 ...` and not `/usr/bin/lldb-server-20 ...`) fails with `error: spawn_process failed: execve failed: No such file or directory`. The underlying issue is that when run that way, it attempts to execute a binary named `lldb-server-20` from its current directory. This is also a mild security hazard because lldb-server is often being run as root in the directory /tmp, meaning that an unprivileged user can create the file /tmp/lldb-server-20 and lldb-server will execute it as root. (although, well, it's a debugging server we're talking about, so that may not be a real concern) I haven't previously contributed to this project; if you want me to change anything in the code please don't hesitate to let me know.
Diffstat (limited to 'llvm/lib/Target/RISCV/Disassembler/RISCVDisassembler.cpp')
0 files changed, 0 insertions, 0 deletions