www.delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-SWARE-Spam-Status: | No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,SPF_PASS |
X-Spam-Check-By: | sourceware.org |
Message-ID: | <4AF29EC2.2050808@users.sourceforge.net> |
Date: | Thu, 05 Nov 2009 03:45:38 -0600 |
From: | "Yaakov (Cygwin/X)" <yselkowitz AT users DOT sourceforge DOT net> |
User-Agent: | Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.4pre) Gecko/20090915 Thunderbird/3.0b4 |
MIME-Version: | 1.0 |
To: | cygwin AT cygwin DOT com |
Subject: | malloc overrides |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.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 |
GraphViz uses iffe tests to determine system capabilities. Two tests, however, hang and require manual intervention to kill them and continue. These are the culprits: ####### start code 1 ####### /* Are we stuck with standard malloc? */ extern void _exit (int); extern char* strdup (const char*); char* malloc(unsigned n) { _exit(0); return 0; } int main(void) { strdup("yo"); _exit(1); } ####### end code 1 ####### ####### start code 2 ####### /* Is alloca is based on malloc()? */ #include <alloca.h> void* malloc(unsigned int size) { exit(0); return 0; } int main(void) { alloca(10); return 1; } ####### end code 1 ####### In both cases, the program hangs and needs to be forcefully killed through Windows' taskmgr. On Linux, these run quickly and return 0 and 1, respectively. Is this a problem with the code, or is this a bug or limitation in Cygwin? Yaakov -- 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
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |