Blame SOURCES/rhbz1643997.0028-testcase-for-PR23875.patch

583230
From c3023bef537648b282f266878ea8de7a350b3a45 Mon Sep 17 00:00:00 2001
583230
From: Serhei Makarov <smakarov@redhat.com>
583230
Date: Fri, 9 Nov 2018 16:42:21 -0500
583230
Subject: [PATCH 28/32] testcase for PR23875
583230
583230
This triggers a 'stack smashing' error in the userspace interpreter.
583230
583230
* testsuite/systemtap.bpf/bpf_tests/pr23875.stp: New testcase.
583230
---
583230
 testsuite/systemtap.bpf/bpf_tests/pr23875.stp | 18 ++++++++++++++++++
583230
 1 file changed, 18 insertions(+)
583230
 create mode 100644 testsuite/systemtap.bpf/bpf_tests/pr23875.stp
583230
583230
diff --git a/testsuite/systemtap.bpf/bpf_tests/pr23875.stp b/testsuite/systemtap.bpf/bpf_tests/pr23875.stp
583230
new file mode 100644
583230
index 000000000..a31f1d087
583230
--- /dev/null
583230
+++ b/testsuite/systemtap.bpf/bpf_tests/pr23875.stp
583230
@@ -0,0 +1,18 @@
583230
+global t
583230
+
583230
+probe begin {
583230
+  printf("BEGIN\n")
583230
+}
583230
+
583230
+probe kernel.function("vfs_read") {
583230
+  t["key"] = 6
583230
+  exit()
583230
+}
583230
+
583230
+probe end {
583230
+  c = 0
583230
+  foreach (k in t)
583230
+    c++
583230
+  printf("%d\n", c)
583230
+  printf("END PASS\n")
583230
+}
583230
-- 
583230
2.14.5
583230