public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [patch 2.4] menuconfig fix crash due to infinite recursion
@ 2004-09-29 16:19 maks attems
  2004-09-30 19:33 ` maximilian attems
  0 siblings, 1 reply; 2+ messages in thread
From: maks attems @ 2004-09-29 16:19 UTC (permalink / raw)
  To: linux-kernel; +Cc: marcelo.tosatti, sam

gawk(1) tells that getline "returns 0 on end of file and -1 on an error."
in current script for menuconfig if getline has an error,
it is still treated as true.

2.6 don't use that script anymore.
fix suggestion from Aharon Robbins <arnold@skeeve.com>
debian bts has 2 bugs open concerning that issue,
this is the one containing belows fix:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=147469

[TM] tested.
menuconfig still works for me. ;)


--- a/scripts/Menuconfig	2002-08-03 02:39:46.000000000 +0200
+++ b/scripts/Menuconfig	2004-09-29 18:00:29.000000000 +0200
@@ -714,7 +714,7 @@ BEGIN {
 
 function parser(ifile,menu) {
 
-	while (getline <ifile) {
+	while ((getline < ifile) > 0) {
 		if ($1 == "mainmenu_option") {
 			comment_is_option = "1"
 		}

--
maks
kernel janitor  	http://janitor.kernelnewbies.org/


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-09-30 19:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-09-29 16:19 [patch 2.4] menuconfig fix crash due to infinite recursion maks attems
2004-09-30 19:33 ` maximilian attems

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox