From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from conssluserg-02.nifty.com (conssluserg-02.nifty.com [210.131.2.81]) by sourceware.org (Postfix) with ESMTPS id E4A813858D20 for ; Thu, 4 May 2023 21:59:59 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org E4A813858D20 Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=nifty.ne.jp Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=nifty.ne.jp Received: from HP-Z230 (aj135041.dynamic.ppp.asahi-net.or.jp [220.150.135.41]) (authenticated) by conssluserg-02.nifty.com with ESMTP id 344LxgSP029385 for ; Fri, 5 May 2023 06:59:43 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-02.nifty.com 344LxgSP029385 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.ne.jp; s=dec2015msa; t=1683237583; bh=iu0DJR1l/6o4UHJ/TGmwAZbtkN2OzYDZQKYGK+sj+r0=; h=Date:From:To:Subject:In-Reply-To:References:From; b=zykPsMm7oDeL+40JbAc1/MyluJPHlUQZC+FSk6BoaN7v81/2s+r7YlfEPB5jBhEkK x0VeoPS3gGWySgpPxUf/vCvfyu7LhLs+1cmmAPhNdIWyYuoTcxGf9Zg1tEq85hgEP7 8fjXqIUva7i9odhySIzXWoD6zLob7xgiloBv8C3oc6slLFNs+J548jp1zKfEvTYbXu Qf7QMtkypoFJzMdDJpVv/383v+i5v0PMD7adAKhBZ/rgWV5XtfcXf5MQA1NutOM1p8 Hr7fWcgbJmh/v05WtkkhmPH2Laqp/77pBiNOkFnaXVTFhb0EWRee9Q72UE32p55zSt NwrysNaxT/Z+A== X-Nifty-SrcIP: [220.150.135.41] Date: Fri, 5 May 2023 06:59:43 +0900 From: Takashi Yano To: cygwin-developers@cygwin.com Subject: Re: stdin, stdout, stderr when GUI app is launched from command line Message-Id: <20230505065943.01a0d61c6e4d96a6fb5047b6@nifty.ne.jp> In-Reply-To: References: X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.30; i686-pc-mingw32) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-6.2 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Thu, 4 May 2023 15:10:03 +0000 "Kacvinsky, Tom" wrote: > I have a Windows GUI app that I have set to run with Windows Application Verifier. > In particular, I have App verifier set to trigger on invalid handle exceptions (code is > 0xC0000008). When the application is run from the Cygwin console, it faults with > an invalid handle three times. I can continue past them in windbg (or gdb for that > matter) and the application launches. I think it is curious the invalid handle exception > occurs three times - is it stdin, stdout and stderr that App Verifier thinks are invalid > handles? My hunch is yes, they are. > > I did notice that if I run the GUI use run.exe, as in "run guiapp.exe", the application > launches with no invalid handle exceptions. > > I am using this version of Cygwin 64 > > vapkay@US05117NB ~ $ cygcheck -V > cygcheck (cygwin) 3.1.7 > > But it also happens with 3.4.6 > > Is this to be expected with a GUI app when run under a Cygwin console? I've never > seen it until I ran with App Verifier. The GUI application is a Qt app. I check the Qt > version we're using for use of and I don't see anything in the WinMain what would > have to do with reading/writing to the standard IO file descriptors. > > Any ideas? I cannot reproduce your problem with cygwin 3.4.6. Could you please provide detailed steps? -- Takashi Yano