[BusyBox] Re: [patch] Why busybox xargs is broken.
Vladimir N. Oleynik
dzo at simtreas.ru
Fri Oct 3 11:11:47 UTC 2003
Glenn,
> echo "one" | xargs grep -i fred
>
> -i is a grep option, not xargs option, this is currently broken in
> busybox xargs.
>
> Im working on an alternative patch, first part of which is.
>
> + int argc_xargs;
> +
> + /* Determine how many arguments are for xargs */
> + for (argc_xargs = 1; argv[argc_xargs] && argv[argc_xargs][0] == '-'; argc_xargs++);
>
> bb_opt_complementaly = "pt";
> - a = bb_getopt_ulflags(argc, argv, "tpr");
> + a = bb_getopt_ulflags(argc_xargs, argv, "tpr");
GNU extension is same effect:
a = bb_getopt_ulflags(argc, argv, "+tpr");
--w
vodz
More information about the busybox
mailing list