From edce5b6764d5a4fe742b1a9cc44fc2fe146b44c7 Mon Sep 17 00:00:00 2001 From: Josh Stone Date: Tue, 21 Jul 2009 19:21:56 -0700 Subject: Use the query paradigm for resolving sdt probes There was a bad assumption in the probe_table initialization that the dwflpp->module would be immediately valid. We should not assume that dwflpp only has one module, or that any module is necessarily in focus. Instead, I've created an sdt_query class which will call an iterate_over_modules like the other dwarf probe types. For now this means just a single module, but it will also open the door to iterating over all linked libraries too, for example. * dwflpp.cxx (dwflpp::setup_user): don't "save mod!" anymore * tapsets.cxx (probe_table -> sdt_query): convert to a query-style class, and also take over the task of iterating over the probes. (dwarf_builder::build): leave the iteration to sdt_query --- dwflpp.cxx | 2 -- 1 file changed, 2 deletions(-) (limited to 'dwflpp.cxx') diff --git a/dwflpp.cxx b/dwflpp.cxx index 1951b071..5fec20e2 100644 --- a/dwflpp.cxx +++ b/dwflpp.cxx @@ -417,8 +417,6 @@ dwflpp::setup_user(const vector& modules, bool debuginfo_needed) module_name.c_str(), module_name.c_str(), -1); - // XXX: save mod! - module = mod; if (debuginfo_needed) dwfl_assert (string("missing process ") + -- cgit