Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!cmcl2!brl-adm!brl-smoke!gwyn From: gwyn@brl-smoke.ARPA (Doug Gwyn ) Newsgroups: comp.unix.wizards Subject: Re: Using argv to show process status Message-ID: <6303@brl-smoke.ARPA> Date: Thu, 20-Aug-87 16:38:32 EDT Article-I.D.: brl-smok.6303 Posted: Thu Aug 20 16:38:32 1987 Date-Received: Sat, 22-Aug-87 11:33:28 EDT References: <1217@mhres.mh.nl> Reply-To: gwyn@brl.arpa (Doug Gwyn (VLD/VMB) ) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 13 Keywords: argv ps In article <1217@mhres.mh.nl> jv@mhres.mh.nl (Johan Vromans) writes: >I have found out, that the process should execute something like > strcpy (argv[0], "Hi there, I'm doing fine."); Great if you really want to clobber other arguments and/or environment variables. argv[0] is a pointer to a string that was set up for you by the exec() system call, or at least by the C run-time startup module. There will not in general be enough room to hold a long string like that, so the strcpy() would overwrite other useful stuff as well. Why bother? Are you trying to run games on a system where you're not supposed to, or what?