summaryrefslogtreecommitdiff
path: root/avr
diff options
context:
space:
mode:
authorLeo C2016-04-22 09:11:02 +0200
committerLeo C2016-04-22 09:11:02 +0200
commitf32690e8a658acc4b935289d4719be1b004deb3b (patch)
tree235a4297713ab4826efdf7b8b22b747575b0f157 /avr
parent5730789084d22d229a87fa42fe55079c4bb35cd8 (diff)
downloadz180-stamp-f32690e8a658acc4b935289d4719be1b004deb3b.zip
Remove redundant hist_init()
Diffstat (limited to 'avr')
-rw-r--r--avr/cli_readline.c21
1 files changed, 1 insertions, 20 deletions
diff --git a/avr/cli_readline.c b/avr/cli_readline.c
index e8f39ae..6aef92e 100644
--- a/avr/cli_readline.c
+++ b/avr/cli_readline.c
@@ -8,7 +8,7 @@
* (C) Copyright 2005
* JinHua Luo, GuangDong Linux Center, <luo.jinhua@gd-linux.com>
*
- * SPDX-License-Identifier: GPL-2.0+
+ * SPDX-License-Identifier: GPL-2.0
*/
#include "common.h"
@@ -259,19 +259,6 @@ static int_fast8_t hist_cur = -1;
static char *hist_list[HIST_MAX];
-static void hist_init(void)
-{
- int_fast8_t i;
-
- hist_max = 0;
- hist_add_idx = 0;
- hist_cur = -1;
-
- for (i = 0; i < HIST_MAX; i++) {
- hist_list[i] = NULL;
- }
-}
-
static void cread_add_to_hist(char *line)
{
if (hist_max) {
@@ -580,12 +567,6 @@ static int cli_readline_into_buffer(const FLASH char *const prompt, char *buffer
#ifdef CONFIG_CMDLINE_EDITING
uint_fast8_t len = CONFIG_SYS_CBSIZE;
int rc;
- static bool initted;
-
- if (!initted) {
- hist_init();
- initted = 1;
- }
if (prompt)
my_puts_P(prompt);