From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alex Harsanyi Newsgroups: gmane.emacs.devel Subject: "resource temporarily unavailable" errors on windows 7 Date: Mon, 12 Mar 2012 12:56:13 +0800 Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: dough.gmane.org 1331528185 32040 80.91.229.3 (12 Mar 2012 04:56:25 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 12 Mar 2012 04:56:25 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Mar 12 05:56:24 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1S6xJ0-0008Oa-6A for ged-emacs-devel@m.gmane.org; Mon, 12 Mar 2012 05:56:22 +0100 Original-Received: from localhost ([::1]:48082 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S6xIz-0005rv-Kx for ged-emacs-devel@m.gmane.org; Mon, 12 Mar 2012 00:56:21 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:35454) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S6xIw-0005rq-Id for emacs-devel@gnu.org; Mon, 12 Mar 2012 00:56:19 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1S6xIu-0001Ld-Ju for emacs-devel@gnu.org; Mon, 12 Mar 2012 00:56:18 -0400 Original-Received: from mail-we0-f169.google.com ([74.125.82.169]:59320) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S6xIu-0001L4-Af for emacs-devel@gnu.org; Mon, 12 Mar 2012 00:56:16 -0400 Original-Received: by werj55 with SMTP id j55so3557479wer.0 for ; Sun, 11 Mar 2012 21:56:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=reZ+5O1065mit+En0H3ThhTH7UQu/gNcOycA7OJVxpA=; b=p2Ta6Q+0dqgLj7c+F1rEneI/iVaoXGi2xq7ZMhAQWTOfbU4T6K9LZwGXGBViaDyqy4 cct9KRqKQ5vSKSChIJKJpXQEVTsQWMr4xQzhs8l0TvG+S4UCGrgGIrNLaN9xVGd4h80f zKG6cnb3pd91KFmIoZMJ0ukXdxd7v7I/myc1UfGSzF1y+9uga5yY4ns5PJbRlm57q54c Y5AiBfLun1gb8Uny9ukIWpw3LRXaPSBQWZ3Ogi5s154E30sNC8J35j2e5kV+h9LW3WDi wxsXBH7k5ggJwfT0sQEwq3Rj9bPeYpuelhBZYoY2baW8Xg5MhiV22kWsVdu8E4exMPD+ +OFA== Original-Received: by 10.216.143.209 with SMTP id l59mr320474wej.87.1331528173421; Sun, 11 Mar 2012 21:56:13 -0700 (PDT) Original-Received: by 10.223.64.212 with HTTP; Sun, 11 Mar 2012 21:56:13 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 74.125.82.169 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:148967 Archived-At: I keep encountering the following error each time I try to start a subprocess under emacs: File error: Spawning child process, resource temporarily unavailable This happens on Windows 7, 32 bit with the prebuilt binaries versions 23.4, 24.0.93 and 24.0.94 but *not* with Emacs 23.3. It happens when launching all kinds of sub-processes (compilation commands, version control commands, diff, aspell, bash, etc). It also happens on two other colleagues computers, also running Windows 7, 32 bit. If I set the Windows XP compatibility flag on emacs.exe, the problem goes away, but makes Emacs unusable for me, since the programs I need to run do not work when the compatibility mode is set. I run a diff between Emacs 23.3 and 23.4 and identified that a new allocate_heap() function was added in 23.4. If I remove the function, falling back on the one used in 23.3 than I no longer get the above error. (I attached a patch to show which function I talk about, not to suggest removing the function). Should this version of allocate_heap() be used on a Windows 7, 32 bit platform? Alex. diff -up --tabsize=4 c\:/emacs-24.0.94/src/w32heap.c\~ c\:/emacs-24.0.94/src/w32heap.c --- c:/emacs-24.0.94/src/w32heap.c~ 2012-02-14 00:13:25.000000000 +0800 +++ c:/emacs-24.0.94/src/w32heap.c 2012-03-02 10:38:51.591246600 +0800 @@ -114,7 +114,6 @@ get_data_end (void) return data_region_end; } -#if !defined (USE_LISP_UNION_TYPE) && !defined (USE_LSB_TAG) static char * allocate_heap (void) { @@ -141,27 +140,6 @@ allocate_heap (void) return ptr; } -#else /* USE_LISP_UNION_TYPE || USE_LSB_TAG */ -static char * -allocate_heap (void) -{ - unsigned long size = 0x80000000; /* start by asking for 2GB */ - void *ptr = NULL; - - while (!ptr && size > 0x00100000) - { - reserved_heap_size = size; - ptr = VirtualAlloc (NULL, - get_reserved_heap_size (), - MEM_RESERVE, - PAGE_NOACCESS); - size -= 0x00800000; /* if failed, decrease request by 8MB */ - } - - return ptr; -} -#endif /* USE_LISP_UNION_TYPE || USE_LSB_TAG */ - /* Emulate Unix sbrk. Note that ralloc.c expects the return value to be the address of the _start_ (not end) of the new block in case of Diff finished. Mon Mar 12 07:47:19 2012