forked from Imagelibrary/binutils-gdb
Return void from gdb_putc
I don't think it's very useful to return the character from gdb_putc, so this patch changes it to return void.
This commit is contained in:
@@ -60,12 +60,11 @@ ui_file::putstrn (const char *str, int n, int quoter, bool async_safe)
|
||||
printchar (str[i], quoter, async_safe);
|
||||
}
|
||||
|
||||
int
|
||||
void
|
||||
ui_file::putc (int c)
|
||||
{
|
||||
char copy = (char) c;
|
||||
write (©, 1);
|
||||
return c;
|
||||
}
|
||||
|
||||
void
|
||||
|
||||
@@ -51,7 +51,7 @@ public:
|
||||
write_async_safe method. */
|
||||
void putstrn (const char *str, int n, int quoter, bool async_safe = false);
|
||||
|
||||
int putc (int c);
|
||||
void putc (int c);
|
||||
|
||||
void vprintf (const char *, va_list) ATTRIBUTE_PRINTF (2, 0);
|
||||
|
||||
|
||||
@@ -1838,16 +1838,13 @@ fputs_highlighted (const char *str, const compiled_regex &highlight,
|
||||
gdb_puts (str, stream);
|
||||
}
|
||||
|
||||
/* Write character C to gdb_stdout using GDB's paging mechanism and return C.
|
||||
May return nonlocally. */
|
||||
|
||||
int
|
||||
void
|
||||
gdb_putc (int c)
|
||||
{
|
||||
return gdb_stdout->putc (c);
|
||||
}
|
||||
|
||||
int
|
||||
void
|
||||
gdb_putc (int c, struct ui_file *stream)
|
||||
{
|
||||
return stream->putc (c);
|
||||
|
||||
@@ -224,9 +224,9 @@ extern void set_screen_width_and_height (int width, int height);
|
||||
|
||||
extern void gdb_puts (const char *, struct ui_file *);
|
||||
|
||||
extern int gdb_putc (int c, struct ui_file *);
|
||||
extern void gdb_putc (int c, struct ui_file *);
|
||||
|
||||
extern int gdb_putc (int c);
|
||||
extern void gdb_putc (int c);
|
||||
|
||||
extern void gdb_puts (const char *);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user