From 6dc8ec89ef71425af52a57f3ebbaadc9f77931ca Mon Sep 17 00:00:00 2001 From: Max dml <maxdemoulin@gmail.com> Date: Thu, 20 Dec 2018 23:07:44 -0500 Subject: [PATCH] fix exception message format in detach_kprobe_event() (#2089) fix exception message format in detach_kprobe_event() --- src/python/bcc/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/python/bcc/__init__.py b/src/python/bcc/__init__.py index 4eb78025..5c7247a3 100644 --- a/src/python/bcc/__init__.py +++ b/src/python/bcc/__init__.py @@ -658,7 +658,7 @@ class BPF(object): def detach_kprobe_event(self, ev_name): if ev_name not in self.kprobe_fds: - raise Exception("Kprobe %s is not attached" % event) + raise Exception("Kprobe %s is not attached" % ev_name) res = lib.bpf_close_perf_event_fd(self.kprobe_fds[ev_name]) if res < 0: raise Exception("Failed to close kprobe FD") -- 2.30.9