This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Fix PR gdb/290


Checked in as obvious.  Wonder why GCC didn't warn about this.  Should
we add some more -Wxxx flags?

Mark


Index: ChangeLog
from  Mark Kettenis  <kettenis@gnu.org>

	* doublest.c (store_typed_floating): Don't try to return a value.
	Fixes PR gdb/290.

Index: doublest.c
===================================================================
RCS file: /cvs/src/src/gdb/doublest.c,v
retrieving revision 1.8
diff -u -p -r1.8 doublest.c
--- doublest.c 2002/01/22 19:57:40 1.8
+++ doublest.c 2002/02/09 17:24:44
@@ -732,9 +732,9 @@ store_typed_floating (void *addr, const 
   memset (addr, 0, TYPE_LENGTH (type));
 
   if (TYPE_FLOATFORMAT (type) == NULL)
-    return store_floating (addr, TYPE_LENGTH (type), val);
-
-  floatformat_from_doublest (TYPE_FLOATFORMAT (type), &val, addr);
+    store_floating (addr, TYPE_LENGTH (type), val);
+  else
+    floatformat_from_doublest (TYPE_FLOATFORMAT (type), &val, addr);
 }
 
 /* Convert a floating-point number of type FROM_TYPE from a


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]