all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
To: Chong Yidong <cyd@stupidchicken.com>
Cc: "İsmail Dönmez" <ismail@namtrac.org>, emacs-devel@gnu.org
Subject: Re: [PATCH] XCloseDisplay already calls XrmDestroyDatabase
Date: Wed, 13 May 2009 12:27:01 +0900	[thread overview]
Message-ID: <wlws8lr8ca.wl%mituharu@math.s.chiba-u.ac.jp> (raw)
In-Reply-To: <87k5eataqu.fsf@cyd.mit.edu>

>>>>> On Thu, 21 Aug 2008 15:43:21 -0400, Chong Yidong <cyd@stupidchicken.com> said:

> "İsmail Dönmez" <ismail@namtrac.org> writes:
>>>> So looks like there is no need to manually call
>>>> XrmDestroyDatabase() anymore, attached patch removes it.
>>> 
>>> Actually correct solution is to disable XrmDestroyDatabase() call
>>> for GTK+ as done for Xt. See attached patch.
>> 
>> Any comments on this? It fixes a frequent crash for me.

> I've checked in the patch.  Thanks.

I tried reverting it, but I couldn't reproduce the crash using the
procedure in Bug#581 with Ubuntu 9.04, GTK+ build.  I also tried
setting a breakpoint to XrmDestroyDatabase, but I couldn't observe its
call from XCloseDisplay on closing an X11 display.  On the other hand,
Bug#1812 says the similar crash happens even without X toolkit on Mac
OS X 10.4.  The same binary does not crash on Mac OS X 10.5.

I think necessity of the XrmDestroyDatabase call depends on which
version of libX11 is used rather than whether GTK+ is used or not.
The relevant change in libX11 would be:

  http://lists.freedesktop.org/archives/xorg-commit-diffs/2004-March/000239.html

I confirmed that the libX11 shipped with Mac OS X 10.4 doesn't contain
the above change.

  http://www.opensource.apple.com/source/X11/X11-0.46.4/xc/lib/X11/

If we remove the XrmDestroyDatabase call unconditionally, then it
causes a memory leak when used with a newer libX11.  But that would be
better than crashing when used with an older one.

				     YAMAMOTO Mitsuharu
				mituharu@math.s.chiba-u.ac.jp




  parent reply	other threads:[~2009-05-13  3:27 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-19 10:19 [PATCH] XCloseDisplay already calls XrmDestroyDatabase İsmail Dönmez
2008-08-20  8:17 ` İsmail Dönmez
2008-08-21 18:40   ` İsmail Dönmez
2008-08-21 19:43     ` Chong Yidong
2008-07-20 20:51       ` bug#581: 23.0.60; OSX: server crashes when quitting emacsclient Markus Triska
     [not found]         ` <handler.581.B.121658711315039.ack@emacsbugs.donarmstrong.com>
2008-08-08 12:08           ` bug#581: Acknowledgement (23.0.60; OSX: server crashes when quitting emacsclient) Markus Triska
2008-08-09  1:02             ` OFFICE ZERO
2008-08-09 14:12             ` OFFICE ZERO
2008-08-21 19:50         ` bug#581: marked as done " Emacs bug Tracking System
2009-05-13  3:27       ` YAMAMOTO Mitsuharu [this message]
2009-05-13 23:48         ` [PATCH] XCloseDisplay already calls XrmDestroyDatabase YAMAMOTO Mitsuharu
2009-05-17 21:40           ` Stefan Monnier
2009-05-18  8:09             ` YAMAMOTO Mitsuharu
2009-05-18 13:29               ` Chong Yidong
2009-05-17 21:40         ` Stefan Monnier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=wlws8lr8ca.wl%mituharu@math.s.chiba-u.ac.jp \
    --to=mituharu@math.s.chiba-u.ac.jp \
    --cc=cyd@stupidchicken.com \
    --cc=emacs-devel@gnu.org \
    --cc=ismail@namtrac.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.