mirror of
https://github.com/ipxe/ipxe
synced 2025-12-21 12:30:20 +03:00
[syslog] Handle backspace characters
Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
@@ -47,6 +47,13 @@ size_t line_putchar ( struct line_console *line, int character ) {
|
|||||||
if ( character < 0 )
|
if ( character < 0 )
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
|
/* Handle backspace characters */
|
||||||
|
if ( character == '\b' ) {
|
||||||
|
if ( line->index )
|
||||||
|
line->index--;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
/* Ignore carriage return */
|
/* Ignore carriage return */
|
||||||
if ( character == '\r' )
|
if ( character == '\r' )
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user