No need. You can memcpy the environment. See setenv(3),
putenv(3) and related library routines.
Once you've parsed your argv who cares if you overwrite it,
put a double NULL at the end, set argc = 1 and argv[1] =
NULL. If argv[argc] - argv[0] + strlen(argv[argc] is
shorter than what you overwrite it with you won't even need
to relocate the environment block if you wish to preserve
that. Just don't leave any loose ends to confuse /proc and
the ps utils.
-- ________________________________________________________________ J.W. Schultz Pegasystems Technologies email address: jw@pegasys.wsRemember Cernan and Schmitt - 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/