This is our old Q&A Site. Please post any new questions and answers at


I am writing a dissector in C and I donwloaded the last version of the source from svn. I want to use the proto_tree_append_text to add a label to an item. My compiler said that this function is not defined. This are are my include at the begin of my c file:

# include "config.h"


#include <stdio.h>
#include <glib.h>
#include <epan/packet.h>
#include <epan/emem.h>
#include <epan/dissectors/packet-tcp.h>
#include <epan/prefs.h>
#include <string.h>

Somebody can help me and tell what include I should add?

Thanks. Sandrine.

asked 17 Dec '10, 05:39

Sandrine%20Beauche's gravatar image

Sandrine Bea...
accept rate: 0%

The function to use would be proto_item_append_text and is declared in epan/proto.h:

/** Append to text of item after it has already been created.
 @param ti the item to append the text to
 @param format printf like format string
 @param ... printf like parameters */
extern void proto_item_append_text(proto_item *ti, const char *format, ...)

Hope this helps :-)

permanent link

answered 17 Dec '10, 07:17

SYN-bit's gravatar image

SYN-bit ♦♦
accept rate: 20%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text]( "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:


question asked: 17 Dec '10, 05:39

question was seen: 2,280 times

last updated: 17 Dec '10, 07:17

p​o​w​e​r​e​d by O​S​Q​A