about summary refs log tree commit diff
path: root/trace-call.cc
diff options
context:
space:
mode:
Diffstat (limited to 'trace-call.cc')
-rw-r--r--trace-call.cc11
1 files changed, 6 insertions, 5 deletions
diff --git a/trace-call.cc b/trace-call.cc
index d154b4f..9d22599 100644
--- a/trace-call.cc
+++ b/trace-call.cc
@@ -38,7 +38,7 @@ main (int argc, char** argv)
       std::cin >> std::hex >> return_address;
       if (std::cin.fail ())
         break;
-      auto* block = find_block (cs, co, return_address);
+      auto* const block = find_block (cs, co, return_address);
       // Each function call creates an interprocedure edge,
       // hence its basic block ends with the call site.
       // The control flow then naturally goes to the next basic block
@@ -50,11 +50,12 @@ main (int argc, char** argv)
       std::vector <Dyninst::ParseAPI::Function*> functions;
       block->getFuncs (functions);
       Dyninst::Address call_address = 0;
-      for (auto* fun : functions)
-        for (auto* call_edge : fun->callEdges ())
+      for (auto* const fun : functions)
+        for (auto* const call_edge : fun->callEdges ())
           {
-            auto* call_block = call_edge->src ();
-            auto* return_block = fun->getImmediatePostDominator (call_block);
+            auto* const call_block = call_edge->src ();
+            auto* const return_block
+              = fun->getImmediatePostDominator (call_block);
             if (return_block == nullptr || *return_block != *block)
               continue;
             if (call_address != 0)