Skip to contentSkip to conversation

Don't assume arguments to init have no period in them.

PATCH New Rob Landley 1 participant 1 message Feb 22, 2007

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Don't assume arguments to init have no period in them.

The kernel assumes that nobody will ever legitimately feed in a kernel command line option with a period in it, and the kernel is wrong: I'm feeding the path to a script as an argument to my init program, the name of the script ends in .sh.

I've been using this patch ever since 2.6.13, and I still need it.

init/main.c +0 -9
@@ -242,15 +242,6 @@
 	if (obsolete_checksetup(param))
 		return 0;
 
-	/*
-	 * Preemptive maintenance for "why didn't my mispelled command
-	 * line work?"
-	 */
-	if (strchr(param, '.') && (!val || strchr(param, '.') < val)) {
-		printk(KERN_ERR "Unknown boot option `%s': ignoring\n", param);
-		return 0;
-	}
-
 	if (panic_later)
 		return 0;
 
Signature · 2 lines
"Perfection is reached, not when there is no longer anything to add, but
when there is no longer anything to take away." - Antoine de Saint-Exupery