Mailing-List: contact cygwin-help@sourceware.cygnus.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@sources.redhat.com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin@sources.redhat.com>
List-Help: <mailto:cygwin-help@sources.redhat.com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner@sources.redhat.com
Delivered-To: mailing list cygwin@sources.redhat.com
Message-ID: <3BCEF347.31A0D7D8@syntrex.com>
Date: Thu, 18 Oct 2001 17:20:39 +0200
From: Pavel Tsekov <ptsekov@syntrex.com>
Organization: Syntrex Inc.
X-Mailer: Mozilla 4.76 [en] (X11; U; Linux 2.4.2-2 i686)
X-Accept-Language: en
MIME-Version: 1.0
To: cygwin@cygwin.com
Subject: [Fwd: simple execvp test]
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Pavel Tsekov wrote:
> 
> This mail is inspired by an offlist discussion
> with James Lee about vi execution before
> "cvs commit" command.
> 
> Given the following simple test he says nothing
> happens after he executes it, as happens with the
> "cvs commit" command which fails to execute vi
> with the following error code "cannot exec vi: No such file or
> directory".
> 
> #include <unistd.h>
> 
> int main()
> {
>   char *arg[] = {
>     0
>   };
> 
>   execvp("vi", arg);
> 
>   return 0;
> }
> 
> If he sets for example the EDITOR variable
> to /usr/bin/vi then cvs suceeds in executing
> vi.
> 
> So is this a known problem with execvp assuming
> that it should search the path for the executable.

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

