int i,j;
LttFacility * f;
LttEventType * et;
+ char name[DIR_NAME_SIZE];
dir = opendir(eventdefs);
if(!dir) g_error("Can not open directory: %s\n", eventdefs);
while((entry = readdir(dir)) != NULL){
ptr = &entry->d_name[strlen(entry->d_name)-4];
if(strcmp(ptr,".xml") != 0) continue;
- ltt_facility_open(t,entry->d_name);
+ strcpy(name,eventdefs);
+ strcat(name,entry->d_name);
+ ltt_facility_open(t,name);
}
closedir(dir);
{
DIR * dir;
struct dirent *entry;
+ char name[DIR_NAME_SIZE];
dir = opendir(control);
if(!dir) g_error("Can not open directory: %s\n", control);
strcmp(entry->d_name,"interrupts") != 0 ||
strcmp(entry->d_name,"processes") != 0) continue;
- ltt_tracefile_open_control(t,entry->d_name);
+ strcpy(name,control);
+ strcat(name,entry->d_name);
+ ltt_tracefile_open_control(t,name);
}
closedir(dir);
}
{
DIR * dir;
struct dirent *entry;
+ char name[DIR_NAME_SIZE];
dir = opendir(cpu);
if(!dir) g_error("Can not open directory: %s\n", cpu);
while((entry = readdir(dir)) != NULL){
if(strcmp(entry->d_name,".") != 0 ||
strcmp(entry->d_name,"..") != 0 ){
- ltt_tracefile_open_cpu(t,entry->d_name);
+ strcpy(name,cpu);
+ strcat(name,entry->d_name);
+ ltt_tracefile_open_cpu(t,name);
}else continue;
}
closedir(dir);
}else if(err < 0){
err = t->which_block;
if(ltt_tracefile_read(t) == NULL){
- g_printf("End of file\n");
+ g_print("End of file\n");
return;
}
if(t->which_block == err)
err=readBlock(t,t->which_block+1);
if(err) g_error("Can not read tracefile: %s\n", t->name);
}else {
- g_printf("End of file\n");
+ g_print("End of file\n");
return;
}
if(tailTime < 0) return ltt_tracefile_seek_time(t, time);