/* construct directed acyclic graph for types, and tree for fields */
void construct_fields(LttFacility *fac,
/* construct directed acyclic graph for types, and tree for fields */
void construct_fields(LttFacility *fac,
- if(g_ascii_strcasecmp(token, "<")) in.error(&in,"not a facility file");
- token = getName(&in);
- if(g_ascii_strcasecmp(token, "?")) in.error(&in,"not a facility file");
- token = getName(&in);
- if(g_ascii_strcasecmp(token, "xml")) in.error(&in,"not a facility file");
- token = getName(&in);
- if(g_ascii_strcasecmp(token, "version")) in.error(&in,"not a facility file");
- token = getName(&in);
- if(g_ascii_strcasecmp(token, "=")) in.error(&in,"not a facility file");
- token = getQuotedString(&in);
- if(g_ascii_strcasecmp(token, "1.0")) in.error(&in,"not a facility file");
- token = getName(&in);
- if(g_ascii_strcasecmp(token, "?")) in.error(&in,"not a facility file");
- token = getToken(&in);
- if(g_ascii_strcasecmp(token, ">")) in.error(&in,"not a facility file");
-
- token = getToken(&in);
-
+ if(g_ascii_strcasecmp(token, "<")) in.error(&in,"not a facility file");
+ token = getName(&in);
+ if(g_ascii_strcasecmp(token, "?")) in.error(&in,"not a facility file");
+ token = getName(&in);
+ if(g_ascii_strcasecmp(token, "xml")) in.error(&in,"not a facility file");
+ token = getName(&in);
+ if(g_ascii_strcasecmp(token, "version")) in.error(&in,"not a facility file");
+ token = getName(&in);
+ if(g_ascii_strcasecmp(token, "=")) in.error(&in,"not a facility file");
+ token = getQuotedString(&in);
+ if(g_ascii_strcasecmp(token, "1.0")) in.error(&in,"not a facility file");
+ token = getName(&in);
+ if(g_ascii_strcasecmp(token, "?")) in.error(&in,"not a facility file");
+ token = getToken(&in);
+ if(g_ascii_strcasecmp(token, ">")) in.error(&in,"not a facility file");
+
+ token = getToken(&in);
+
checkNamedTypesImplemented(&fac->named_types);
generateChecksum(fac->name, &checksum, &fac->events);
checkNamedTypesImplemented(&fac->named_types);
generateChecksum(fac->name, &checksum, &fac->events);
+ //}
+ if (checksum != f->checksum)
+ g_warning("Facility checksum mismatch for facility %s : kernel 0x%X vs "
+ "XML 0x%X\n", fac->name, f->checksum, checksum);
/* The second day, he created the event fields and types */
//for each event, construct field and type acyclic graph
for(i=0;i<events->position;i++){
/* The second day, he created the event fields and types */
//for each event, construct field and type acyclic graph
for(i=0;i<events->position;i++){
event_type->fields = g_array_sized_new(FALSE, TRUE,
sizeof(LttField), parser_event->fields.position);
event_type->fields =
event_type->fields = g_array_sized_new(FALSE, TRUE,
sizeof(LttField), parser_event->fields.position);
event_type->fields =
fld->child[i] = g_new(LttField,1);
// fld->child[i]->field_pos = i;
fld->child[i]->field_type = fld->field_type->element_type[i];
fld->child[i]->field_type->element_name
fld->child[i] = g_new(LttField,1);
// fld->child[i]->field_pos = i;
fld->child[i]->field_type = fld->field_type->element_type[i];
fld->child[i]->field_type->element_name
fld->child[i] = g_new(LttField,1);
fld->child[i]->field_pos = i;
fld->child[i]->field_type = fld->field_type->element_type[i];
if(flag){
fld->child[i] = g_new(LttField,1);
fld->child[i]->field_pos = i;
fld->child[i]->field_type = fld->field_type->element_type[i];
if(flag){
- fld->child[i]->field_type->element_name
- = g_quark_from_string(((type_fields*)(td->fields.array[i]))->name);
+ fld->child[i]->field_type->element_name
+ = g_quark_from_string(((type_fields*)(td->fields.array[i]))->name);