projects
/
carl9170fw.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
kconfig: Fix expr_free() E_NOT leak
[carl9170fw.git]
/
config
/
conf.c
diff --git
a/config/conf.c
b/config/conf.c
index 6b6cba52a453455e2be70e3b16cf86cc6e88ca74..6be614318782bfc3c2e3525a8ebc5ad94d775f70 100644
(file)
--- a/
config/conf.c
+++ b/
config/conf.c
@@
-5,6
+5,7
@@
#include <locale.h>
#include <ctype.h>
#include <locale.h>
#include <ctype.h>
+#include <limits.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@
-39,7
+40,7
@@
static int indent = 1;
static int tty_stdio;
static int valid_stdin = 1;
static int conf_cnt;
static int tty_stdio;
static int valid_stdin = 1;
static int conf_cnt;
-static char line[
128
];
+static char line[
PATH_MAX
];
static struct menu *rootEntry;
static void print_help(struct menu *menu)
static struct menu *rootEntry;
static void print_help(struct menu *menu)
@@
-106,7
+107,7
@@
static int conf_askvalue(struct symbol *sym, const char *def)
/* fall through */
case oldaskconfig:
fflush(stdout);
/* fall through */
case oldaskconfig:
fflush(stdout);
- xfgets(line,
128
, stdin);
+ xfgets(line,
sizeof(line)
, stdin);
if (!tty_stdio)
printf("\n");
return 1;
if (!tty_stdio)
printf("\n");
return 1;
@@
-307,7
+308,7
@@
static int conf_choice(struct menu *menu)
/* fall through */
case oldaskconfig:
fflush(stdout);
/* fall through */
case oldaskconfig:
fflush(stdout);
- xfgets(line,
128
, stdin);
+ xfgets(line,
sizeof(line)
, stdin);
strip(line);
if (line[0] == '?') {
print_help(menu);
strip(line);
if (line[0] == '?') {
print_help(menu);