Ethereal-dev: [Ethereal-dev] value_string - compile error

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Charlie Duke <cduke@xxxxxxx>
Date: Tue, 5 Feb 2002 10:24:35 -0500
Hi,

When compiling a plugin written in C++ using VC++ 6.0 sp5 on Windows 2000, I
came across the following compile error:

"error C2371: 'value_string' : redefinition;  different basic types".

value_string was defined in <epan/value_string.h> as:

	typedef struct _value_string {
      ...
	} value_string;

Then it is later forward declared in <epan/proto.h> as:

	struct value_string;

The problem can be fixed by changing the definition in value_string.h to:

	typedef struct value_string {
                     ^ without the leading '_'
      ...
      } value_string;


---
Charlie Duke