lttctl fix
[lttv.git] / ltt / branches / poly / ltt / tracefile.c
index fc02bfed119c167c573978b421b6ffceb68db0dd..b9ab0b71f2f5d79defa33b0c0e36f08f96ddbc29 100644 (file)
@@ -804,7 +804,7 @@ static int open_tracefiles(LttTrace *trace, gchar *root_path,
 
 /* ltt_get_facility_description
  *
- * Opens the trace corresponding to the requested facility (identified by fac_id
+ * Opens the file corresponding to the requested facility (identified by fac_id
  * and checksum).
  *
  * The name searched is : %trace root%/eventdefs/facname_checksum.xml
@@ -836,7 +836,7 @@ static int ltt_get_facility_description(LttFacility *f,
   textlen+=strlen(text);
   if(textlen >= PATH_MAX) goto name_error;
   strcat(desc_file_name, text);
-
+#if 0
   text = "_";
   textlen+=strlen(text);
   if(textlen >= PATH_MAX) goto name_error;
@@ -848,11 +848,12 @@ static int ltt_get_facility_description(LttFacility *f,
 
   textlen=strlen(desc_file_name);
   
+#endif //0
   text = ".xml";
   textlen+=strlen(text);
   if(textlen >= PATH_MAX) goto name_error;
   strcat(desc_file_name, text);
+
   err = ltt_facility_open(f, t, desc_file_name);
   if(err) goto facility_error;
 
@@ -1431,7 +1432,7 @@ int ltt_tracefile_seek_time(LttTracefile *tf, LttTime time)
         if(ret == ERANGE) goto range; /* ERANGE or EPERM */
         else if(ret) goto fail;
 
-        if(ltt_time_compare(time, tf->event.event_time) < 0)
+        if(ltt_time_compare(time, tf->event.event_time) <= 0)
           goto found;
       }
 
@@ -1448,7 +1449,7 @@ int ltt_tracefile_seek_time(LttTracefile *tf, LttTime time)
         if(ret == ERANGE) goto range; /* ERANGE or EPERM */
         else if(ret) goto fail;
 
-        if(ltt_time_compare(time, tf->event.event_time) < 0)
+        if(ltt_time_compare(time, tf->event.event_time) <= 0)
           break;
       }
       goto found;
This page took 0.030967 seconds and 4 git commands to generate.