delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2007/08/28/14:04:59

X-Spam-Check-By: sourceware.org
Date: Tue, 28 Aug 2007 14:04:00 -0400
From: Christopher Faylor <cgf-use-the-mailinglist-please AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: openssh not reporting the correct errorlevel
Message-ID: <20070828180400.GA15294@ednor.casa.cgf.cx>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <20070827115523 DOT AWF95381 AT mp6 DOT mc DOT surewest DOT net> <fb0i9v$s3m$1 AT sea DOT gmane DOT org> <31b7d2790708281001s6ccd5e4bx85a9aee3bbcf3c9d AT mail DOT gmail DOT com> <003a01c7e997$96f99120$2e08a8c0 AT CAM DOT ARTIMI DOT COM>
MIME-Version: 1.0
In-Reply-To: <003a01c7e997$96f99120$2e08a8c0@CAM.ARTIMI.COM>
User-Agent: Mutt/1.5.16 (2007-06-09)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On Tue, Aug 28, 2007 at 06:19:28PM +0100, Dave Korn wrote:
>On 28 August 2007 18:02, DePriest, Jason R. wrote:
>
>>> *  (Mon, 27 Aug 2007 11:55:23 -0700 (PDT))
>>>> Here are the command sequence I ran on Windows 2003 x86 SP2 servers (delhi
>>>> is the hostname) C:\>ssh delhi net The syntax of this command is:
>>>> 
>>>> NET [ ACCOUNTS | COMPUTER | CONFIG | CONTINUE | FILE | GROUP | HELP |
>>>>       HELPMSG | LOCALGROUP | NAME | PAUSE | PRINT | SEND | SESSION |
>>>>       SHARE | START | STATISTICS | STOP | TIME | USE | USER | VIEW ]
>>>> 
>>>> 
>>>> C:\>echo %errorlevel%
>>>> 0
>>>> 
>>>> ANALYSIS:
>>>> The errorlevel returned from the second command should be "1"
>>>> instead of "0".
>
>> The command entered looks correct to me.
>> 
>> He is connecting to remote host 'delhi' using ssh and executing the
>> 'net' command on 'delhi' which correctly outputs its usage
>> information.  Ssh then disconnects and returns him to the local
>> system.
>
>  I spent some time trying to reproduce this with various combinations of linux
>and windows servers, native win32 and cygwin commmands being run at the remote
>end when windows, etc., etc., and I couldn't find any way to reproduce it.
>Absolutely everything WJFFM, including the original example:

That's why we need cygcheck output.  If this is an older version of cygwin1.dll
then there was a problem with the reporting of error codes from non-cygwin apps.

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/

- Raw text -


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