[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] trunk r113247: Fix bug re noninteractive multithreaded mem
From: |
Paul Eggert |
Subject: |
[Emacs-diffs] trunk r113247: Fix bug re noninteractive multithreaded memory allocation. |
Date: |
Mon, 01 Jul 2013 21:06:17 +0000 |
User-agent: |
Bazaar (2.6b2) |
------------------------------------------------------------
revno: 113247
revision-id: address@hidden
parent: address@hidden
fixes bug: http://debbugs.gnu.org/14569
committer: Paul Eggert <address@hidden>
branch nick: trunk
timestamp: Mon 2013-07-01 14:06:12 -0700
message:
Fix bug re noninteractive multithreaded memory allocation.
* emacs.c (malloc_enable_thread): Hoist extern decl to top level.
(main) [HAVE_PTHREAD && !SYSTEM_MALLOC && !DOUG_LEA_MALLOC]:
Invoke malloc_enable_thread even when not interactive.
Problem reported by Ken Brown in <http://bugs.gnu.org/14569#275>.
* process.c (init_process_emacs) [CYGWIN]: Tickle glib even
in this case, since the underlying bug has now been fixed.
modified:
src/ChangeLog changelog-20091113204419-o5vbwnq5f7feedwu-1438
src/emacs.c emacs.c-20091113204419-o5vbwnq5f7feedwu-241
src/process.c process.c-20091113204419-o5vbwnq5f7feedwu-462
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog 2013-07-01 16:54:37 +0000
+++ b/src/ChangeLog 2013-07-01 21:06:12 +0000
@@ -1,3 +1,13 @@
+2013-07-01 Paul Eggert <address@hidden>
+
+ Fix bug re noninteractive multithreaded memory allocation (Bug#14569).
+ * emacs.c (malloc_enable_thread): Hoist extern decl to top level.
+ (main) [HAVE_PTHREAD && !SYSTEM_MALLOC && !DOUG_LEA_MALLOC]:
+ Invoke malloc_enable_thread even when not interactive.
+ Problem reported by Ken Brown in <http://bugs.gnu.org/14569#275>.
+ * process.c (init_process_emacs) [CYGWIN]: Tickle glib even
+ in this case, since the underlying bug has now been fixed.
+
2013-07-01 Juanma Barranquero <address@hidden>
* emacs.c (Fkill_emacs): Expand Vauto_save_list_file_name before
=== modified file 'src/emacs.c'
--- a/src/emacs.c 2013-07-01 16:54:37 +0000
+++ b/src/emacs.c 2013-07-01 21:06:12 +0000
@@ -127,6 +127,8 @@
/* True if the MALLOC_CHECK_ environment variable was set while
dumping. Used to work around a bug in glibc's malloc. */
static bool malloc_using_checking;
+#elif defined HAVE_PTHREAD && !defined SYSTEM_MALLOC
+extern void malloc_enable_thread (void);
#endif
Lisp_Object Qfile_name_handler_alist;
@@ -1074,13 +1076,8 @@
#endif /* DOS_NT */
}
-#if defined (HAVE_PTHREAD) && !defined (SYSTEM_MALLOC) && !defined
(DOUG_LEA_MALLOC)
- if (! noninteractive)
- {
- extern void malloc_enable_thread (void);
-
- malloc_enable_thread ();
- }
+#if defined HAVE_PTHREAD && !defined SYSTEM_MALLOC && !defined DOUG_LEA_MALLOC
+ malloc_enable_thread ();
#endif
init_signals (dumping);
=== modified file 'src/process.c'
--- a/src/process.c 2013-06-27 14:47:52 +0000
+++ b/src/process.c 2013-07-01 21:06:12 +0000
@@ -7095,15 +7095,11 @@
if (! noninteractive || initialized)
#endif
{
-#if defined HAVE_GLIB && !defined WINDOWSNT && !defined CYGWIN
+#if defined HAVE_GLIB && !defined WINDOWSNT
/* Tickle glib's child-handling code. Ask glib to wait for Emacs itself;
this should always fail, but is enough to initialize glib's
- private SIGCHLD handler, allowing the code below to copy it into
- LIB_CHILD_HANDLER.
-
- For some reason tickling causes Cygwin bootstrap to fail, so it's
- skipped under Cygwin. FIXME: Skipping the tickling likely causes
- bugs in subprocess handling under Cygwin (Bug#14569). */
+ private SIGCHLD handler, allowing catch_child_signal to copy
+ it into lib_child_handler. */
g_source_unref (g_child_watch_source_new (getpid ()));
#endif
catch_child_signal ();
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] trunk r113247: Fix bug re noninteractive multithreaded memory allocation.,
Paul Eggert <=