X-Spam-Check-By: sourceware.org Message-ID: <45DF280A.7070907@swipnet.se> Date: Fri, 23 Feb 2007 18:44:42 +0100 From: =?UTF-8?B?SmFuIERqw6Rydg==?= User-Agent: Thunderbird 1.5.0.9 (X11/20070103) MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: FW: Re: [emacs_user AT hotmail DOT com: ***MEMORY-ERROR***: emacs[5172]: GSlice: failed References: <45D9678E DOT 7090108 AT swipnet DOT se> <45DA98EF DOT 6040205 AT swipnet DOT se> <45DB2A13 DOT 6070606 AT swipnet DOT se> <45DC1AAD DOT 5050109 AT swipnet DOT se> <45DD3F89 DOT 60400 AT swipnet DOT se> <45DE9352 DOT 5070706 AT swipnet DOT se> In-Reply-To: <45DE9352.5070706@swipnet.se> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 Larry Hall wrote: > Jan DjÃrv wrote: > > Yes it does thanks for the explanation. Cygwin has some mechanism that makes > it possible for a program to supply its own malloc/free and friends I think > (malloc_wrapper.cc). Would it be hard to also handle memalign/valloc and > later posix_memalign in the same fashion? > > > > It already handles memalign/valloc. Are you talking about the released cygwin version? It does not handle malloc the same as memalign, I see in malloc_wrapper.c: extern "C" void * malloc (size_t size) { void *res; export_malloc_called = 1; if (!use_internal_malloc) res = user_data->malloc (size); else ... and extern "C" void * memalign (size_t alignment, size_t bytes) { void *res; if (!use_internal_malloc) { set_errno (ENOSYS); res = NULL; } > > > Would I be correct in assuming that such an addition would make glib call the > Emacs versions? > > > > I suppose. But if Emacs is modular enough to provide its calls as a > (import) library or object file, you can just list this on the link line > after glib and get the same affect for Emacs/glib. This may be easier > for you. That would have to come from someone that cares alot about Emacs + Gtk+ on cygwin. I'm just trying to find a simple solution, as it seems now, we will disable Gtk+ on cygwin. BTW, I tried to put to put the object file that contain malloc/memalign after the Gtk+ libraries, and it didn't work. Glib does not call the Emacs supplied memalign in this case either. Jan D. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/