X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:date:message-id:mime-version :content-type:content-transfer-encoding; q=dns; s=default; b=kAt o9FT6elijPffRp4z+8pY1LN9xZWedLYjdx5UDyGTT4A8Io31uoX0Lq5bKzkrhlvR FnuWoSPXs0D1GfFvMx7k+2WNgqsWs3zTu+34Kx456LG/GmjGyH+XVhQ0+C2DrZHs vwZPV4D13xjNKH2HYNkQMHY3rDSufM5fSrP8WBJo= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:date:message-id:mime-version :content-type:content-transfer-encoding; s=default; bh=acJfaR5d4 30iJmAxbayRl3ZxSPc=; b=ULeaw35siM7Zbblb1AmAE04z4LkSiPcHEXL4iqz2k 3lMX6NdLeofs0X7WGZdM2+wQtvGaJokKapvOt9l4JTrhWbnEHfBJn528G4KWDdOX OT+unrsb6BDhuFSracZFiiDmAwkL95D+2qvlSZc4dcnwhEOKHGPyEW+2OSSeL09R Ao= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: 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 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=1.4 required=5.0 tests=AWL,BAYES_50,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_SPAM,SPF_PASS autolearn=no version=3.3.2 spammy=H*x:14.0, UD:bash.exe, bash.exe, bashexe X-HELO: mail-yw0-f194.google.com X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :content-transfer-encoding:thread-index:content-language; bh=MqNGJagpcYg9HjfTbSCXReE2jMZ0ADHKiBM0OY/WieU=; b=Zp18yAn5G36pOlMJeNzDdUMsVCJGO/IktJ8R5bdirz771jHD5RjGepYx3fYfP6gyui o7GU9xci2M5xwFG+O+yvRknHtxooBX2D390GIpTSRYeO9ZR+6SZ/p9n+6hAeWcIGZOff 0MR9wkxr6nHbr+cg0VBE8jZRMculzRobhMP3PwqlAOOovXyMHNVMN4zvDstftUS4PYXf y+TWCX+V1JRBKeVgHW9n6a/YUFpb67wIoPpU1vPpAT8ECE0GcbRjqnmh9v9L0l1wwtWt h14++6sc3fILnXWjSu87hp2wiknVrxSKTXIQGAgoJvSbVTPPjTtTKwiPnt9M7IrJNkqc 8QEA== X-Gm-Message-State: AODbwcCw1cR8pMRgwD2abeNqNEVebv4U0rMo24VTNVMKWLWuIbEs4Gno OvnFMH+MT3hPNOt3WdTbdA== X-Received: by 10.13.236.206 with SMTP id v197mr6614427ywe.296.1494668562313; Sat, 13 May 2017 02:42:42 -0700 (PDT) From: "Brien Oberstein" To: Subject: Ctrl-Break killing subprocess even though handled in parent process Date: Sat, 13 May 2017 05:42:41 -0400 Message-ID: <006701d2cbcd$444459b0$cccd0d10$@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit x-ms-exchange-organization-originalclientipaddress: 192.168.91.98 x-ms-exchange-organization-originalserveripaddress: 192.168.91.99 Hi, I have a dotnet windows console application that runs a bash script as a subprocess using CreateProcess() under the covers. My windows app traps Ctrl-Break via SetConsoleCtrlHandler() and handles it (returning true from the handler). I execute the script via the command "bash.exe --login script.sh". Somehow the Ctrl-Break is reaching the subprocess and causing it to be killed, which is undesireable. Is there a way to either prevent the Ctrl-Break from reaching the cygwin subprocess or telling cygwin/bash to ignore it? Thanks, Brien -- 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