On Friday 28 September 2007 03:49, Loïc Grenié wrote:
> The if () test is useless because it has already been done above.
if (flags & (PSSCAN_CMD|PSSCAN_ARGV0)) {
if (sp->argv0) {
free(sp->argv0);
sp->argv0 = NULL;
}
if (sp->cmd) {
free(sp->cmd);
sp->cmd = NULL;
}
strcpy(filename_tail, "/cmdline");
/* TODO: to get rid of size limits, read into malloc
buf,
* then realloc it down to real size. */
n = read_to_buf(filename, buf);
if (n <= 0)
break;
if (flags & PSSCAN_ARGV0)
sp->argv0 = xstrdup(buf);
I do not see why (flags & PSSCAN_ARGV0) is true in last if().
--
vda
_______________________________________________
busybox mailing list
[email protected]
http://busybox.net/cgi-bin/mailman/listinfo/busybox