diff --git a/Userland/Libraries/LibCore/System.cpp b/Userland/Libraries/LibCore/System.cpp index 93bc34a157..872bbab715 100644 --- a/Userland/Libraries/LibCore/System.cpp +++ b/Userland/Libraries/LibCore/System.cpp @@ -167,6 +167,12 @@ ErrorOr profiling_disable(pid_t pid) int rc = ::profiling_disable(pid); HANDLE_SYSCALL_RETURN_VALUE("profiling_disable", rc, {}); } + +ErrorOr profiling_free_buffer(pid_t pid) +{ + int rc = ::profiling_free_buffer(pid); + HANDLE_SYSCALL_RETURN_VALUE("profiling_free_buffer", rc, {}); +} #endif #ifndef AK_OS_BSD_GENERIC diff --git a/Userland/Libraries/LibCore/System.h b/Userland/Libraries/LibCore/System.h index 79801c112f..eb429eb1d3 100644 --- a/Userland/Libraries/LibCore/System.h +++ b/Userland/Libraries/LibCore/System.h @@ -45,6 +45,7 @@ ErrorOr ptrace(int request, pid_t tid, void* address, void* data); ErrorOr disown(pid_t pid); ErrorOr profiling_enable(pid_t, u64 event_mask); ErrorOr profiling_disable(pid_t); +ErrorOr profiling_free_buffer(pid_t); #endif #ifndef AK_OS_BSD_GENERIC