You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by je...@apache.org on 2021/07/29 17:28:25 UTC
[mynewt-core] branch master updated: sys/console: Stop history auto
search when echo is off
This is an automated email from the ASF dual-hosted git repository.
jerzy pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-core.git
The following commit(s) were added to refs/heads/master by this push:
new 88d521f sys/console: Stop history auto search when echo is off
88d521f is described below
commit 88d521f4edc521092107ac6d0811e19fad2e0f54
Author: Jerzy Kasenberg <je...@apache.org>
AuthorDate: Mon Jul 19 11:25:14 2021 +0200
sys/console: Stop history auto search when echo is off
When echo is off history auto search should not output
anything.
This allows to have newtmgr upload working while code
is build with history auto search support.
---
sys/console/full/src/console.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/sys/console/full/src/console.c b/sys/console/full/src/console.c
index 346941c..f9df03c 100644
--- a/sys/console/full/src/console.c
+++ b/sys/console/full/src/console.c
@@ -710,7 +710,8 @@ insert_char(char *pos, char c)
if (trailing_chars == 0) {
*pos = c;
if (!MYNEWT_VAL_CHOICE(CONSOLE_HISTORY, none) &&
- MYNEWT_VAL(CONSOLE_HISTORY_AUTO_SEARCH) && cur > 1) {
+ MYNEWT_VAL(CONSOLE_HISTORY_AUTO_SEARCH) &&
+ echo != 0 && cur > 1) {
history_line = 0;
console_history_search(pos - cur + 1, HFT_MATCH_PREV);
return;