diff options
author | Frank Ch. Eigler <fche@elastic.org> | 2009-10-19 11:33:24 -0400 |
---|---|---|
committer | Frank Ch. Eigler <fche@elastic.org> | 2009-10-19 13:11:30 -0400 |
commit | 2e526dabcf4b15fb102e295b282df3af54d5c9d3 (patch) | |
tree | 026750014ab7bbbd046ac555ee44fb06d29b010d /testsuite/systemtap.syscall | |
parent | a34babfa5246b1f8393c18fde450ec684f11bc21 (diff) | |
download | systemtap-steved-2e526dabcf4b15fb102e295b282df3af54d5c9d3.tar.gz systemtap-steved-2e526dabcf4b15fb102e295b282df3af54d5c9d3.tar.xz systemtap-steved-2e526dabcf4b15fb102e295b282df3af54d5c9d3.zip |
PR10799: warn on possibly uintended local-vs-global namespace collision
* elaborate.cxx (find_var): Take extra token parameter.
Look for cross-file global variable resolution, signal
a warning.
* testsuite/systemtap.examples/io/traceio2.stp: Fix it.
* testsuite/systemtap.syscall/sys.stp: Fix it.
* NEWS: Document it.
Diffstat (limited to 'testsuite/systemtap.syscall')
-rwxr-xr-x | testsuite/systemtap.syscall/sys.stp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/testsuite/systemtap.syscall/sys.stp b/testsuite/systemtap.syscall/sys.stp index e3564a15..79c7ff57 100755 --- a/testsuite/systemtap.syscall/sys.stp +++ b/testsuite/systemtap.syscall/sys.stp @@ -1,4 +1,4 @@ -global indent, indent_str, entry +global indent, indent_str, entry_p probe begin { indent = 0 @@ -13,22 +13,22 @@ probe begin { probe syscall.* ? { if (pid() == target()) { - if (entry) printf("\n") + if (entry_p) printf("\n") printf("%s%s: %s (%s) = ", indent_str[indent], execname(), name, argstr) # printf("%s%s: %s (%s) = ", indent_str[indent], execname(), probefunc(), argstr) indent++ - entry = 1 + entry_p = 1 } } probe syscall.*.return ? { if (pid() == target()) { if (indent) indent-- - if (entry) + if (entry_p) printf("%s\n", retstr) else printf("%s%s\n", indent_str[indent],retstr) - entry = 0 + entry_p = 0 } } |