Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Date: Sun, 30 Jan 2005 15:29:16 -0500 From: Christopher Faylor To: cygwin AT cygwin DOT com Subject: Re: Cygwin not passing return code to Windows? Message-ID: <20050130202916.GA13214@trixie.casa.cgf.cx> Reply-To: cygwin AT cygwin DOT com References: <011601c50707$21c21460$05010e0a AT 2mbit DOT com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <011601c50707$21c21460$05010e0a@2mbit.com> User-Agent: Mutt/1.4.1i Note-from-DJ: This may be spam On Sun, Jan 30, 2005 at 03:06:03PM -0500, Brian Bruns wrote: >Up until Cygwin 1.5.12, the return code from stuff like clamscan was >being passed back to Windows, so programs outside of Cygwin could call >the binary and tell weather or not the program found a virus in the >file it scanned. > >Now, in the latest snapshots, that is no longer the case. See example >below using freshclam, but also applies to the other apps: The odd error return was unintentional but there will be a change in cygwin 1.5.13 -- the error return will match what you'd expect for a unix program. So, this is what you should expect: c:\>sh -c 'exit 1' c:\>echo %errorlevel% 256 This will be the behavior of the next snapshot. cgf -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/