Merge pull request #83 from filnet/warnings
Fixed various compilation warnings on msys2
This commit is contained in:
commit
a236f18b17
@ -16,7 +16,7 @@
|
|||||||
* THE SOFTWARE.
|
* THE SOFTWARE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef WIN32
|
#if defined(WIN32) && !(defined(__CYGWIN__) || defined(__MINGW32__))
|
||||||
/////////////////////////////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////////////////////////////
|
||||||
// Disable unavoidable warning messages:
|
// Disable unavoidable warning messages:
|
||||||
|
|
||||||
|
@ -19,7 +19,9 @@
|
|||||||
#include <osgDB/FileUtils>
|
#include <osgDB/FileUtils>
|
||||||
|
|
||||||
#ifdef WIN32
|
#ifdef WIN32
|
||||||
|
#if !defined(__MINGW32__)
|
||||||
#define _WIN32_WINNT 0x0500
|
#define _WIN32_WINNT 0x0500
|
||||||
|
#endif
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -34,7 +34,10 @@ typedef char TCHAR;
|
|||||||
#include <direct.h> // for _mkdir
|
#include <direct.h> // for _mkdir
|
||||||
|
|
||||||
#define mkdir(x,y) _mkdir((x))
|
#define mkdir(x,y) _mkdir((x))
|
||||||
|
|
||||||
|
#if !defined(__MINGW32__)
|
||||||
#define stat64 _stati64
|
#define stat64 _stati64
|
||||||
|
#endif
|
||||||
|
|
||||||
// set up for windows so acts just like unix access().
|
// set up for windows so acts just like unix access().
|
||||||
#ifndef F_OK
|
#ifndef F_OK
|
||||||
|
@ -2989,7 +2989,7 @@ int unzlocal_getByte(LUFILE *fin,int *pi)
|
|||||||
int unzlocal_getShort (LUFILE *fin,uLong *pX)
|
int unzlocal_getShort (LUFILE *fin,uLong *pX)
|
||||||
{
|
{
|
||||||
uLong x ;
|
uLong x ;
|
||||||
int i;
|
int i = 0;
|
||||||
int err;
|
int err;
|
||||||
|
|
||||||
err = unzlocal_getByte(fin,&i);
|
err = unzlocal_getByte(fin,&i);
|
||||||
@ -3009,7 +3009,7 @@ int unzlocal_getShort (LUFILE *fin,uLong *pX)
|
|||||||
int unzlocal_getLong (LUFILE *fin,uLong *pX)
|
int unzlocal_getLong (LUFILE *fin,uLong *pX)
|
||||||
{
|
{
|
||||||
uLong x ;
|
uLong x ;
|
||||||
int i;
|
int i = 0;
|
||||||
int err;
|
int err;
|
||||||
|
|
||||||
err = unzlocal_getByte(fin,&i);
|
err = unzlocal_getByte(fin,&i);
|
||||||
|
@ -1674,9 +1674,9 @@ static int ChooseMatchingPixelFormat( HDC hdc, int screenNum, const WGLIntegerAt
|
|||||||
1, // version number
|
1, // version number
|
||||||
PFD_DRAW_TO_WINDOW | // support window
|
PFD_DRAW_TO_WINDOW | // support window
|
||||||
PFD_SUPPORT_OPENGL | // support OpenGL
|
PFD_SUPPORT_OPENGL | // support OpenGL
|
||||||
DWORD(_traits->doubleBuffer ? PFD_DOUBLEBUFFER : NULL) | // double buffered ?
|
DWORD(_traits->doubleBuffer ? PFD_DOUBLEBUFFER : 0) | // double buffered ?
|
||||||
DWORD(_traits->swapMethod == osg::DisplaySettings::SWAP_COPY ? PFD_SWAP_COPY : NULL) |
|
DWORD(_traits->swapMethod == osg::DisplaySettings::SWAP_COPY ? PFD_SWAP_COPY : 0) |
|
||||||
DWORD(_traits->swapMethod == osg::DisplaySettings::SWAP_EXCHANGE ? PFD_SWAP_EXCHANGE : NULL),
|
DWORD(_traits->swapMethod == osg::DisplaySettings::SWAP_EXCHANGE ? PFD_SWAP_EXCHANGE : 0),
|
||||||
PFD_TYPE_RGBA, // RGBA type
|
PFD_TYPE_RGBA, // RGBA type
|
||||||
BYTE(_traits->red + _traits->green + _traits->blue), // color depth
|
BYTE(_traits->red + _traits->green + _traits->blue), // color depth
|
||||||
BYTE(_traits->red), 0, BYTE(_traits->green), 0, BYTE(_traits->blue), 0, // shift bits ignored
|
BYTE(_traits->red), 0, BYTE(_traits->green), 0, BYTE(_traits->blue), 0, // shift bits ignored
|
||||||
|
Loading…
Reference in New Issue
Block a user