aboutsummaryrefslogtreecommitdiff
path: root/gdb/monitor.c
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2001-03-28 21:42:32 +0000
committerAndrew Cagney <cagney@redhat.com>2001-03-28 21:42:32 +0000
commit93d56215df715181dba7f5275de9863f28a6c941 (patch)
treebfea01c982a361dfe8ad972cb291de3d8085a7c2 /gdb/monitor.c
parent381bab78db8ce8d9a17929364bdc7901ac17e4f0 (diff)
downloadgdb-93d56215df715181dba7f5275de9863f28a6c941.zip
gdb-93d56215df715181dba7f5275de9863f28a6c941.tar.gz
gdb-93d56215df715181dba7f5275de9863f28a6c941.tar.bz2
Gag -Wuninitialized warnings.
Add -Wuninitialized to default warning list.
Diffstat (limited to 'gdb/monitor.c')
-rw-r--r--gdb/monitor.c39
1 files changed, 20 insertions, 19 deletions
diff --git a/gdb/monitor.c b/gdb/monitor.c
index 025a2cd..78746b7 100644
--- a/gdb/monitor.c
+++ b/gdb/monitor.c
@@ -1691,7 +1691,6 @@ monitor_read_memory_single (CORE_ADDR memaddr, char *myaddr, int len)
char membuf[sizeof (int) * 2 + 1];
char *p;
char *cmd;
- int i;
monitor_debug ("MON read single\n");
#if 0
@@ -1751,29 +1750,31 @@ monitor_read_memory_single (CORE_ADDR memaddr, char *myaddr, int len)
else
monitor_error ("monitor_read_memory_single",
"bad response from monitor",
- memaddr, i, membuf, c);
+ memaddr, 0, NULL, 0);
}
- for (i = 0; i < len * 2; i++)
- {
- int c;
-
- while (1)
- {
- c = readchar (timeout);
- if (isxdigit (c))
- break;
- if (c == ' ')
- continue;
- monitor_error ("monitor_read_memory_single",
- "bad response from monitor",
- memaddr, i, membuf, c);
- }
+ {
+ int i;
+ for (i = 0; i < len * 2; i++)
+ {
+ int c;
+ while (1)
+ {
+ c = readchar (timeout);
+ if (isxdigit (c))
+ break;
+ if (c == ' ')
+ continue;
+
+ monitor_error ("monitor_read_memory_single",
+ "bad response from monitor",
+ memaddr, i, membuf, 0);
+ }
membuf[i] = c;
}
-
- membuf[i] = '\000'; /* terminate the number */
+ membuf[i] = '\000'; /* terminate the number */
+ }
/* If TERM is present, we wait for that to show up. Also, (if TERM is
present), we will send TERM_CMD if that is present. In any case, we collect