view src/physfs-1-fix-gcc46-warnings.patch @ 2353:99516e73b368

Move doc/index.html -> index.html
author Volker Grabsch <vog@notjusthosting.com>
date Thu, 29 Mar 2012 12:14:15 +0200
parents f653602a0500
children
line wrap: on
line source

This file is part of MXE.
See index.html for further information.

This patch has been taken from:
http://icculus.org/pipermail/physfs/2011-March/000990.html

diff -ru physfs-2.0.2.orig/archivers/wad.c physfs-2.0.2/archivers/wad.c
--- physfs-2.0.2.orig/archivers/wad.c	2011-02-18 22:17:31.000000000 +0100
+++ physfs-2.0.2/archivers/wad.c	2011-03-27 14:55:10.000000000 +0200
@@ -245,9 +245,6 @@
     PHYSFS_uint32 fileCount;
     PHYSFS_uint32 directoryOffset;
     WADentry *entry;
-    char lastDirectory[9];
-
-    lastDirectory[8] = 0; /* Make sure lastDirectory stays null-terminated. */
 
     BAIL_IF_MACRO(!wad_open(name, forWriting, &fh, &fileCount,&directoryOffset), NULL, 0);
     info->entryCount = fileCount;
diff -ru physfs-2.0.2.orig/platform/windows.c physfs-2.0.2/platform/windows.c
--- physfs-2.0.2.orig/platform/windows.c	2011-02-18 22:17:31.000000000 +0100
+++ physfs-2.0.2/platform/windows.c	2011-03-27 14:54:17.000000000 +0200
@@ -462,6 +462,7 @@
              */	
     		rc = pGetUserProfileDirectoryW(accessToken, &dummy, &psize);
             assert(!rc);  /* !!! FIXME: handle this gracefully. */
+            (void)rc;
 
             /* Allocate memory for the profile directory */
             wstr = (LPWSTR) __PHYSFS_smallAlloc(psize * sizeof (WCHAR));