Skip to content

Instantly share code, notes, and snippets.

@agentzh

agentzh/a.patch Secret

Created October 29, 2020 08:47
Show Gist options
  • Save agentzh/cb093f410ef2740efa10d65656806e3c to your computer and use it in GitHub Desktop.
Save agentzh/cb093f410ef2740efa10d65656806e3c to your computer and use it in GitHub Desktop.
commit 01df5daee0ec4c2d4b0714095bfed1d475846f7e
Author: Yichun Zhang (agentzh) <agentzh@gmail.com>
Date: Wed Oct 28 22:28:41 2020 -0700
fixed Dl hang.
diff --git a/runtime/linux/task_finder2.c b/runtime/linux/task_finder2.c
index 0ba614741..8aa0ed71a 100644
--- a/runtime/linux/task_finder2.c
+++ b/runtime/linux/task_finder2.c
@@ -876,7 +876,7 @@ __stp_utrace_attach_match_filename(struct task_struct *tsk,
// when the thread gets quiesced.
rc = __stp_utrace_attach(tsk, &tgt->ops, tgt,
__STP_ATTACHED_TASK_EVENTS,
- UTRACE_STOP);
+ UTRACE_INTERRUPT);
if (rc != 0 && rc != EPERM)
break;
tgt->engine_attached = 1;
@@ -1778,7 +1778,7 @@ stap_start_task_finder(void)
// Set up events we need for attached tasks.
rc = __stp_utrace_attach(tsk, &tgt->ops, tgt,
__STP_ATTACHED_TASK_EVENTS,
- UTRACE_STOP);
+ UTRACE_INTERRUPT);
dbug_task(2, "__stp_utrace_attach() for %d returned %d", tsk->tgid,
rc);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment