build fix
authorcompudj <compudj@04897980-b3bd-0310-b5e0-8ef037075253>
Fri, 10 Oct 2008 20:42:36 +0000 (20:42 +0000)
committercompudj <compudj@04897980-b3bd-0310-b5e0-8ef037075253>
Fri, 10 Oct 2008 20:42:36 +0000 (20:42 +0000)
git-svn-id: http://ltt.polymtl.ca/svn@3088 04897980-b3bd-0310-b5e0-8ef037075253

trunk/lttv/ltt/event.h
trunk/lttv/ltt/tracefile.c

index d737a469b5a841be3759046a34192d48ec5998dd..31a49d36a7cbb56b922664c4e25f1c63b8045b10 100644 (file)
@@ -1,4 +1,4 @@
-
+#ifndef _LTT_EVENT_H
 #define _LTT_EVENT_H
 
 #include <glib.h>
index cb7d5e80ffd7bb29908c3683d443727bc14a819b..b4d20cc23d84beed08a03fdb2d87a77538567f9f 100644 (file)
@@ -165,7 +165,7 @@ static int parse_trace_header(void *header, LttTracefile *tf, LttTrace *t)
           (struct ltt_trace_header_2_0 *)header;
         tf->buffer_header_size =
          sizeof(struct ltt_block_start_header) 
-            + sizeof(struct ltt_trace_header_1_0);
+            + sizeof(struct ltt_trace_header_2_0);
         tf->tscbits = vheader->tscbits;
         tf->eventbits = vheader->eventbits;
         tf->tsc_mask = ((1ULL << tf->tscbits) - 1);
@@ -1256,7 +1256,7 @@ int ltt_tracefile_read_update_event(LttTracefile *tf)
   
   event->timestamp = ltt_get_uint32(LTT_GET_BO(tf), pos);
   event->event_id = event->timestamp >> tf->tscbits;
-  event->timestamp = event->timestamp & tsc_mask;
+  event->timestamp = event->timestamp & tf->tsc_mask;
   pos += sizeof(guint32);
 
   switch (event->event_id) {
@@ -1495,7 +1495,7 @@ void ltt_update_event_size(LttTracefile *tf)
    */
   if (likely(info && info->fields)) {
     /* alignment */
-    event->data += ltt_align((off_t)event->data, info->largest_align,
+    tf->event.data += ltt_align((off_t)tf->event.data, info->largest_align,
                              info->alignment);
     /* size, dynamically computed */
     if (info->size != -1)
This page took 0.027135 seconds and 4 git commands to generate.