- Fix WMC and mkhive warnings

- Fix the unitialized variable warning in freetype (done the same way in freetype trunk)
- Make CRT compile warning-free again, and re-remove allowwarnings=true
- Make libxml compile warning-free too


svn path=/trunk/; revision=38911
This commit is contained in:
Stefan Ginsberg 2009-01-18 20:42:13 +00:00
parent 39934ca5e2
commit 0d17246450
16 changed files with 33 additions and 21 deletions

View file

@ -1,6 +1,6 @@
<?xml version="1.0"?> <?xml version="1.0"?>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd"> <!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="freetype" type="kernelmodedll" entrypoint="0" baseaddress="${BASEADDRESS_FREETYPE}" installbase="system32" installname="freetype.dll" allowwarnings="true" crt="libcntpr"> <module name="freetype" type="kernelmodedll" entrypoint="0" baseaddress="${BASEADDRESS_FREETYPE}" installbase="system32" installname="freetype.dll" crt="libcntpr">
<importlibrary definition="freetype.def" /> <importlibrary definition="freetype.def" />
<include base="freetype">include</include> <include base="freetype">include</include>
<define name="_DISABLE_TIDENTS" /> <define name="_DISABLE_TIDENTS" />

View file

@ -197,7 +197,7 @@
FT_UInt glyph_index; FT_UInt glyph_index;
FT_Int best_point, best_y, best_first, best_last; FT_Int best_point, best_y, best_first, best_last;
FT_Vector* points; FT_Vector* points;
FT_Bool round; FT_Bool round = 0;
AF_LOG(( "'%c'", *p )); AF_LOG(( "'%c'", *p ));

View file

@ -3250,7 +3250,7 @@ xmlLoadCatalogs(const char *pathss) {
cur++; cur++;
path = xmlStrndup((const xmlChar *)paths, cur - paths); path = xmlStrndup((const xmlChar *)paths, cur - paths);
#ifdef _WIN32 #ifdef _WIN32
iLen = strlen(path); iLen = strlen((const char *)path);
for(i = 0; i < iLen; i++) { for(i = 0; i < iLen; i++) {
if(path[i] == '\\') { if(path[i] == '\\') {
path[i] = '/'; path[i] = '/';

View file

@ -1,6 +1,6 @@
<?xml version="1.0"?> <?xml version="1.0"?>
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd"> <!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
<module name="libxml2" type="staticlibrary" allowwarnings="true" crt="dll"> <module name="libxml2" type="staticlibrary" crt="dll">
<define name="HAVE_CONFIG_H" /> <define name="HAVE_CONFIG_H" />
<define name="WIN32" /> <define name="WIN32" />
<define name="_WINDOWS" /> <define name="_WINDOWS" />

View file

@ -78,11 +78,13 @@
#if defined(__MINGW32__) || defined(_WIN32_WCE) #if defined(__MINGW32__) || defined(_WIN32_WCE)
#ifndef _WINSOCKAPI_
#define _WINSOCKAPI_ #define _WINSOCKAPI_
#endif
#include <wsockcompat.h> #include <wsockcompat.h>
#include <winsock2.h> #include <winsock2.h>
#undef XML_SOCKLEN_T #undef XML_SOCKLEN_T
#define XML_SOCKLEN_T unsigned int #define XML_SOCKLEN_T int
#endif #endif
/** /**

View file

@ -75,11 +75,13 @@
#endif #endif
#if defined(__MINGW32__) || defined(_WIN32_WCE) #if defined(__MINGW32__) || defined(_WIN32_WCE)
#ifndef _WINSOCKAPI_
#define _WINSOCKAPI_ #define _WINSOCKAPI_
#endif
#include <wsockcompat.h> #include <wsockcompat.h>
#include <winsock2.h> #include <winsock2.h>
#undef XML_SOCKLEN_T #undef XML_SOCKLEN_T
#define XML_SOCKLEN_T unsigned int #define XML_SOCKLEN_T int
#endif #endif

View file

@ -453,7 +453,7 @@ __xmlGlobalInitMutexLock(void)
/* Swap it into the global_init_lock */ /* Swap it into the global_init_lock */
#ifdef InterlockedCompareExchangePointer #ifdef InterlockedCompareExchangePointer
InterlockedCompareExchangePointer(&global_init_lock, cs, NULL); (void)InterlockedCompareExchangePointer(&global_init_lock, cs, NULL);
#else /* Use older void* version */ #else /* Use older void* version */
InterlockedCompareExchange((void **) &global_init_lock, InterlockedCompareExchange((void **) &global_init_lock,
(void *) cs, NULL); (void *) cs, NULL);
@ -936,7 +936,7 @@ xmlOnceInit(void)
#if defined(HAVE_WIN32_THREADS) #if defined(HAVE_WIN32_THREADS)
if (!run_once.done) { if (!run_once.done) {
if (InterlockedIncrement(&run_once.control) == 1) { if (InterlockedIncrement((PLONG)&run_once.control) == 1) {
#if !defined(HAVE_COMPILER_TLS) #if !defined(HAVE_COMPILER_TLS)
globalkey = TlsAlloc(); globalkey = TlsAlloc();
#endif #endif

View file

@ -58,6 +58,7 @@
# endif # endif
#endif #endif
/* Small ReactOS hack */ /* Small ReactOS hack */
#undef fpclassify
#define fpclassify _fpclass #define fpclassify _fpclass
#include <assert.h> #include <assert.h>
@ -213,6 +214,7 @@ TRIO_ARGS2((number, has_mantissa),
return is_special_quantity; return is_special_quantity;
} }
#if 0
/* /*
* trio_is_negative * trio_is_negative
*/ */
@ -230,6 +232,7 @@ TRIO_ARGS1((number),
} }
return is_negative; return is_negative;
} }
#endif
#endif /* USE_IEEE_754 */ #endif /* USE_IEEE_754 */

View file

@ -2453,7 +2453,6 @@ xmlCanonicPath(const xmlChar *path)
*/ */
#if defined(_WIN32) && !defined(__CYGWIN__) #if defined(_WIN32) && !defined(__CYGWIN__)
int len = 0; int len = 0;
int i = 0;
xmlChar *p = NULL; xmlChar *p = NULL;
#endif #endif
xmlURIPtr uri; xmlURIPtr uri;
@ -2522,7 +2521,7 @@ path_processing:
len = xmlStrlen(path); len = xmlStrlen(path);
if ((len > 2) && IS_WINDOWS_PATH(path)) { if ((len > 2) && IS_WINDOWS_PATH(path)) {
/* make the scheme 'file' */ /* make the scheme 'file' */
uri->scheme = xmlStrdup(BAD_CAST "file"); uri->scheme = (char*)xmlStrdup(BAD_CAST "file");
/* allocate space for leading '/' + path + string terminator */ /* allocate space for leading '/' + path + string terminator */
uri->path = xmlMallocAtomic(len + 2); uri->path = xmlMallocAtomic(len + 2);
if (uri->path == NULL) { if (uri->path == NULL) {
@ -2531,15 +2530,15 @@ path_processing:
} }
/* Put in leading '/' plus path */ /* Put in leading '/' plus path */
uri->path[0] = '/'; uri->path[0] = '/';
p = uri->path + 1; p = (xmlChar *)uri->path + 1;
strncpy(p, path, len + 1); strncpy((char *)p, (const char *)path, len + 1);
} else { } else {
uri->path = xmlStrdup(path); uri->path = (char*)xmlStrdup(path);
if (uri->path == NULL) { if (uri->path == NULL) {
xmlFreeURI(uri); xmlFreeURI(uri);
return(NULL); return(NULL);
} }
p = uri->path; p = (xmlChar *)uri->path;
} }
/* Now change all occurences of '\' to '/' */ /* Now change all occurences of '\' to '/' */
while (*p != '\0') { while (*p != '\0') {

View file

@ -15,7 +15,7 @@
</directory> </directory>
</module> </module>
<module name="crt" type="staticlibrary" allowwarnings="true"> <module name="crt" type="staticlibrary">
<library>chkstk</library> <library>chkstk</library>
<include base="crt">.</include> <include base="crt">.</include>
<include base="crt">include</include> <include base="crt">include</include>

View file

@ -105,6 +105,7 @@ static void dump_exception_type( const cxx_exception_type *type )
static void dump_function_descr( const cxx_function_descr *descr ) static void dump_function_descr( const cxx_function_descr *descr )
{ {
#ifndef WINE_NO_TRACE_MSGS
UINT i; UINT i;
int j; int j;
@ -122,6 +123,7 @@ static void dump_function_descr( const cxx_function_descr *descr )
descr->tryblock[i].start_level, descr->tryblock[i].end_level, descr->tryblock[i].start_level, descr->tryblock[i].end_level,
descr->tryblock[i].catch_level, descr->tryblock[i].catchblock, descr->tryblock[i].catch_level, descr->tryblock[i].catchblock,
descr->tryblock[i].catchblock_count ); descr->tryblock[i].catchblock_count );
for (j = 0; j < descr->tryblock[i].catchblock_count; j++) for (j = 0; j < descr->tryblock[i].catchblock_count; j++)
{ {
const catchblock_info *ptr = &descr->tryblock[i].catchblock[j]; const catchblock_info *ptr = &descr->tryblock[i].catchblock[j];
@ -130,6 +132,7 @@ static void dump_function_descr( const cxx_function_descr *descr )
ptr->type_info, dbgstr_type_info( ptr->type_info ) ); ptr->type_info, dbgstr_type_info( ptr->type_info ) );
} }
} }
#endif
} }
/* check if the exception type is caught by a given catch block, and return the type that matched */ /* check if the exception type is caught by a given catch block, and return the type that matched */

View file

@ -241,8 +241,6 @@ CmiAddSubKey(
HSTORAGE_TYPE Storage; HSTORAGE_TYPE Storage;
ULONG i; ULONG i;
DPRINT("CmiAddSubKey(%p '%wZ')\n", RegistryHive, SubKeyName);
VERIFY_KEY_CELL(ParentKeyCell); VERIFY_KEY_CELL(ParentKeyCell);
/* Skip leading backslash */ /* Skip leading backslash */
@ -523,8 +521,6 @@ CmiScanForSubKey(
VERIFY_KEY_CELL(KeyCell); VERIFY_KEY_CELL(KeyCell);
DPRINT("CmiScanForSubKey('%wZ')\n", SubKeyName);
ASSERT(RegistryHive); ASSERT(RegistryHive);
*pSubKeyCell = NULL; *pSubKeyCell = NULL;

View file

@ -1,6 +1,6 @@
<?xml version="1.0"?> <?xml version="1.0"?>
<!DOCTYPE module SYSTEM "../../tools/rbuild/project.dtd"> <!DOCTYPE module SYSTEM "../../tools/rbuild/project.dtd">
<module name="mkhive" type="buildtool" allowwarnings="true"> <module name="mkhive" type="buildtool">
<include base="inflibhost">.</include> <include base="inflibhost">.</include>
<include base="cmlibhost">.</include> <include base="cmlibhost">.</include>
<include base="zlibhost">.</include> <include base="zlibhost">.</include>

View file

@ -7,6 +7,12 @@
#include <stdlib.h> #include <stdlib.h>
#include <stdarg.h> #include <stdarg.h>
/* gcc defaults to cdecl */
#if defined(__GNUC__)
#undef __cdecl
#define __cdecl
#endif
#include "mkhive.h" #include "mkhive.h"
#include <bitmap.c> #include <bitmap.c>

View file

@ -1,6 +1,6 @@
<?xml version="1.0"?> <?xml version="1.0"?>
<!DOCTYPE module SYSTEM "../../tools/rbuild/project.dtd"> <!DOCTYPE module SYSTEM "../../tools/rbuild/project.dtd">
<module name="wmc" type="buildtool" allowwarnings="true"> <module name="wmc" type="buildtool">
<define name="WINE_UNICODE_API">" "</define> <define name="WINE_UNICODE_API">" "</define>
<include base="unicode">.</include> <include base="unicode">.</include>
<library>unicode</library> <library>unicode</library>

View file

@ -22,6 +22,7 @@
#define __WMC_WMCTYPES_H #define __WMC_WMCTYPES_H
#include <stdarg.h> #include <stdarg.h>
#include <string.h>
#include <host/typedefs.h> #include <host/typedefs.h>
/* Byteordering defines */ /* Byteordering defines */