From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19007 invoked by alias); 24 Dec 2014 01:56:20 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 18405 invoked by uid 89); 24 Dec 2014 01:56:15 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.1 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-vc0-f177.google.com Received: from mail-vc0-f177.google.com (HELO mail-vc0-f177.google.com) (209.85.220.177) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Wed, 24 Dec 2014 01:56:14 +0000 Received: by mail-vc0-f177.google.com with SMTP id ij19so2653584vcb.22 for ; Tue, 23 Dec 2014 17:56:11 -0800 (PST) MIME-Version: 1.0 X-Received: by 10.220.5.72 with SMTP id 8mr12215599vcu.6.1419386171450; Tue, 23 Dec 2014 17:56:11 -0800 (PST) Received: by 10.52.7.134 with HTTP; Tue, 23 Dec 2014 17:56:11 -0800 (PST) In-Reply-To: References: Date: Wed, 24 Dec 2014 01:56:00 -0000 Message-ID: Subject: Re: Exitcode is 0 when killing a cygwin initiated process via taskmanager From: - To: marco@gmail.com, cygwin@cygwin.com, Anr Daemon , cygsimple@gmail.com Content-Type: text/plain; charset=UTF-8 X-SW-Source: 2014-12/txt/msg00351.txt.bz2 >> If it is similar in GNU/Linux we have a general problem I suppose. If it is a cygwin >> thing, it is a feature which behaves different to the real posix world?! > Cygwin is a POSIX environment executing within the Windows OS environment. > If things happen outside of the Cygwin environment it cannot detect those. > You must train your users to not use the Windows Task Manager to kill the process outside of the Cygwin environment. > The problem does not exist in Linux because there isn't an environment inside an environment so there isn't a chance > to use the tools improperly. Ok I wrote a wrapper and check stdout of critical commands. If I get returnvalue 0 but not expectet stdout I panic. As far as my critical part is rsync that is a safe bet (there is a nice footer when rsync was not interrupted). As far as robustness is concerned I must say I am happy having found this edge very early. What do you think is that topic worth an entry in FAQ/Documentation? On the other hand this thread will be found through google search... Thanks again for being supportive and all your work! lopiuh keywords: cygwin returnvalue errorcode taskmanager exitcode process kill end continue zero errorvalue unset -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple