summaryrefslogtreecommitdiffstats
path: root/tapset/logging.stp
diff options
context:
space:
mode:
authorhunt <hunt>2005-09-04 09:40:46 +0000
committerhunt <hunt>2005-09-04 09:40:46 +0000
commit6c100036afcfa4d038f7a7af83bcbcb28f905d35 (patch)
treec5ca93e96ad425446c1e1be02f0ecf21509a8a6e /tapset/logging.stp
parente479d1f47a8d83737418674bb03f780220bc4ff4 (diff)
downloadsystemtap-steved-6c100036afcfa4d038f7a7af83bcbcb28f905d35.tar.gz
systemtap-steved-6c100036afcfa4d038f7a7af83bcbcb28f905d35.tar.xz
systemtap-steved-6c100036afcfa4d038f7a7af83bcbcb28f905d35.zip
2005-09-04 Martin Hunt <hunt@redhat.com>
* testsuite/buildok/context_test.stp: New test. * tapset/logging.stp (log): Call _stp_printf(). * stapfuncs.5.in: Add contextinfo funcs. * tapset/context.stp: Minor cleanup.
Diffstat (limited to 'tapset/logging.stp')
-rw-r--r--tapset/logging.stp8
1 files changed, 4 insertions, 4 deletions
diff --git a/tapset/logging.stp b/tapset/logging.stp
index eff7b555..e276aa3f 100644
--- a/tapset/logging.stp
+++ b/tapset/logging.stp
@@ -4,10 +4,10 @@ function print (msg:string) %{
_stp_print (THIS->msg);
%}
-// almost the same as print
-function log (msg) {
- print (msg . "\n")
-}
+// like print but with a newline
+function log (msg:string) %{
+ _stp_printf ("%s\n", THIS->msg);
+%}
function printk (msg:string) %{
printk (KERN_INFO "%s\n", THIS->msg);