Ethereal-dev: Re: [Ethereal-dev] bug in rtp_analysis.c?

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

From: Guy Harris <guy@xxxxxxxxxxxx>
Date: Thu, 30 Oct 2003 03:38:07 -0800
On Thu, Oct 30, 2003 at 12:00:07PM +0100, Lars Ruoff wrote:
> Sorry, cannot build from latest cvs snapshot (2003-10-30) on Win32 ...
> 
> packet-gsm_a.c(87) : error C2133: 'dtap_msg_rr_fcn' : unknown size

Another zero-length array definition.  I've checked in a fix.  Remove
the definition on line 87.

> util.c(185) : error C2065: 'OSVERSIONINFO' : undeclared identifier
> util.c(204) : error C2065: 'VER_PLATFORM_WIN32s' : undeclared identifier
> util.c(209) : error C2065: 'VER_PLATFORM_WIN32_WINDOWS' : undeclared
> identifier
> util.c(243) : error C2065: 'VER_PLATFORM_WIN32_NT' : undeclared identifier
> (follow-up errors left out)

That's odd.  "util.c" hasn't changed in a while, and I was able to
compile it in the past few days.

However, it doesn't include <windows.h>, so presumably it compiles for
me because some header such as <pcap.h> implicitly includes <windows.h>.

I'd throw in a <windows.h> include, but I'm a bit nervous that it'd drag
in <winsock.h> or whatever, and the usual Clash of the Titans between
the Winsock 1 and Winsock 2 headers might then occur as a result of
including <pcap.h>.

Try adding

	#ifdef HAVE_WINDOWS_H
	#include <windows.h>
	#endif

right after the

	#ifdef HAVE_SYS_STAT_H
	#include <sys/stat.h>
	#endif

stuff, and see if that works.