delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/03/12/05:49:22

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Date: Mon, 12 Mar 2001 05:43:27 -0500
From: Chet Ramey <chet AT nike DOT ins DOT cwru DOT edu>
To: ralf AT akutech DOT de
Subject: Re: different behaviour of bash and sh
Cc: bug-bash AT gnu DOT org, cygwin AT cygwin DOT com, chet AT po DOT cwru DOT edu
Reply-To: chet AT po DOT cwru DOT edu
Message-ID: <1010312104327.AA84634.SM@nike.ins.cwru.edu>
Read-Receipt-To: chet AT po DOT CWRU DOT Edu
MIME-Version: 1.0
X-In-Reply-To: Message from ralf AT akutech DOT de of Thu, 8 Mar 2001 21:16:48 +0100 (id <15015 DOT 59568 DOT 965521 DOT 675165 AT jupiter DOT akutech-local DOT de>)
X-In-Reply-To: Message from ralf AT akutech DOT de of Thu, 8 Mar 2001 21:16:48 +0100 (id <15015 DOT 59568 DOT 965521 DOT 675165 AT jupiter DOT akutech-local DOT de>)

> Machine Type: i686-pc-cygwin
> 
> Bash Version: 2.04
> Patch Level: 7
> Release Status: release
> 
> Description:
> The following script behaves differently in bash and sh:
> 
>     % cat script
>     #!/bin/sh --
>     checkstat() {
> 	echo $?
>     }
>     false
>     checkstat
>     # End of file
> 
> Repeat-By:
> 
>     $ type bash
>     bash is /usr/bin/bash
>     $ bash script
>     1
>     $ type sh
>     sh is /usr/bin/sh
>     $ sh script
>     0
> 
> The 0 is wrong IMHO, it should be 1.  (Even HP with their BD-/bin/sh
> returns 1).

You're reporting a bug in the cygwin sh, not bash.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
( ``Discere est Dolere'' -- chet)

Chet Ramey, CWRU    chet AT po DOT CWRU DOT Edu    http://cnswww.cns.cwru.edu/~chet/

--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019