Skip to content
Snippets Groups Projects
Commit 43e5fbd8 authored by Thiago Jung Bauermann's avatar Thiago Jung Bauermann
Browse files

gdbserver: Add PID parameter to linux_get_auxv and linux_get_hwcap


This patch doesn't change gdbserver behaviour, but after later changes are
made it avoids a null pointer dereference when HWCAP needs to be obtained
for a specific process while current_thread is nullptr.

Fixing linux_read_auxv, linux_get_hwcap and linux_get_hwcap2 to take a PID
parameter seems more correct than setting current_thread in one particular
code path.

Changes are propagated to allow passing the new parameter through the call
chain.

Approved-By: default avatarSimon Marchi <simon.marchi@efficios.com>
parent cbd02f9f
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment