* [commit/obvious] minor fixes in DFP code
@ 2007-11-27 20:16 Thiago Jung Bauermann
0 siblings, 0 replies; only message in thread
From: Thiago Jung Bauermann @ 2007-11-27 20:16 UTC (permalink / raw)
To: gdb-patches
[-- Attachment #1: Type: text/plain, Size: 188 bytes --]
Hi,
Just commited the following minor fixes which slipped through in the
Decimal Floating Point support code.
--
[]'s
Thiago Jung Bauermann
Software Engineer
IBM Linux Technology Center
[-- Attachment #2: dfp-obvious.diff --]
[-- Type: text/x-patch, Size: 2114 bytes --]
2007-11-27 Thiago Jung Bauermann <bauerman@br.ibm.com>
* dfp.c (decimal_from_string): Remove superfluous newline from
error string.
(decimal_to_string): Likewise.
* printcmd.c (printf_command): Change string buffer to use
MAX_DECIMAL_STRING constant.
* value.c (value_from_decfloat): Likewise.
Index: dfp.c
===================================================================
RCS file: /cvs/src/src/gdb/dfp.c,v
retrieving revision 1.1
diff -u -r1.1 dfp.c
--- dfp.c 25 Oct 2007 17:52:31 -0000 1.1
+++ dfp.c 27 Nov 2007 20:01:45 -0000
@@ -71,7 +71,7 @@
decimal128ToString ((decimal128 *) dec, s);
break;
default:
- error (_("Unknown decimal floating point type.\n"));
+ error (_("Unknown decimal floating point type."));
break;
}
}
@@ -103,7 +103,7 @@
decimal128FromString ((decimal128 *) dec, string, &set);
break;
default:
- error (_("Unknown decimal floating point type.\n"));
+ error (_("Unknown decimal floating point type."));
break;
}
Index: printcmd.c
===================================================================
RCS file: /cvs/src/src/gdb/printcmd.c,v
retrieving revision 1.112
diff -u -r1.112 printcmd.c
--- printcmd.c 5 Nov 2007 11:32:31 -0000 1.112
+++ printcmd.c 27 Nov 2007 20:01:45 -0000
@@ -2128,7 +2128,7 @@
case decfloat_arg:
{
char *eos;
- char decstr[128];
+ char decstr[MAX_DECIMAL_STRING];
unsigned int dfp_len = TYPE_LENGTH (value_type (val_args[i]));
unsigned char *dfp_value_ptr = (unsigned char *) value_contents_all (val_args[i])
+ value_offset (val_args[i]);
Index: value.c
===================================================================
RCS file: /cvs/src/src/gdb/value.c,v
retrieving revision 1.52
diff -u -r1.52 value.c
--- value.c 25 Oct 2007 18:01:58 -0000 1.52
+++ value.c 27 Nov 2007 20:01:45 -0000
@@ -1652,7 +1652,7 @@
if (expect_type)
{
int expect_len = TYPE_LENGTH (expect_type);
- char decstr[128];
+ char decstr[MAX_DECIMAL_STRING];
int real_len;
decimal_to_string (decbytes, len, decstr);
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2007-11-27 20:16 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-11-27 20:16 [commit/obvious] minor fixes in DFP code Thiago Jung Bauermann
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox