From owner-freebsd-questions Sun May 14 14:53:47 2000 Delivered-To: freebsd-questions@freebsd.org Received: from mail2.x-treme.gr (mail2.x-treme.gr [212.120.196.24]) by hub.freebsd.org (Postfix) with ESMTP id B89C737B552 for ; Sun, 14 May 2000 14:53:40 -0700 (PDT) (envelope-from keramida@ceid.upatras.gr) Received: from hades.hell.gr (pat18.x-treme.gr [212.120.197.210]) by mail2.x-treme.gr (8.9.3/8.9.3/IPNG-ADV-ANTISPAM-0.2) with ESMTP id AAA23649; Mon, 15 May 2000 00:53:30 +0300 Received: (from charon@localhost) by hades.hell.gr (8.10.1/8.10.1) id e4EG1wC00488; Sun, 14 May 2000 19:01:58 +0300 (EEST) Date: Sun, 14 May 2000 19:01:58 +0300 From: Giorgos Keramidas To: Alex Kwan Cc: XF , freebsd-questions@FreeBSD.ORG Subject: Re: A basic question about C programming (sloved) Message-ID: <20000514190158.A448@hades.hell.gr> References: <000701bfbd9b$fd945300$591e40ca@alexkwan> <20000514131017.A801@dds.nl> <001701bfbd9d$eae8be60$591e40ca@alexkwan> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0.1i In-Reply-To: <001701bfbd9d$eae8be60$591e40ca@alexkwan>; from alexkwan@pacific.net.hk on Sun, May 14, 2000 at 08:14:12PM +0800 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Sun, May 14, 2000 at 08:14:12PM +0800, Alex Kwan wrote: > > Thank you! it is ok now, but why? > > > > I compile it with "cc -o inform inform.c", when the compilation is > > > finished, I have got the file "inform", but it can't execute and > > > got the error "inform: Command not found", What is the problem of > > > me? > > > > try ./inform Your PATH does not include the current working directory, if you do not add it there. For instance, on my machine I can see that: % echo $PATH /sbin:/bin:{lots of dirs trimmed}:~/bin But nowhere on the path can one find the `.' directory. You can always add the directory to your path, by adding to your .cshrc the following: set path = ( $path . ) But this is not a recommended way of solving the problem, since it creates various security issues, when you do it for the superuser. Just think of the good ol' trojan called /tmp/mroe and the following commands: # cd /tmp # ls -l | mroe Ciao, Giorgos. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message