From fceafda7d034e62bd12688c6f2a85c3dc32c67cc Mon Sep 17 00:00:00 2001 From: dkf Date: Fri, 22 Feb 2002 13:13:13 +0000 Subject: Stop GCC from issuing warnings about things that don't matter. --- ChangeLog | 5 +++++ unix/tkUnixMenu.c | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 27caaf9..9484ce5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2002-02-22 Donal K. Fellows + + * unix/tkUnixMenu.c (GetMenuLabelGeometry,DrawMenuEntryLabel): + Stop meaningless GCC warnings. + 2002-02-21 Jeff Hobbs * doc/panedwindow.n: diff --git a/unix/tkUnixMenu.c b/unix/tkUnixMenu.c index c2d4e41..930a973 100644 --- a/unix/tkUnixMenu.c +++ b/unix/tkUnixMenu.c @@ -8,7 +8,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tkUnixMenu.c,v 1.6 2002/01/17 03:35:01 dgp Exp $ + * RCS: @(#) $Id: tkUnixMenu.c,v 1.7 2002/02/22 13:13:13 dkf Exp $ */ #include "tkPort.h" @@ -707,7 +707,7 @@ DrawMenuEntryLabel(menuPtr, mePtr, d, gc, tkfont, fmPtr, x, y, width, height) int activeBorderWidth; int leftEdge; int imageHeight, imageWidth; - int textHeight, textWidth; + int textHeight = 0, textWidth = 0; /* stop GCC warning */ int haveImage = 0, haveText = 0; int imageXOffset = 0, imageYOffset = 0; int textXOffset = 0, textYOffset = 0; @@ -1473,7 +1473,7 @@ GetMenuLabelGeometry(mePtr, tkfont, fmPtr, widthPtr, heightPtr) * portion */ { TkMenu *menuPtr = mePtr->menuPtr; - int haveImage = 0, haveText = 0; + int haveImage = 0; if (mePtr->image != NULL) { Tk_SizeOfImage(mePtr->image, widthPtr, heightPtr); -- cgit v0.12