Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-davinci
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
linux
linux-davinci
Commits
a5229e6b
Commit
a5229e6b
authored
Sep 04, 2007
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Plain Diff
Merge
git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-fix
parents
bc5a6deb
f82f3f94
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
9 deletions
+12
-9
scripts/kconfig/conf.c
scripts/kconfig/conf.c
+12
-9
No files found.
scripts/kconfig/conf.c
View file @
a5229e6b
...
@@ -72,7 +72,7 @@ static void check_stdin(void)
...
@@ -72,7 +72,7 @@ static void check_stdin(void)
}
}
}
}
static
void
conf_askvalue
(
struct
symbol
*
sym
,
const
char
*
def
)
static
int
conf_askvalue
(
struct
symbol
*
sym
,
const
char
*
def
)
{
{
enum
symbol_type
type
=
sym_get_type
(
sym
);
enum
symbol_type
type
=
sym_get_type
(
sym
);
tristate
val
;
tristate
val
;
...
@@ -87,7 +87,7 @@ static void conf_askvalue(struct symbol *sym, const char *def)
...
@@ -87,7 +87,7 @@ static void conf_askvalue(struct symbol *sym, const char *def)
printf
(
"%s
\n
"
,
def
);
printf
(
"%s
\n
"
,
def
);
line
[
0
]
=
'\n'
;
line
[
0
]
=
'\n'
;
line
[
1
]
=
0
;
line
[
1
]
=
0
;
return
;
return
0
;
}
}
switch
(
input_mode
)
{
switch
(
input_mode
)
{
...
@@ -97,23 +97,23 @@ static void conf_askvalue(struct symbol *sym, const char *def)
...
@@ -97,23 +97,23 @@ static void conf_askvalue(struct symbol *sym, const char *def)
case
set_random
:
case
set_random
:
if
(
sym_has_value
(
sym
))
{
if
(
sym_has_value
(
sym
))
{
printf
(
"%s
\n
"
,
def
);
printf
(
"%s
\n
"
,
def
);
return
;
return
0
;
}
}
break
;
break
;
case
ask_new
:
case
ask_new
:
case
ask_silent
:
case
ask_silent
:
if
(
sym_has_value
(
sym
))
{
if
(
sym_has_value
(
sym
))
{
printf
(
"%s
\n
"
,
def
);
printf
(
"%s
\n
"
,
def
);
return
;
return
0
;
}
}
check_stdin
();
check_stdin
();
case
ask_all
:
case
ask_all
:
fflush
(
stdout
);
fflush
(
stdout
);
fgets
(
line
,
128
,
stdin
);
fgets
(
line
,
128
,
stdin
);
return
;
return
1
;
case
set_default
:
case
set_default
:
printf
(
"%s
\n
"
,
def
);
printf
(
"%s
\n
"
,
def
);
return
;
return
1
;
default:
default:
break
;
break
;
}
}
...
@@ -123,7 +123,7 @@ static void conf_askvalue(struct symbol *sym, const char *def)
...
@@ -123,7 +123,7 @@ static void conf_askvalue(struct symbol *sym, const char *def)
case
S_HEX
:
case
S_HEX
:
case
S_STRING
:
case
S_STRING
:
printf
(
"%s
\n
"
,
def
);
printf
(
"%s
\n
"
,
def
);
return
;
return
1
;
default:
default:
;
;
}
}
...
@@ -174,6 +174,7 @@ static void conf_askvalue(struct symbol *sym, const char *def)
...
@@ -174,6 +174,7 @@ static void conf_askvalue(struct symbol *sym, const char *def)
break
;
break
;
}
}
printf
(
"%s"
,
line
);
printf
(
"%s"
,
line
);
return
1
;
}
}
int
conf_string
(
struct
menu
*
menu
)
int
conf_string
(
struct
menu
*
menu
)
...
@@ -187,7 +188,8 @@ int conf_string(struct menu *menu)
...
@@ -187,7 +188,8 @@ int conf_string(struct menu *menu)
def
=
sym_get_string_value
(
sym
);
def
=
sym_get_string_value
(
sym
);
if
(
sym_get_string_value
(
sym
))
if
(
sym_get_string_value
(
sym
))
printf
(
"[%s] "
,
def
);
printf
(
"[%s] "
,
def
);
conf_askvalue
(
sym
,
def
);
if
(
!
conf_askvalue
(
sym
,
def
))
return
0
;
switch
(
line
[
0
])
{
switch
(
line
[
0
])
{
case
'\n'
:
case
'\n'
:
break
;
break
;
...
@@ -240,7 +242,8 @@ static int conf_sym(struct menu *menu)
...
@@ -240,7 +242,8 @@ static int conf_sym(struct menu *menu)
if
(
menu_has_help
(
menu
))
if
(
menu_has_help
(
menu
))
printf
(
"/?"
);
printf
(
"/?"
);
printf
(
"] "
);
printf
(
"] "
);
conf_askvalue
(
sym
,
sym_get_string_value
(
sym
));
if
(
!
conf_askvalue
(
sym
,
sym_get_string_value
(
sym
)))
return
0
;
strip
(
line
);
strip
(
line
);
switch
(
line
[
0
])
{
switch
(
line
[
0
])
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment