From b17077ede01fdee35c0da5ed3bec62b549cd051f Mon Sep 17 00:00:00 2001 From: "Carlos R. Mafra" Date: Fri, 16 Apr 2010 18:12:25 +0200 Subject: [PATCH] Avoid more gcc warnings MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit WUtil.h:212: warning: function declaration isn’t a prototype WUtil.h:259: warning: function declaration isn’t a prototype WUtil.h:300: warning: function declaration isn’t a prototype WINGsP.h:593: warning: function declaration isn’t a prototype WINGsP.h:599: warning: function declaration isn’t a prototype WINGs.h:616: warning: function declaration isn’t a prototype raster.c:295: warning: no previous prototype for ‘calculateCombineArea’ --- WINGs/WINGs/WINGs.h | 2 +- WINGs/WINGs/WINGsP.h | 4 ++-- WINGs/WINGs/WUtil.h | 6 +++--- WINGs/wapplication.c | 4 +--- src/main.c | 4 ++-- wrlib/raster.c | 5 ++--- 6 files changed, 11 insertions(+), 14 deletions(-) diff --git a/WINGs/WINGs/WINGs.h b/WINGs/WINGs/WINGs.h index ba3297ef..93a8a014 100644 --- a/WINGs/WINGs/WINGs.h +++ b/WINGs/WINGs/WINGs.h @@ -613,7 +613,7 @@ void WMInitializeApplication(char *applicationName, int *argc, char **argv); void WMSetResourcePath(char *path); /* don't free the returned string */ -char* WMGetApplicationName(); +char* WMGetApplicationName(void); /* Try to locate resource file. ext may be NULL */ char* WMPathForResourceOfType(char *resource, char *ext); diff --git a/WINGs/WINGs/WINGsP.h b/WINGs/WINGs/WINGsP.h index b72de53b..bb58906c 100644 --- a/WINGs/WINGs/WINGsP.h +++ b/WINGs/WINGs/WINGsP.h @@ -590,13 +590,13 @@ Bool W_SendDnDClientMessage(Display *dpy, Window win, Atom message, void W_DragSourceStartTimer(WMDraggingInfo *info); -void W_DragSourceStopTimer(); +void W_DragSourceStopTimer(void); void W_DragSourceStateHandler(WMDraggingInfo *info, XClientMessageEvent *event); void W_DragDestinationStartTimer(WMDraggingInfo *info); -void W_DragDestinationStopTimer(); +void W_DragDestinationStopTimer(void); void W_DragDestinationStoreEnterMsgInfo(WMDraggingInfo *info, WMView *toplevel, XClientMessageEvent *event); diff --git a/WINGs/WINGs/WUtil.h b/WINGs/WINGs/WUtil.h index 4be89be2..6849f524 100644 --- a/WINGs/WINGs/WUtil.h +++ b/WINGs/WINGs/WUtil.h @@ -209,7 +209,7 @@ int wmkdirhier(const char *path); int wrmdirhier(const char *path); /* don't free the returned string */ -char* wgethomedir(); +char* wgethomedir(void); void* wmalloc(size_t size); void* wrealloc(void *ptr, size_t newsize); @@ -256,7 +256,7 @@ WMRange wmkrange(int start, int count); #endif -char* wusergnusteppath(); +char* wusergnusteppath(void); char* wdefaultspathfordomain(char *domain); char* wglobaldefaultspathfordomain(const char *domain); @@ -297,7 +297,7 @@ void WMDeleteInputHandler(WMHandlerID handlerID); * This function will handle all input/timer/idle events, then return. */ -void WHandleEvents(); +void WHandleEvents(void); /*......................................................................*/ diff --git a/WINGs/wapplication.c b/WINGs/wapplication.c index e9a6cf00..620e378b 100644 --- a/WINGs/wapplication.c +++ b/WINGs/wapplication.c @@ -1,12 +1,10 @@ #include +#include #include "WINGsP.h" - #include "wconfig.h" -#include "X11/Xlocale.h" - extern void W_InitNotificationCenter(void); struct W_Application WMApplication; diff --git a/src/main.c b/src/main.c index 5833a118..a15f3fcc 100644 --- a/src/main.c +++ b/src/main.c @@ -177,8 +177,8 @@ static char **Arguments; static int ArgCount; -extern void EventLoop(); -extern void StartUp(); +extern void EventLoop(void); +extern void StartUp(Bool defaultScreenOnly); extern int MonitorLoop(int argc, char **argv); static Bool multiHead = True; diff --git a/wrlib/raster.c b/wrlib/raster.c index 2c11949e..188dd516 100644 --- a/wrlib/raster.c +++ b/wrlib/raster.c @@ -291,9 +291,8 @@ void RCombineImagesWithOpaqueness(RImage * image, RImage * src, int opaqueness) #undef COP } -int -calculateCombineArea(RImage * des, int *sx, int *sy, - unsigned int *swidth, unsigned int *sheight, int *dx, int *dy) +static int calculateCombineArea(RImage *des, int *sx, int *sy, unsigned int *swidth, + unsigned int *sheight, int *dx, int *dy) { int width = (int)*swidth, height = (int)*sheight;