mirror of
https://github.com/varun-r-mallya/sysprof.git
synced 2026-02-12 08:00:53 +00:00
libsysprof: add helper to get process info array
This commit is contained in:
@ -551,3 +551,18 @@ sysprof_helpers_authorize_finish (SysprofHelpers *self,
|
|||||||
|
|
||||||
return g_task_propagate_boolean (G_TASK (result), error);
|
return g_task_propagate_boolean (G_TASK (result), error);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
gboolean
|
||||||
|
sysprof_helpers_get_process_info (SysprofHelpers *self,
|
||||||
|
const gchar *attributes,
|
||||||
|
GCancellable *cancellable,
|
||||||
|
GVariant **info,
|
||||||
|
GError **error)
|
||||||
|
{
|
||||||
|
g_assert (SYSPROF_IS_HELPERS (self));
|
||||||
|
g_assert (attributes != NULL);
|
||||||
|
g_assert (!cancellable || G_IS_CANCELLABLE (cancellable));
|
||||||
|
g_assert (info != NULL);
|
||||||
|
|
||||||
|
return ipc_service_call_get_process_info_sync (self->proxy, attributes, info, cancellable, error);
|
||||||
|
}
|
||||||
|
|||||||
@ -68,6 +68,11 @@ gboolean sysprof_helpers_get_proc_file_finish (SysprofHelpers
|
|||||||
GAsyncResult *result,
|
GAsyncResult *result,
|
||||||
gchar **contents,
|
gchar **contents,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
gboolean sysprof_helpers_get_process_info (SysprofHelpers *self,
|
||||||
|
const gchar *attributes,
|
||||||
|
GCancellable *cancellable,
|
||||||
|
GVariant **info,
|
||||||
|
GError **error);
|
||||||
#ifdef __linux__
|
#ifdef __linux__
|
||||||
gboolean sysprof_helpers_perf_event_open (SysprofHelpers *self,
|
gboolean sysprof_helpers_perf_event_open (SysprofHelpers *self,
|
||||||
struct perf_event_attr *attr,
|
struct perf_event_attr *attr,
|
||||||
|
|||||||
Reference in New Issue
Block a user