- gcc 4.4.0 bringup 1 of ?:

- servman: Disable unused, static function
- explorer, mpu401: Fix "deprecated conversion from string constant to 'xxx'" under
- ws2_32_new, portcls: Hack around bogus uninitialized variable usage warning for
- glu32: Fix various warnings and errors

svn path=/trunk/; revision=42970
This commit is contained in:
Stefan Ginsberg 2009-08-30 15:53:16 +00:00
parent 07d6ee8ed5
commit b0f1241ccb
19 changed files with 50 additions and 20 deletions

View file

@ -50,6 +50,7 @@ AddItemToTreeView(HWND hTreeView,
return TreeView_InsertItem(hTreeView, &tvins);
}
#if 0
static VOID
AddServiceDependency(PSERVICEPROPSHEET dlgInfo,
HWND hTreeView,
@ -123,6 +124,7 @@ AddServiceDependency(PSERVICEPROPSHEET dlgInfo,
}
}
#endif
static VOID
AddServiceDependent(HWND hTreeView,

View file

@ -153,6 +153,11 @@ MainFrameBase::MainFrameBase(HWND hwnd)
: super(hwnd)
{
HDC hDC = GetDC(NULL);
#ifndef _NO_REBAR
//static WCHAR Title1[] = TEXT("Toolbar");
static WCHAR Title2[] = TEXT("Address :");
#endif
if (hDC)
{
DWORD ilMask;
@ -264,7 +269,7 @@ MainFrameBase::MainFrameBase(HWND hwnd)
rbBand.cyMaxChild = 0;
rbBand.cyIntegral = btn_hgt;
rbBand.lpText = NULL;//TEXT("Toolbar");
rbBand.lpText = NULL;//Title1
rbBand.hwndChild = _htoolbar;
rbBand.cxMinChild = 0;
rbBand.cyMinChild = btn_hgt;
@ -273,7 +278,7 @@ MainFrameBase::MainFrameBase(HWND hwnd)
rbBand.fStyle &= ~RBBS_HIDETITLE;
rbBand.fStyle |= RBBS_BREAK;
rbBand.lpText = TEXT("Address :");
rbBand.lpText = Title2;
rbBand.hwndChild = _haddrcombo;
rbBand.cxMinChild = 0;
rbBand.cyMinChild = btn_hgt;

View file

@ -42,7 +42,7 @@ enum IMAGE {
#define IMAGE_HEIGHT 13
static const LPTSTR g_pos_names[COLUMNS] = {
static const TCHAR* g_pos_names[COLUMNS] = {
TEXT(""), /* symbol */
TEXT("Name"),
TEXT("Type"),
@ -141,7 +141,7 @@ bool Pane::create_header(HWND hparent, int id)
hdi.mask = HDI_TEXT|HDI_WIDTH|HDI_FORMAT;
for(int idx=0; idx<COLUMNS; idx++) {
hdi.pszText = g_pos_names[idx];
hdi.pszText = (TCHAR*)g_pos_names[idx];
hdi.fmt = HDF_STRING | g_pos_align[idx];
hdi.cxy = _widths[idx];
Header_InsertItem(hwnd, idx, &hdi);

View file

@ -246,7 +246,7 @@ Backend::evalVStrip(int n_left, REAL u_left, REAL* left_val,
*-------------------------------------------------------------------------
*/
void
Backend::bgntmesh( char * )
Backend::bgntmesh( const char * )
{
#ifndef NOWIREFRAME

View file

@ -65,7 +65,7 @@ public:
void surfbbox( long, REAL *, REAL * );
void surfgrid( REAL, REAL, long, REAL, REAL, long );
void surfmesh( long, long, long, long );
void bgntmesh( char * );
void bgntmesh( const char * );
void endtmesh( void );
void swaptmesh( void );
void tmeshvert( GridTrimVertex * );

View file

@ -120,7 +120,7 @@ Bin::adopt()
*/
void
Bin::show( char *name )
Bin::show( const char *name )
{
#ifndef NDEBUG
dprintf( "%s\n", name );

View file

@ -63,7 +63,7 @@ public:
int numarcs( void );
void adopt( void );
void markall( void );
void show( char * );
void show( const char * );
void listBezier( void );
};

View file

@ -48,7 +48,7 @@
* Pool - allocate a new pool of buffers
*-----------------------------------------------------------------------------
*/
Pool::Pool( int _buffersize, int initpoolsize, char *n )
Pool::Pool( int _buffersize, int initpoolsize, const char *n )
{
buffersize= (_buffersize < (int)sizeof(Buffer)) ? sizeof(Buffer) : _buffersize;
initsize = initpoolsize * buffersize;

View file

@ -55,7 +55,7 @@ class Buffer {
class Pool {
public:
Pool( int, int, char * );
Pool( int, int, const char * );
~Pool( void );
inline void* new_buffer( void );
inline void free_buffer( void * );
@ -74,7 +74,7 @@ protected:
int nextfree; /* byte offset past next free buffer */
int initsize;
enum Magic { is_allocated = 0xf3a1, is_free = 0xf1a2 };
char *name; /* name of the pool */
const char *name; /* name of the pool */
Magic magic; /* marker for valid pool */
};

View file

@ -179,6 +179,13 @@ Subdivider::arc_split( Arc_ptr jarc, int param, REAL value, int dir )
TrimVertex* v = jarc->pwlArc->pts;
int loc[3];
#if defined(__GNUC__) && \
(__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__ == 40400)
/* Silence incorrect GCC 4.4.0 warnings */
loc[0] = loc[1] = loc[2] = 0;
#endif
switch( pwlarc_intersect( jarc->pwlArc, param, value, dir, loc ) ) {
// When the parameter value lands on a vertex, life is sweet

View file

@ -126,7 +126,7 @@ int Knotvector::validate( void )
return 0;
}
void Knotvector::show( char *msg )
void Knotvector::show( const char *msg )
{
#ifndef NDEBUG
dprintf( "%s\n", msg );

View file

@ -49,7 +49,7 @@ struct Knotvector { /* a knot vector */
~Knotvector( void );
void init( long, long, long, INREAL * );
int validate( void );
void show( char * );
void show( const char * );
long order; /* order of spline */
long knotcount; /* number of knots */

View file

@ -677,7 +677,7 @@ NurbsTessellator::do_nurbserror( int msg )
}
int
NurbsTessellator::do_check_knots( Knotvector *knots, char *msg )
NurbsTessellator::do_check_knots( Knotvector *knots, const char *msg )
{
int status = knots->validate();
if( status ) {

View file

@ -112,7 +112,7 @@ protected:
private:
void resetObjects( void );
int do_check_knots( Knotvector *, char * );
int do_check_knots( Knotvector *, const char * );
void do_nurbserror( int );
void do_bgncurve( O_curve * );
void do_endcurve( void );

View file

@ -531,16 +531,18 @@ Subdivider::nonSamplingSplit(
patchlist.pspec[param].range[1] ) * 0.5;
split( source, left, right, param, mid );
Patchlist subpatchlist( patchlist, param, mid );
if( left.isnonempty() )
if( left.isnonempty() ) {
if( subpatchlist.cullCheck() == CULL_TRIVIAL_REJECT )
freejarcs( left );
else
nonSamplingSplit( left, subpatchlist, subdivisions-1, param );
if( right.isnonempty() )
}
if( right.isnonempty() ) {
if( patchlist.cullCheck() == CULL_TRIVIAL_REJECT )
freejarcs( right );
else
nonSamplingSplit( right, patchlist, subdivisions-1, param );
}
} else {
// make bbox calls

View file

@ -113,8 +113,8 @@ Int isCusp(directedLine *v)
else if(A[1] > B[1] && C[1] > B[1])
return 1;
if(isAbove(v, v) && isAbove(v, v->getPrev()) ||
isBelow(v, v) && isBelow(v, v->getPrev()))
if((isAbove(v, v) && isAbove(v, v->getPrev())) ||
(isBelow(v, v) && isBelow(v, v->getPrev())))
return 1;
else
return 0;

View file

@ -52,6 +52,12 @@ select(IN INT s,
SOCKET Handle;
DPRINT("select: %lx %p %p %p %p\n", s, readfds, writefds, exceptfds, timeout);
#if defined(__GNUC__) && \
(__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__ == 40400)
/* Silence incorrect GCC 4.4.0 warning */
Handle = 0;
#endif
/* Check for WSAStartup */
if ((ErrorCode = WsQuickProlog()) == ERROR_SUCCESS)
{

View file

@ -80,6 +80,12 @@ IUnregisterSubdevice_fnUnregisterSubdevice(
ASSERT_IRQL_EQUAL(PASSIVE_LEVEL);
#if defined(__GNUC__) && \
(__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__ == 40400)
/* Silence incorrect GCC 4.4.0 warning */
SubDeviceEntry = NULL;
#endif
DeviceExtension = (PPCLASS_DEVICE_EXTENSION)DeviceObject->DeviceExtension;
ASSERT(DeviceExtension);

View file

@ -18,6 +18,8 @@
#include <portcls.h>
#include <debug.h>
WCHAR DeviceName[] = L"Uart";
NTSTATUS
NTAPI
StartDevice(
@ -68,7 +70,7 @@ StartDevice(
}
DPRINT1("Registering subdevice via PcRegisterSubdevice\n");
Status = PcRegisterSubdevice(pDeviceObject, L"Uart", port);
Status = PcRegisterSubdevice(pDeviceObject, DeviceName, port);
if (!NT_SUCCESS(Status))
{