fix marker hash table
authorcompudj <compudj@04897980-b3bd-0310-b5e0-8ef037075253>
Wed, 29 Aug 2007 14:35:51 +0000 (14:35 +0000)
committercompudj <compudj@04897980-b3bd-0310-b5e0-8ef037075253>
Wed, 29 Aug 2007 14:35:51 +0000 (14:35 +0000)
git-svn-id: http://ltt.polymtl.ca/svn@2596 04897980-b3bd-0310-b5e0-8ef037075253

ltt/branches/poly/ltt/ltt-private.h
ltt/branches/poly/ltt/markers.c

index 8d862840d52579c01eb4f82f70d58838533499e1..68509eab78a22b2d3a78b55370b1cbd2034dd9cb 100644 (file)
@@ -219,6 +219,7 @@ struct _LttType{
   char *footer;
 };
 
+#if 0
 struct _LttEventType{
   GQuark name;
   gchar * description;
@@ -228,6 +229,7 @@ struct _LttEventType{
   GData *fields_by_name;
   int has_compact_data;       //event header contains compact data (first field)
 };
+#endif //0
 
 /* Structure LttEvent and LttEventPosition must begin with the _exact_ same
  * fields in the exact same order. LttEventPosition is a parent of LttEvent. */
index ec9ad5912290ea230505b0e719a5a4b417149f37..6be3822834b1e489dd32d52a3c8f7f19b2daac42 100644 (file)
@@ -414,8 +414,10 @@ int marker_id_event(LttTrace *trace, GQuark name, guint16 id,
   head = g_hash_table_lookup(trace->markers_hash, (gconstpointer)name);
   if (!head)
     g_hash_table_insert(trace->markers_hash, (gpointer)name, info);
-  else
-    head->next = info;
+  else {
+    g_hash_table_replace(trace->markers_hash, (gpointer)name, info);
+    info->next = head;
+  }
 }
 
 int allocate_marker_data(LttTrace *trace)
This page took 0.024443 seconds and 4 git commands to generate.