Fixed some indents in program listings.
svn path=/trunk/; revision=26830
This commit is contained in:
parent
6aa7d26c2c
commit
48cced98a6
|
@ -317,11 +317,9 @@ static gint *ett[] = {
|
|||
</para>
|
||||
<example><title>Dissector data structure globals.</title>
|
||||
<programlisting>
|
||||
<![CDATA[
|
||||
static int hf_foo_pdu_type = -1;
|
||||
<![CDATA[static int hf_foo_pdu_type = -1;
|
||||
|
||||
static gint ett_foo = -1;
|
||||
]]>
|
||||
static gint ett_foo = -1;]]>
|
||||
</programlisting></example>
|
||||
<para>
|
||||
Now we can enhance the protocol display with some detail.
|
||||
|
@ -547,7 +545,9 @@ dissect_foo(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
val_to_str(packet_type, packettypenames, "Unknown (0x%02x)"));
|
||||
foo_tree = proto_item_add_subtree(ti, ett_foo);
|
||||
proto_tree_add_item(foo_tree, hf_foo_pdu_type, tvb, offset, 1, FALSE);
|
||||
offset += 1;]]>
|
||||
offset += 1;
|
||||
}
|
||||
}]]>
|
||||
</programlisting></example>
|
||||
<para>
|
||||
So here, after grabbing the value of the first 8 bits, we use it with one of the
|
||||
|
|
Loading…
Reference in New Issue