* monitor.c: Fix so all the output shows up in the GUI command
window.
This commit is contained in:
parent
ce2349c52d
commit
151e7820c7
|
@ -1,3 +1,8 @@
|
||||||
|
Wed Feb 8 19:19:56 1995 Rob Savoye <rob@darkstar.cygnus.com>
|
||||||
|
|
||||||
|
* monitor.c: Fix so all the output shows up in the GUI command
|
||||||
|
window.
|
||||||
|
|
||||||
Mon Feb 6 18:50:59 1995 Stan Shebs <shebs@andros.cygnus.com>
|
Mon Feb 6 18:50:59 1995 Stan Shebs <shebs@andros.cygnus.com>
|
||||||
|
|
||||||
* i386-tdep.c (_initialize_i386_tdep): Put void decl on separate
|
* i386-tdep.c (_initialize_i386_tdep): Put void decl on separate
|
||||||
|
|
|
@ -327,7 +327,7 @@ debuglogs(va_alist)
|
||||||
*p = '\0'; /* terminate the string */
|
*p = '\0'; /* terminate the string */
|
||||||
|
|
||||||
if (sr_get_debug() > level)
|
if (sr_get_debug() > level)
|
||||||
puts (newbuf);
|
printf_unfiltered ("%s\n", newbuf);
|
||||||
|
|
||||||
#ifdef LOG_FILE /* write to the monitor log */
|
#ifdef LOG_FILE /* write to the monitor log */
|
||||||
if (log_file != 0x0) {
|
if (log_file != 0x0) {
|
||||||
|
@ -402,9 +402,12 @@ expect (string, discard)
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (!discard) {
|
if (!discard) {
|
||||||
|
putc_unfiltered (c);
|
||||||
|
#if 0
|
||||||
fwrite(string, 1, (p - 1) - string, stdout);
|
fwrite(string, 1, (p - 1) - string, stdout);
|
||||||
putchar((char)c);
|
putchar((char)c);
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
p = string;
|
p = string;
|
||||||
}
|
}
|
||||||
|
@ -622,18 +625,19 @@ monitor_open(args, name, from_tty)
|
||||||
|
|
||||||
SERIAL_RAW(monitor_desc);
|
SERIAL_RAW(monitor_desc);
|
||||||
|
|
||||||
#if !defined(__GO32__) && !defined(GDB_TARGET_IS_PA_ELF)
|
|
||||||
/* some systems only work with 2 stop bits */
|
/* some systems only work with 2 stop bits */
|
||||||
|
#if !defined(__GO32__) && !defined(GDB_TARGET_IS_PA_ELF)
|
||||||
if (STOPBITS == 2) {
|
if (STOPBITS == 2) {
|
||||||
temptempio = (TERMINAL *)SERIAL_GET_TTY_STATE(monitor_desc);
|
if (!strchr (dev_name, ':')) { /* don't set for a tcp connection */
|
||||||
|
temptempio = (TERMINAL *)SERIAL_GET_TTY_STATE(monitor_desc);
|
||||||
#ifdef HAVE_SGTTY
|
#ifdef HAVE_SGTTY
|
||||||
temptempio->sg_cflag |= baud_rate | CSTOPB;
|
temptempio->sg_cflag |= baud_rate | CSTOPB;
|
||||||
#else
|
#else
|
||||||
temptempio->c_cflag |= baud_rate | CSTOPB;
|
temptempio->c_cflag |= baud_rate | CSTOPB;
|
||||||
/*** temptempio->c_lflag |= ~0x00000008; turn off echo ***/
|
|
||||||
#endif
|
#endif
|
||||||
SERIAL_SET_TTY_STATE(monitor_desc, temptempio);
|
SERIAL_SET_TTY_STATE(monitor_desc, temptempio);
|
||||||
debuglogs (4, "Set serial port to 2 stop bits");
|
debuglogs (4, "Set serial port to 2 stop bits");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
#endif /* __GO32__ */
|
#endif /* __GO32__ */
|
||||||
|
|
||||||
|
@ -1026,14 +1030,8 @@ monitor_write_inferior_memory (memaddr, myaddr, len)
|
||||||
*p++ = num[7];
|
*p++ = num[7];
|
||||||
*p++ = ':'; /* add the colon delimeter */
|
*p++ = ':'; /* add the colon delimeter */
|
||||||
for (j = 0; j < len; j++) { /* copy the data in after converting it */
|
for (j = 0; j < len; j++) { /* copy the data in after converting it */
|
||||||
#if 0
|
|
||||||
hexword2ascii (num, myaddr[j]);
|
|
||||||
#endif
|
|
||||||
*p++ = tohex ((myaddr[j] >> 4) & 0xf);
|
*p++ = tohex ((myaddr[j] >> 4) & 0xf);
|
||||||
*p++ = tohex (myaddr[j] & 0xf);
|
*p++ = tohex (myaddr[j] & 0xf);
|
||||||
#if 0
|
|
||||||
strcpy ((buf+14)+(j * 2), num+6);
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
make_gdb_packet (packet, buf);
|
make_gdb_packet (packet, buf);
|
||||||
|
@ -1472,8 +1470,10 @@ monitor_load_srec (args, protocol)
|
||||||
if (GETACK) /* ACKnowledged, get next data chunk */
|
if (GETACK) /* ACKnowledged, get next data chunk */
|
||||||
break;
|
break;
|
||||||
} else { /* assume we got an ACK */
|
} else { /* assume we got an ACK */
|
||||||
if (hashmark)
|
if (hashmark) {
|
||||||
printf_filtered ("#");
|
putc_unfiltered ('#');
|
||||||
|
fflush (gdb_stdout);
|
||||||
|
}
|
||||||
debuglogs (3, "Got an ACK, sending next packet");
|
debuglogs (3, "Got an ACK, sending next packet");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1485,10 +1485,12 @@ monitor_load_srec (args, protocol)
|
||||||
} else { /* no protocols at all */
|
} else { /* no protocols at all */
|
||||||
printf_monitor ("%s\n", srec);
|
printf_monitor ("%s\n", srec);
|
||||||
}
|
}
|
||||||
if (hashmark)
|
if (hashmark) {
|
||||||
printf_filtered ("#");
|
putc_unfiltered ('#');
|
||||||
|
fflush (gdb_stdout);
|
||||||
|
}
|
||||||
type = 3; /* switch to a 4 byte address record */
|
type = 3; /* switch to a 4 byte address record */
|
||||||
fflush (stdout);
|
fflush (gdb_stdout);
|
||||||
}
|
}
|
||||||
free (buffer);
|
free (buffer);
|
||||||
} else {
|
} else {
|
||||||
|
@ -1496,7 +1498,7 @@ monitor_load_srec (args, protocol)
|
||||||
}
|
}
|
||||||
s = s->next;
|
s = s->next;
|
||||||
}
|
}
|
||||||
printf_filtered ("\n");
|
putc_unfiltered ('\n');
|
||||||
|
|
||||||
/*
|
/*
|
||||||
write a type 7 terminator record. no data for a type 7,
|
write a type 7 terminator record. no data for a type 7,
|
||||||
|
@ -1517,7 +1519,7 @@ monitor_load_srec (args, protocol)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (hashmark)
|
if (hashmark)
|
||||||
putchar ('\n');
|
putc_unfiltered ('\n');
|
||||||
|
|
||||||
expect_prompt ();
|
expect_prompt ();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue