[kaffe] CVS kaffe (dalibor): Small fix for compiler warning about unused variables on parisc-hpux with gcc 3.

Kaffe CVS Kaffe Mailing List <kaffe@kaffe.org>
Thu Sep 25 10:30:02 2003


PatchSet 4067 
Date: 2003/09/25 17:26:15
Author: dalibor
Branch: HEAD
Tag: (none) 
Log:
Small fix for compiler warning about unused variables on parisc-hpux with gcc 3.3.1

Members: 
	ChangeLog:1.1662->1.1663 
	libraries/clib/awt/X/fnt.c:1.10->1.11 
	libraries/clib/awt/X/gra.c:1.20->1.21 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.1662 kaffe/ChangeLog:1.1663
--- kaffe/ChangeLog:1.1662	Thu Sep 25 16:29:38 2003
+++ kaffe/ChangeLog	Thu Sep 25 17:26:15 2003
@@ -1,5 +1,15 @@
 2003-09-25  Dalibor Topic <robilad@kaffe.org>
 
+	* libraries/clib/awt/X/fnt.c:
+	(Java_java_awt_Toolkit_fntStringWidth)  Only declare n if
+	WORDS_BIGENDIAN is defined.
+
+	* libraries/clib/awt/X/gra.c:
+	(Java_java_awt_Toolkit_graDrawString) Only declare n if
+	WORDS_BIGENDIAN is defined.
+	
+2003-09-25  Dalibor Topic <robilad@kaffe.org>
+
 	* libraries/clib/io/FileDescriptor.c
 	(java_io_FileDescriptor_nativeSetLength) Changed type of ret to
 	ssize_t to fix compiler warning with gcc 3.3.1 on parisc-hpux.
Index: kaffe/libraries/clib/awt/X/fnt.c
diff -u kaffe/libraries/clib/awt/X/fnt.c:1.10 kaffe/libraries/clib/awt/X/fnt.c:1.11
--- kaffe/libraries/clib/awt/X/fnt.c:1.10	Tue Feb 29 05:31:26 2000
+++ kaffe/libraries/clib/awt/X/fnt.c	Thu Sep 25 17:26:16 2003
@@ -279,7 +279,10 @@
   jboolean isCopy;
   const jchar    *jc = (*env)->GetStringChars( env, jStr, &isCopy);
   int      len = (*env)->GetStringLength( env, jStr);
-  int      w, n;
+  int      w;
+#ifndef WORDS_BIGENDIAN
+  int      n;
+#endif
   XChar2b  *b;
 
 #ifndef WORDS_BIGENDIAN
Index: kaffe/libraries/clib/awt/X/gra.c
diff -u kaffe/libraries/clib/awt/X/gra.c:1.20 kaffe/libraries/clib/awt/X/gra.c:1.21
--- kaffe/libraries/clib/awt/X/gra.c:1.20	Mon Aug  4 13:48:15 2003
+++ kaffe/libraries/clib/awt/X/gra.c	Thu Sep 25 17:26:16 2003
@@ -209,7 +209,10 @@
 									  Graphics* gr, jstring str, jint x, jint y )
 {
   jboolean     isCopy;
-  int          n, len;
+  int          len;
+#ifndef WORDS_BIGENDIAN
+  int n;
+#endif
   const jchar  *jc;
   XChar2b      *b;