Commit 03382453 by Greg Hartman

Improve advice for attaching the debugger

Change-Id: I6ca5697a8b672a1e20bcb7999cf4d9ba544f9558 Reviewed-on: https://swiftshader-review.googlesource.com/3117Reviewed-by: 's avatarNicolas Capens <capn@google.com> Tested-by: 's avatarGreg Hartman <ghartman@google.com>
parent 7ca4db3c
...@@ -15,9 +15,10 @@ void AndroidEnterDebugger() ...@@ -15,9 +15,10 @@ void AndroidEnterDebugger()
int debug_uid = atoi(value); int debug_uid = atoi(value);
if ((debug_uid >= 0) && (geteuid() < static_cast<uid_t>(debug_uid))) if ((debug_uid >= 0) && (geteuid() < static_cast<uid_t>(debug_uid)))
{ {
ALOGE("Waiting for debugger: gdbserver :${PORT} --attach %u", gettid()); ALOGE("Waiting for debugger: gdbserver :${PORT} --attach %u. Look for thread %u", getpid(), gettid());
while (1) { volatile int waiting = 1;
pause(); while (waiting) {
sleep(1);
} }
} else { } else {
ALOGE("No debugger"); ALOGE("No debugger");
......
Markdown is supported
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