From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ej1-x633.google.com (mail-ej1-x633.google.com [IPv6:2a00:1450:4864:20::633]) by sourceware.org (Postfix) with ESMTPS id 84658385481D for ; Fri, 13 Nov 2020 17:28:11 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 84658385481D Received: by mail-ej1-x633.google.com with SMTP id w13so14563616eju.13 for ; Fri, 13 Nov 2020 09:28:11 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=qXL/b8lD+EmO3xl1DJy2Jx8m+jcuRbWDcX7l98uSzmM=; b=AlcRCBEXFfgObYQGNCUO4T0hozZTOFbF0lKCZI+5TOt9AHNiQYfmmGiDEiz0CXvnJj a+DnYByBdK8X71CXWRk4ccOl9kK0kextMBiTGa8Ylbfuiam4krtul1+Oda0IFVu4GTP6 rOmiY2f5O+ZIOGrHfPaykaIPBxuxeINWbrKkBcKEO4DrOJLx29TXWuN6bCd2zQLSz38l 61B+0H56z3mYAIvYEZwrEz9V/cC3kpVVs7rCyKCPMesqMTWHzbthKVsergw+rCvg4Kcj LySpBfVSkY4ZEDuwwTKcOT0BUDljhwGIn9fV4pF3yLl6qMllEmSOCRTArmGKVDs453Vn 8Vfg== X-Gm-Message-State: AOAM531vZgYgAa4iEDOHTtECETggKeHoXiGwa+erkzt8GYiyWEVGs8G6 SgcHgpjW4lJS2zmXWwuxRBc+2wtWMezu/KqEVP+HuBE6RwVeiA== X-Google-Smtp-Source: ABdhPJz8F1LBbxr+MblvH3J9vEsWl+D08oj6XZV5kxJjWf8W2foWHrg/LpCNN11TffS0g1UJv5qYSA65V1VQE2ckVKM= X-Received: by 2002:a17:906:3a8d:: with SMTP id y13mr3093482ejd.460.1605288487836; Fri, 13 Nov 2020 09:28:07 -0800 (PST) MIME-Version: 1.0 From: "William M. (Mike) Miller" Date: Fri, 13 Nov 2020 12:27:57 -0500 Message-ID: Subject: Failed assertion dialog box To: The Cygwin Mailing List X-Spam-Status: No, score=-2.2 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, HTML_MESSAGE, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: cygwin@cygwin.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: General Cygwin discussions and problem reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 13 Nov 2020 17:28:12 -0000 I've run into a problem running a collection of tests under Cygwin and I wonder if anyone can suggest a way around it. The problem occurs when a program being run fails a C/C++ runtime assertion. Ordinarily, this just writes an error message on stderr and aborts. Under Cygwin, however, if both stdin and stderr are redirected to files, the program instead pops up a dialog box that must be interactively dismissed before the failed program will exit - holding up all the tests that follow it. Specifically, if I have the following as assert.cpp: #include int main() { assert(false); } and say gcc assert.cpp ./a.exe < /dev/null > output 2>&1 I get an error dialog box saying Failed assertion false at line 3 of file assert.cpp in function int main() If I omit either the stdin or the stderr redirection, the program behaves as desired with no dialog box. Is there an environment setting or compiler command-line option I can give to suppress the dialog box and always just write a message to stderr and abort? Thanks for any insights. -- William M. (Mike) Miller | Edison Design Group william.m.miller@gmail.com