From c432246e06bb83a3d43a6668517486fb6b4b959d Mon Sep 17 00:00:00 2001 From: dagenais Date: Thu, 7 Aug 2003 15:35:38 +0000 Subject: [PATCH] git-svn-id: http://ltt.polymtl.ca/svn@174 04897980-b3bd-0310-b5e0-8ef037075253 --- ltt/branches/poly/lttv/main.c | 2 ++ ltt/branches/poly/lttv/module.c | 2 +- ltt/branches/poly/lttv/state.c | 9 +++++---- ltt/branches/poly/lttv/textDump.c | 5 +++-- 4 files changed, 11 insertions(+), 7 deletions(-) diff --git a/ltt/branches/poly/lttv/main.c b/ltt/branches/poly/lttv/main.c index 1123af44..ec131915 100644 --- a/ltt/branches/poly/lttv/main.c +++ b/ltt/branches/poly/lttv/main.c @@ -101,7 +101,9 @@ int main(int argc, char **argv) { lttv_module_path_option, NULL); lttv_hooks_call(before_options, NULL); + lttv_option_parse(argc, argv); lttv_hooks_call(after_options, NULL); + lttv_hooks_call(before_main, NULL); lttv_hooks_call(after_main, NULL); diff --git a/ltt/branches/poly/lttv/module.c b/ltt/branches/poly/lttv/module.c index 0f6f5a07..e6012f76 100644 --- a/ltt/branches/poly/lttv/module.c +++ b/ltt/branches/poly/lttv/module.c @@ -118,7 +118,7 @@ module_load(const char *name, int argc, char **argv) if(!g_module_symbol(gm, "init", (gpointer)&init_function)) { g_warning("module %s (%s) has no init function", name, pathname); } - else init_Function(m, argc, argv); + else init_function(m, argc, argv); } else { diff --git a/ltt/branches/poly/lttv/state.c b/ltt/branches/poly/lttv/state.c index b60f22f2..2a9164ca 100644 --- a/ltt/branches/poly/lttv/state.c +++ b/ltt/branches/poly/lttv/state.c @@ -78,21 +78,21 @@ fini(LttvTracesetState *self) } -LttvTracesetContext * +static LttvTracesetContext * new_traceset_context(LttvTracesetContext *self) { return LTTV_TRACESET_CONTEXT(g_object_new(LTTV_TRACESET_STATE_TYPE, NULL)); } -LttvTraceContext * +static LttvTraceContext * new_trace_context(LttvTracesetContext *self) { return LTTV_TRACE_CONTEXT(g_object_new(LTTV_TRACE_STATE_TYPE, NULL)); } -LttvTracefileContext * +static LttvTracefileContext * new_tracefile_context(LttvTracesetContext *self) { return LTTV_TRACEFILE_CONTEXT(g_object_new(LTTV_TRACEFILE_STATE_TYPE, NULL)); @@ -272,6 +272,7 @@ static void push_state(LttvTracefileState *tfs, LttvInterruptType t, intr->n = state_id; intr->entry = intr->last_change = LTTV_TRACEFILE_CONTEXT(tfs)->timestamp; intr->s = process->state->s; + process->state = intr; } @@ -512,7 +513,7 @@ find_hook(LttTrace *t, char *facility, char *event, et = ltt_facility_eventtype_get_by_name(f, event); if(et == NULL) g_error("Event %s does not exist", event); - hook_id.id = *(ltt_eventtype_id(et)); /* CHECK */ + hook_id.id = ltt_eventtype_id(et); hook_id.h = h; hook_id.free_hook_data = FALSE; hook_data.f1 = find_field(et, field1); diff --git a/ltt/branches/poly/lttv/textDump.c b/ltt/branches/poly/lttv/textDump.c index e4c8d5c7..646cb081 100644 --- a/ltt/branches/poly/lttv/textDump.c +++ b/ltt/branches/poly/lttv/textDump.c @@ -79,9 +79,9 @@ void print_field(LttEvent *e, LttField *f, GString *s, gboolean field_names) { nb = ltt_type_member_number(type); for(i = 0 ; i < nb ; i++) { element = ltt_field_member(f,i); - if(name) { + if(field_names) { ltt_type_member_type(type, i, &name); - g_string_append_printf(s, " %s = ", field_names); + g_string_append_printf(s, " %s = ", name); } print_field(e, element, s, field_names); } @@ -115,6 +115,7 @@ void lttv_event_to_string(LttEvent *e, LttTracefile *tf, GString *s, g_string_append_printf(s,"%s.%s: %ld.%ld (%s)",ltt_facility_name(facility), ltt_eventtype_name(event_type), (long)time.tv_sec, time.tv_nsec, ltt_tracefile_name(tf)); + /* Print the process id and the state/interrupt type of the process */ } print_field(e, field, s, field_names); -- 2.34.1