mirror of
https://github.com/varun-r-mallya/Python-BPF.git
synced 2025-12-31 21:06:25 +00:00
Comment out non string based decorator to decide later and also make
changes to decorator adding a "section"
This commit is contained in:
@ -1,11 +1,13 @@
|
||||
from pythonbpf.decorators import tracepoint, syscalls
|
||||
from pythonbpf.decorators import section
|
||||
# from pythonbpf.decorators import tracepoint, syscalls
|
||||
from ctypes import c_void_p, c_int32
|
||||
|
||||
#This is a test function
|
||||
def test_function():
|
||||
print("test_function called")
|
||||
|
||||
@tracepoint(syscalls.sys_enter_execve)
|
||||
# @tracepoint(syscalls.sys_enter_execve)
|
||||
@section("tracepoint/syscalls/sys_enter_execve")
|
||||
def trace_execve(ctx: c_void_p) -> c_int32:
|
||||
print("execve called")
|
||||
print("execve2 called")
|
||||
|
||||
Reference in New Issue
Block a user