Date: Thu, 22 Aug 2002 19:54:22 +0300 From: "Eli Zaretskii" Sender: halo1 AT zahav DOT net DOT il To: taupind AT wanadoo DOT fr Message-Id: <2950-Thu22Aug2002195421+0300-eliz@is.elta.co.il> X-Mailer: emacs 21.3.50 (via feedmail 8 I) and Blat ver 1.8.9 CC: djgpp AT delorie DOT com In-reply-to: <3D64F835.A0BC04FF@wanadoo.fr> (message from Daniel Taupin on Thu, 22 Aug 2002 16:41:57 +0200) Subject: Re: Zero-th argument NOT with long name! References: <3D64E2A7 DOT 53133408 AT wanadoo DOT fr> <2110-Thu22Aug2002172350+0300-eliz AT is DOT elta DOT co DOT il> <3D64F835 DOT A0BC04FF AT wanadoo DOT fr> Reply-To: djgpp AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk > Date: Thu, 22 Aug 2002 16:41:57 +0200 > From: Daniel Taupin > > > > > Is there a means of getting the full long name of a program, inside its > > > execution? > > > > Yes, pass argv[0] to the library function _truename and use the result > > it returns. > > That's exactly what I wanted. Is the calling sequence > _truename(the_argv[0] string)? No, it's _truename(argv[0], lfn_name) where lfn_name is a string long enough to store 260 characters. See the docs of _truename for more information (it's in libc.info).