mirror of
https://xff.cz/git/u-boot/
synced 2025-09-02 09:12:08 +02:00
Fix control-c handing in CONFIG_CMDLINE_EDITING
Properly pass break code back from readline. Patch by Roger Blofeld, 31 Jul 2006
This commit is contained in:
@@ -2,6 +2,10 @@
|
|||||||
Changes since U-Boot 1.1.4:
|
Changes since U-Boot 1.1.4:
|
||||||
======================================================================
|
======================================================================
|
||||||
|
|
||||||
|
* Fix control-c handing in CONFIG_CMDLINE_EDITING
|
||||||
|
Properly pass break code back from readline.
|
||||||
|
Patch by Roger Blofeld, 31 Jul 2006
|
||||||
|
|
||||||
* Add commandline history support to all AMCC eval boards
|
* Add commandline history support to all AMCC eval boards
|
||||||
Patch by Stefan Roese, 07 Aug 2006
|
Patch by Stefan Roese, 07 Aug 2006
|
||||||
|
|
||||||
|
@@ -937,6 +937,7 @@ int readline (const char *const prompt)
|
|||||||
#ifdef CONFIG_CMDLINE_EDITING
|
#ifdef CONFIG_CMDLINE_EDITING
|
||||||
char *p = console_buffer;
|
char *p = console_buffer;
|
||||||
unsigned int len=MAX_CMDBUF_SIZE;
|
unsigned int len=MAX_CMDBUF_SIZE;
|
||||||
|
int rc;
|
||||||
static int initted = 0;
|
static int initted = 0;
|
||||||
|
|
||||||
if (!initted) {
|
if (!initted) {
|
||||||
@@ -946,8 +947,8 @@ int readline (const char *const prompt)
|
|||||||
|
|
||||||
puts (prompt);
|
puts (prompt);
|
||||||
|
|
||||||
cread_line(p, &len);
|
rc = cread_line(p, &len);
|
||||||
return len;
|
return rc < 0 ? rc : len;
|
||||||
#else
|
#else
|
||||||
char *p = console_buffer;
|
char *p = console_buffer;
|
||||||
int n = 0; /* buffer index */
|
int n = 0; /* buffer index */
|
||||||
|
Reference in New Issue
Block a user