From 775c802cdfbe80d65674b78b00f0c8fcfb012dfb Mon Sep 17 00:00:00 2001 From: compudj Date: Wed, 10 Oct 2007 18:43:19 +0000 Subject: [PATCH] start fixing the f1 f2 f3 refs git-svn-id: http://ltt.polymtl.ca/svn@2626 04897980-b3bd-0310-b5e0-8ef037075253 --- ltt/branches/poly/lttv/lttv/state.c | 2 +- ltt/branches/poly/lttv/lttv/tracecontext.h | 10 ++++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ltt/branches/poly/lttv/lttv/state.c b/ltt/branches/poly/lttv/lttv/state.c index 9450d8bc..a4532f57 100644 --- a/ltt/branches/poly/lttv/lttv/state.c +++ b/ltt/branches/poly/lttv/lttv/state.c @@ -2150,7 +2150,7 @@ static gboolean syscall_entry(void *hook_data, void *call_data) LttvProcessState *process = ts->running_process[cpu]; LttEvent *e = ltt_tracefile_get_event(s->parent.tf); LttvTraceHook *th = (LttvTraceHook *)hook_data; - struct marker_field *f = th->f1; + struct marker_field *f = lttv_trace_get_hook_field(th, 0); LttvExecutionSubmode submode; diff --git a/ltt/branches/poly/lttv/lttv/tracecontext.h b/ltt/branches/poly/lttv/lttv/tracecontext.h index 873aa61f..a99d3eb6 100644 --- a/ltt/branches/poly/lttv/lttv/tracecontext.h +++ b/ltt/branches/poly/lttv/lttv/tracecontext.h @@ -279,8 +279,6 @@ typedef struct _LttvTraceHook { gpointer hook_data; } LttvTraceHook; -#define FIELD_ARRAY(val...) ((GQuark[]){ val, 0 }) - /* Get the head of marker list correcponding to the given trace hook. */ struct marker_info *lttv_trace_hook_get_marker(LttTrace *t, LttvTraceHook *th); @@ -303,6 +301,13 @@ void lttv_trace_hook_remove_all(GArray **th); int lttv_trace_find_hook(LttTrace *t, GQuark marker_name, GQuark fields[], LttvHook h, gpointer hook_data, GArray **trace_hooks); +static inline struct marker_field * +lttv_trace_get_hook_field(LttvTraceHook *hook, unsigned int index) +{ + return g_ptr_array_index(hook->fields, index); +} + + LttvTracefileContext *lttv_traceset_context_get_current_tfc( LttvTracesetContext *self); @@ -369,5 +374,6 @@ guint lttv_process_traceset_seek_n_backward(LttvTracesetContext *self, LttvFilter *filter3, gpointer data); +#define FIELD_ARRAY(val...) ((GQuark[]){ val, 0 }) #endif // PROCESSTRACE_H -- 2.34.1