<event name=block_end>
<description>Block end timestamp</description>
- <field name="timestamp"><typeref name=timestamp/></field>
- <field name="block_id"><uint size=4/></field>
+ <struct>
+ <field name="timestamp"><typeref name=timestamp/></field>
+ <field name="block_id"><uint size=4/></field>
+ </struct>
</event>
<type name=timestamp>
* hasStrSeq : string or sequence present?
* structCount : struct postfix
****************************************************************************/
+
static void
printStruct(FILE * fp, int len, void ** array, char * name, char * facName,
int * whichTypeFirst, int * hasStrSeq, int * structCount)
fld = (field *)array[pos];
td = fld->type;
if( td->type != STRING && td->type != SEQUENCE &&
- td->type != ARRAY) {
+ td->type != ARRAY) {
if (*whichTypeFirst == 0) {
*whichTypeFirst = 1; //struct first
}
if (flag == 0) {
flag = 1;
- fprintf(fp,"struct %s_%s",
- name, facName);
- if (structCount) {
- fprintf(fp, "_%d {\n",
- ++*structCount);
- } else {
- fprintf(fp, " {\n");
- }
+ fprintf(fp,"struct %s_%s",name, facName);
+ if (structCount) {
+ fprintf(fp, "_%d {\n",++*structCount);
+ } else {
+ fprintf(fp, " {\n");
+ }
}
- fprintf(fp, "\t%s %s; /* %s */\n",
- getTypeStr(td),fld->name,fld->description );
+ fprintf(fp, "\t%s %s; /* %s */\n",
+ getTypeStr(td),fld->name,fld->description );
} else {
- if (*whichTypeFirst == 0) {
+ if (*whichTypeFirst == 0) {
//string or sequence or array first
- *whichTypeFirst = 2;
- }
- (*hasStrSeq)++;
- if(flag) {
- fprintf(fp,"} __attribute__ ((packed));\n\n");
- }
- flag = 0;
+ *whichTypeFirst = 2;
+ }
+ (*hasStrSeq)++;
+ if(flag) {
+ fprintf(fp,"} __attribute__ ((packed));\n\n");
+ }
+ flag = 0;
}
}
<facility name=ipc>
<description>The ipc facility contains events related to Inter Process Communication</description>
-
+
<event name=call>
- <descriptiona>IPC call</description>
+
+ <description>IPC call</description>
<struct>
<field name="call_number"> <description>Number of IPC call</description> <uint size=4/> </field>
+
<field name="first"> <description>First argument</description> <int size=4/> </field>
</struct>
</event>
-
<event name=msg_create>
<description>Get an IPC message queue identifier</description>
<struct>
getRAnglebracket(in); //<type name=type_name>
getLAnglebracket(in); //<struct>
token = getName(in);
- if(strcmp("struct",token))in->error(in,"not a valid type definition");
+ //MD ??if(strcmp("struct",token))in->error(in,"not a valid type definition");
ungetToken(in);
parseType(in,t, unnamed_types, named_types);
<description>An interval timer is set.</description>
<struct>
<field name="which"> <description>kind of interval timer.</description>
- <typeref name=itimer_kind>
+ <typeref name=itimer_kind/>
</field>
<field name="interval"> <description>timer interval.</description>
- <typeref name=timeval>
+ <typeref name=timeval/>
</field>
<field name="value"> <description>current value.</description>
- <typeref name=timeval>
+ <typeref name=timeval/>
</field>
</struct>
</event>