* [PATCH] kconfig: fix a regression when exiting menuconfig without saving
@ 2012-01-16 7:01 Li Zefan
2012-01-16 7:20 ` Cong Wang
0 siblings, 1 reply; 6+ messages in thread
From: Li Zefan @ 2012-01-16 7:01 UTC (permalink / raw)
To: Michal Marek; +Cc: Arnaud Lacombe, Davidlohr Bueso, LKML, linux-kbuild
$ make menuconfig
HOSTCC scripts/kconfig/mconf.o
HOSTLD scripts/kconfig/mconf
scripts/kconfig/mconf Kconfig
Your configuration changes were NOT saved.
make[1]: *** [menuconfig] Error 1
make: *** [menuconfig] Error 2
Exiting menuconfig without saving, make will report error.
This is a regression, and was introduced by
commit 564899f9f0a2df85fa367c8749a1fef323cb3215
Author: Davidlohr Bueso <dave@gnu.org>
Date: Sun Aug 21 22:04:09 2011 -0300
kconfig: handle SIGINT in menuconfig
Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
---
scripts/kconfig/mconf.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/scripts/kconfig/mconf.c b/scripts/kconfig/mconf.c
index 19e200d..2c6286c 100644
--- a/scripts/kconfig/mconf.c
+++ b/scripts/kconfig/mconf.c
@@ -830,6 +830,8 @@ static int handle_exit(void)
fprintf(stderr, _("\n\n"
"Your configuration changes were NOT saved."
"\n\n"));
+ if (res != KEY_ESC)
+ res = 0;
}
return res;
--
1.7.3.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] kconfig: fix a regression when exiting menuconfig without saving
2012-01-16 7:01 [PATCH] kconfig: fix a regression when exiting menuconfig without saving Li Zefan
@ 2012-01-16 7:20 ` Cong Wang
2012-01-16 7:30 ` Li Zefan
0 siblings, 1 reply; 6+ messages in thread
From: Cong Wang @ 2012-01-16 7:20 UTC (permalink / raw)
To: Li Zefan
Cc: Michal Marek, Arnaud Lacombe, Davidlohr Bueso, LKML, linux-kbuild
On Mon, 2012-01-16 at 15:01 +0800, Li Zefan wrote:
> $ make menuconfig
> HOSTCC scripts/kconfig/mconf.o
> HOSTLD scripts/kconfig/mconf
> scripts/kconfig/mconf Kconfig
>
> Your configuration changes were NOT saved.
>
> make[1]: *** [menuconfig] Error 1
> make: *** [menuconfig] Error 2
>
> Exiting menuconfig without saving, make will report error.
This should be fixed by "[PATCH] scripts:kconfig:mconf.c: let make not
report error when not save configuration".
Thanks.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] kconfig: fix a regression when exiting menuconfig without saving
2012-01-16 7:20 ` Cong Wang
@ 2012-01-16 7:30 ` Li Zefan
2012-01-16 7:57 ` [PATCH] menuconfig: fix a regression when canceling the prompt dialog at exit Li Zefan
0 siblings, 1 reply; 6+ messages in thread
From: Li Zefan @ 2012-01-16 7:30 UTC (permalink / raw)
To: Cong Wang
Cc: Michal Marek, Arnaud Lacombe, Davidlohr Bueso, LKML, linux-kbuild
Cong Wang wrote:
> On Mon, 2012-01-16 at 15:01 +0800, Li Zefan wrote:
>> $ make menuconfig
>> HOSTCC scripts/kconfig/mconf.o
>> HOSTLD scripts/kconfig/mconf
>> scripts/kconfig/mconf Kconfig
>>
>> Your configuration changes were NOT saved.
>>
>> make[1]: *** [menuconfig] Error 1
>> make: *** [menuconfig] Error 2
>>
>> Exiting menuconfig without saving, make will report error.
>
> This should be fixed by "[PATCH] scripts:kconfig:mconf.c: let make not
> report error when not save configuration".
>
I didn't notice that patch. I just took a look on it, and unfortunately
that patch is wrong, in that now pressing ESC in the Yes/No dialog will
exit menuconfig instead of returning to the main menu.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH] menuconfig: fix a regression when canceling the prompt dialog at exit
2012-01-16 7:30 ` Li Zefan
@ 2012-01-16 7:57 ` Li Zefan
2012-01-16 8:05 ` Wang YanQing
2012-01-16 13:44 ` Michal Marek
0 siblings, 2 replies; 6+ messages in thread
From: Li Zefan @ 2012-01-16 7:57 UTC (permalink / raw)
To: Michal Marek
Cc: Cong Wang, Arnaud Lacombe, Davidlohr Bueso, LKML, linux-kbuild,
Wang YanQing
This commit fixes a bug, while introducing a new one..
commit 7203ddbd4be9720649e47d756a001e0c7d7f8ae2
Author: Wang YanQing <udknight@gmail.com>
Date: Thu Jan 12 11:31:32 2012 +0800
menuconfig: let make not report error when not save configuration
Pressing ESC should cancel the yes/no dialog and return back to
the main menu, but not exit from menuconfig.
Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
---
scripts/kconfig/mconf.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/scripts/kconfig/mconf.c b/scripts/kconfig/mconf.c
index 86cd1ea..2c6286c 100644
--- a/scripts/kconfig/mconf.c
+++ b/scripts/kconfig/mconf.c
@@ -830,7 +830,8 @@ static int handle_exit(void)
fprintf(stderr, _("\n\n"
"Your configuration changes were NOT saved."
"\n\n"));
- res = 0;
+ if (res != KEY_ESC)
+ res = 0;
}
return res;
--
1.7.3.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] menuconfig: fix a regression when canceling the prompt dialog at exit
2012-01-16 7:57 ` [PATCH] menuconfig: fix a regression when canceling the prompt dialog at exit Li Zefan
@ 2012-01-16 8:05 ` Wang YanQing
2012-01-16 13:44 ` Michal Marek
1 sibling, 0 replies; 6+ messages in thread
From: Wang YanQing @ 2012-01-16 8:05 UTC (permalink / raw)
To: Li Zefan
Cc: Michal Marek, Cong Wang, Arnaud Lacombe, Davidlohr Bueso, LKML,
linux-kbuild
On Mon, Jan 16, 2012 at 03:57:39PM +0800, Li Zefan wrote:
> This commit fixes a bug, while introducing a new one..
>
> commit 7203ddbd4be9720649e47d756a001e0c7d7f8ae2
> Author: Wang YanQing <udknight@gmail.com>
> Date: Thu Jan 12 11:31:32 2012 +0800
>
> menuconfig: let make not report error when not save configuration
>
> Pressing ESC should cancel the yes/no dialog and return back to
> the main menu, but not exit from menuconfig.
>
> Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Acked-by: Wang YanQing <udknight@gmail.com>
> ---
> scripts/kconfig/mconf.c | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/scripts/kconfig/mconf.c b/scripts/kconfig/mconf.c
> index 86cd1ea..2c6286c 100644
> --- a/scripts/kconfig/mconf.c
> +++ b/scripts/kconfig/mconf.c
> @@ -830,7 +830,8 @@ static int handle_exit(void)
> fprintf(stderr, _("\n\n"
> "Your configuration changes were NOT saved."
> "\n\n"));
> - res = 0;
> + if (res != KEY_ESC)
> + res = 0;
> }
>
> return res;
> --
> 1.7.3.1
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] menuconfig: fix a regression when canceling the prompt dialog at exit
2012-01-16 7:57 ` [PATCH] menuconfig: fix a regression when canceling the prompt dialog at exit Li Zefan
2012-01-16 8:05 ` Wang YanQing
@ 2012-01-16 13:44 ` Michal Marek
1 sibling, 0 replies; 6+ messages in thread
From: Michal Marek @ 2012-01-16 13:44 UTC (permalink / raw)
To: Li Zefan
Cc: Cong Wang, Arnaud Lacombe, Davidlohr Bueso, LKML, linux-kbuild,
Wang YanQing
On 16.1.2012 08:57, Li Zefan wrote:
> This commit fixes a bug, while introducing a new one..
>
> commit 7203ddbd4be9720649e47d756a001e0c7d7f8ae2
> Author: Wang YanQing <udknight@gmail.com>
> Date: Thu Jan 12 11:31:32 2012 +0800
>
> menuconfig: let make not report error when not save configuration
>
> Pressing ESC should cancel the yes/no dialog and return back to
> the main menu, but not exit from menuconfig.
Thanks, applied. Note that in the Ctrl-C case, ESC still exits with an
error. Changing sig_handler() to only exit if res != KEY_ESC is not
sufficient, as the dialog is not redrawn. Hm.
Michal
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2012-01-16 13:44 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-01-16 7:01 [PATCH] kconfig: fix a regression when exiting menuconfig without saving Li Zefan
2012-01-16 7:20 ` Cong Wang
2012-01-16 7:30 ` Li Zefan
2012-01-16 7:57 ` [PATCH] menuconfig: fix a regression when canceling the prompt dialog at exit Li Zefan
2012-01-16 8:05 ` Wang YanQing
2012-01-16 13:44 ` Michal Marek
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).