summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrank Ch. Eigler <fche@elastic.org>2008-05-17 10:02:19 -0400
committerFrank Ch. Eigler <fche@elastic.org>2008-05-17 10:02:19 -0400
commit277f2b79b02bf69a1d72d05b06086b07bcc6a113 (patch)
treed96cec44852ecd259370ec0a06ac668676aacf71
parent2171f774be4c06664c5d2a0c1b8ef1f8b870ffdb (diff)
downloadsystemtap-steved-277f2b79b02bf69a1d72d05b06086b07bcc6a113.tar.gz
systemtap-steved-277f2b79b02bf69a1d72d05b06086b07bcc6a113.tar.xz
systemtap-steved-277f2b79b02bf69a1d72d05b06086b07bcc6a113.zip
suppress "pass-2 failed" messages from "stap -l FOOBAR"; just produce empty output
-rw-r--r--ChangeLog6
-rw-r--r--elaborate.cxx9
-rw-r--r--main.cxx2
3 files changed, 10 insertions, 7 deletions
diff --git a/ChangeLog b/ChangeLog
index 139ae6ac..92aad43b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
2008-05-17 Frank Ch. Eigler <fche@elastic.org>
+ * elaborate.cxx (semantic_pass): Error on #probes=0, but not in
+ listing mode.
+ (semantic_pass_optimize[12]): Remove inappropriate check from here.
+
+2008-05-17 Frank Ch. Eigler <fche@elastic.org>
+
* tapsets.cxx (cu_function_cache_t): Switch to <ext/hash_map>s,
since these tables tend to get pretty big.
diff --git a/elaborate.cxx b/elaborate.cxx
index 0e454937..9a817cba 100644
--- a/elaborate.cxx
+++ b/elaborate.cxx
@@ -1159,6 +1159,9 @@ semantic_pass (systemtap_session& s)
if (rc == 0 && ! s.unoptimized) rc = semantic_pass_optimize2 (s);
if (rc == 0) rc = semantic_pass_vars (s);
if (rc == 0) rc = semantic_pass_stats (s);
+
+ if (s.probes.size() == 0 && !s.listing_mode)
+ throw semantic_error ("no probes found");
}
catch (const semantic_error& e)
{
@@ -2139,9 +2142,6 @@ semantic_pass_optimize1 (systemtap_session& s)
semantic_pass_opt4 (s, relaxed_p);
}
- if (s.probes.size() == 0)
- throw semantic_error ("no probes found");
-
return rc;
}
@@ -2164,9 +2164,6 @@ semantic_pass_optimize2 (systemtap_session& s)
semantic_pass_opt5 (s, relaxed_p);
}
- if (s.probes.size() == 0)
- throw semantic_error ("no probes found");
-
return rc;
}
diff --git a/main.cxx b/main.cxx
index eadbd694..b53499b7 100644
--- a/main.cxx
+++ b/main.cxx
@@ -242,7 +242,7 @@ printscript(systemtap_session& s, ostream& o)
}
}
}
- }
+}
int pending_interrupts;