Ethereal-dev: [Ethereal-dev] errors with epan/ipv5_utils.h

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

From: Ulf Lamping <ulf.lamping@xxxxxx>
Date: Mon, 12 Sep 2005 03:28:43 +0200
Hi List!

I'm (and the buildbot too) getting errors, probably caused by ipv6_utils.h:

capture_if_details_dlg.c
C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\ws2tcpip.h(57) : error C2143: Syntaxfehler : Fehlendes ';' vor '.' C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\ws2tcpip.h(57) : error C2059: Syntaxfehler : '.' C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\ws2tcpip.h(58) : error C2059: Syntaxfehler : '}' C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\ws2tcpip.h(64) : error C2079: 'sin6_addr' verwendet undefiniertes struct 'in_addr6'

In ipv6_utils.h I see the following code:

#ifdef s6_addr32
#undef s6_addr32
#endif

#ifdef s6_addr16
#undef s6_addr16
#endif

#ifdef s6_addr8
#undef s6_addr8
#endif

#ifdef s6_addr
#undef s6_addr
#endif

I would think this is an ugly hack which sooner or later will lead to more trouble!

Why not use a prefix like e_ in this and the files using it and get rid of the cause of the problem.

Otherwise we'll end up in having an ugly header file dependency problem ...

Regards, ULFL