[PATCH 15/17] staptree: initialize the synthetic flag on function calls

Aaron Merey amerey@redhat.com
Mon Nov 23 04:14:29 GMT 2026


The guru-mode check reads call->synthetic on a functioncall whose
constructor left the flag unset. Initialize it to false.

Memcheck reported

  Conditional jump or move depends on uninitialised value(s)
    at functioncall_security_check::visit_embeddedcode(embeddedcode*)
       (elaborate.cxx:3548)
  Uninitialised value was created by a heap allocation
    at ... operator new(unsigned long)
    by ... location_context::handle_GNU_parameter_ref(Dwarf_Op)
           (loc2stap.cxx:1906)

Assisted-by: Codex <noreply@openai.com>
---
 staptree.cxx | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/staptree.cxx b/staptree.cxx
index fcebcc79b..f4fc1f4fd 100644
--- a/staptree.cxx
+++ b/staptree.cxx
@@ -75,7 +75,8 @@ arrayindex::arrayindex ():
 {
 }
 
-functioncall::functioncall ()
+functioncall::functioncall ():
+  synthetic (false)
 {
 }
 
-- 
2.56.1



More information about the Systemtap mailing list