lkml.org 
[lkml]   [2001]   [Sep]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: Linux-2.2.20pre10
From
Date
On Thu, 2001-09-13 at 02:59, Willy TARREAU wrote:
> Robert M. Love pointed out that the command line parse could forget arguments
> if either MAX_INIT_ENVS or MAX_INIT_ARGS were reached, and his patch seems to
> fix it correctly :

I have posted posted this patch multiple times for 2.2 and 2.4, to no
avail -- in fact, it seems no one even thinks this is a bug.

to me, it is pretty clear that hitting MAX_INIT_ENVS _or_ MAX_INIT_ARGS
kills the parse_options loop, when that should not occur until both are
hit -- thus, this patch switches the breaks to continues.

thanks for noticing, I hope it is applied.

> --- linux-2.2.19-wt5-OE/init/main.c Sat Sep 8 23:11:00 2001
> +++ linux-2.2.19-wt5-OF/init/main.c Sat Sep 8 23:24:13 2001
> @@ -1292,11 +1292,11 @@
> */
> if (strchr(line,'=')) {
> if (envs >= MAX_INIT_ENVS)
> - break;
> + continue;
> envp_init[++envs] = line;
> } else {
> if (args >= MAX_INIT_ARGS)
> - break;
> + continue;
> argv_init[++args] = line;
> }
> }

--
Robert M. Love
rml at ufl.edu
rml at tech9.net

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:03    [W:0.044 / U:0.396 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site