update
[lttv.git] / ltt / branches / poly / lttv / modules / text / textDump.c
index dbb8ec0fbcf1d09c7e21f38b4cd2d4c4631199c6..2cd60264aa15d1c9263a018433dbee713507a875 100644 (file)
@@ -70,10 +70,15 @@ print_tree(FILE *fp, GString *indent, LttvAttribute *tree)
 
   LttvAttributeType type;
 
+       gboolean is_named;
+
   nb = lttv_attribute_get_number(tree);
   for(i = 0 ; i < nb ; i++) {
-    type = lttv_attribute_get(tree, i, &name, &value);
-    fprintf(fp, "%s%s: ", indent->str, g_quark_to_string(name));
+    type = lttv_attribute_get(tree, i, &name, &value, &is_named);
+               if(is_named)
+           fprintf(fp, "%s%s: ", indent->str, g_quark_to_string(name));
+               else
+           fprintf(fp, "%s%lu: ", indent->str, name);
 
     switch(type) {
       case LTTV_INT:
@@ -109,7 +114,7 @@ print_tree(FILE *fp, GString *indent, LttvAttribute *tree)
           fprintf(fp, "\n");
           subtree = (LttvAttribute *)*(value.v_gobject);
           saved_length = indent->len; 
-          g_string_append(indent, "  ");
+          indent = g_string_append(indent, "  ");
           print_tree(fp, indent, subtree);
           g_string_truncate(indent, saved_length);
         }
@@ -154,7 +159,7 @@ print_stats(FILE *fp, LttvTracesetStats *tscs)
       start_time.tv_nsec);
 #endif //FIXME
     saved_length = indent->len;
-    g_string_append(indent, "  ");
+    indent = g_string_append(indent, "  ");
     print_tree(fp, indent, tcs->stats);
     g_string_truncate(indent, saved_length);
   }
@@ -236,7 +241,7 @@ static int write_event_content(void *hook_data, void *call_data)
 
   LttvFilter *filter;
 
-  guint cpu = ltt_tracefile_num(tfs->parent.tf);
+  guint cpu = tfs->cpu;
   LttvTraceState *ts = (LttvTraceState*)tfc->t_context;
   LttvProcessState *process = ts->running_process[cpu];
 
This page took 0.023544 seconds and 4 git commands to generate.