forked from qt-creator/qt-creator
Utils: Don't use ptrace in the process stub
Previously, ptrace was used to keep a tight hold on the spawned process across the exec(), followed by raising a SIGSTOP to allow un-racy attaching a debugger. This makes implementation of 'Run as root' more difficult and is apparently not needed: instead of the ptrace use, the SIGSTOP can be raised directly, before exec(). Change-Id: I36025ac547b2a335e2a203c728d221830e4c0a7d Reviewed-by: Christian Stenger <christian.stenger@qt.io> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
@@ -1157,7 +1157,8 @@ void GdbEngine::handleStopResponse(const GdbMi &data)
|
||||
const QString func = frame["func"].data();
|
||||
if (from.endsWith("/ld-linux.so.2")
|
||||
|| from.endsWith("/ld-linux-x86-64.so.2")
|
||||
|| func == "clone")
|
||||
|| func == "clone"
|
||||
|| func == "kill")
|
||||
{
|
||||
showMessage("INTERNAL CONTINUE AFTER SIGSTOP FROM STUB", LogMisc);
|
||||
notifyInferiorSpontaneousStop();
|
||||
|
||||
Reference in New Issue
Block a user