Wireshark mailing list archives
Re: Compiling Wireshark for Win32
From: Graham Bloice <graham.bloice () trihedral com>
Date: Wed, 10 Aug 2011 17:50:28 +0100
On 10/08/2011 17:18, news.gmane.com wrote:
Hello, I am a bit surprised about a problem with compiling Wireshark 1.6.0 with Visual Studio 2005 for Win32. Some dissectors have assignments from 64 to 32 bit, what will issue a warning C4244 by the compiler. Since the -WX parameter is passed to the compiler, the compilation fails. The warning level /W3 will not suppress the warning C4244 but /W2 would do. example: packet-afp.c function: dissect_spotlight line: 3999 toc_offset = (spotlight_ntoh64(tvb, offset) >> 32) * 8 - 8; where the variable is defines as gint toc_offset; Compiler output: packet-afp.c packet-afp.c(3999) : error C2220: warning treated as error - no 'object' file generated packet-afp.c(3999) : warning C4244: '=' : conversion from 'guint64' to 'gint', possible loss of data Why did this pass the compilation at wireshark.org? How do I recompile Wireshark 1.6.0? This affects also packet-ieee802154.c(2162) : warning C4244: 'return' : conversion from 'guint64' to 'guint', possible loss of data packet-netflow.c(2623) : warning C4244: '=' : conversion from 'guint64' to 'int', possible loss of data
In the trunk these all have appropriate casts so no warnings are issued. For example packet-afp.c was fixed by r37694 on 17th June 2011. -- Regards, Graham Bloice ___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev () wireshark org> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request () wireshark org?subject=unsubscribe
Current thread:
- Compiling Wireshark for Win32 news.gmane.com (Aug 10)
- Re: Compiling Wireshark for Win32 Graham Bloice (Aug 10)
- Re: Compiling Wireshark for Win32 Guy Harris (Aug 10)
- Re: Compiling Wireshark for Win32 Graham Bloice (Aug 10)
- Re: Compiling Wireshark for Win32 news.gmane.com (Aug 11)
- Re: Compiling Wireshark for Win32 Stig Bjørlykke (Aug 11)
- Re: Compiling Wireshark for Win32 news.gmane.com (Aug 11)
- Re: Compiling Wireshark for Win32 Alex Lindberg (Aug 11)
- Re: Compiling Wireshark for Win32 news.gmane.com (Aug 11)
- Re: Compiling Wireshark for Win32 Alex Lindberg (Aug 11)
- Re: Compiling Wireshark for Win32 Graham Bloice (Aug 11)
- Re: Compiling Wireshark for Win32 news.gmane.com (Aug 11)
- Re: Compiling Wireshark for Win32 Gerald Combs (Aug 11)