From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Jason Rumney Newsgroups: gmane.emacs.bugs Subject: bug#3208: 23.0.93; Memory full / crash when displaying lots of characters from a large font (like Arial Unicode or Code2000) which is not explicitly selected (on Win32) Date: Mon, 22 Jun 2009 19:51:52 +0800 Message-ID: <4A3F7058.902@gnu.org> References: <49FF3340.2040008@gmx.de> <4A005A64.5050908@gnu.org> <4A3F1B05.7030105@gnu.org> Reply-To: Jason Rumney , 3208@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1245671928 20911 80.91.229.12 (22 Jun 2009 11:58:48 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 22 Jun 2009 11:58:48 +0000 (UTC) Cc: schierlm@gmx.de, 3208@emacsbugs.donarmstrong.com To: Kenichi Handa Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Jun 22 13:58:44 2009 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1MIiAe-0008Kp-4H for geb-bug-gnu-emacs@m.gmane.org; Mon, 22 Jun 2009 13:58:44 +0200 Original-Received: from localhost ([127.0.0.1]:52335 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MIiAd-0007Bp-Jk for geb-bug-gnu-emacs@m.gmane.org; Mon, 22 Jun 2009 07:58:43 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MIi9X-0006jr-WF for bug-gnu-emacs@gnu.org; Mon, 22 Jun 2009 07:57:36 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MIi9Q-0006es-A4 for bug-gnu-emacs@gnu.org; Mon, 22 Jun 2009 07:57:33 -0400 Original-Received: from [199.232.76.173] (port=35101 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MIi9P-0006ek-TA for bug-gnu-emacs@gnu.org; Mon, 22 Jun 2009 07:57:27 -0400 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:39686) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1MIi9O-0007tD-GS for bug-gnu-emacs@gnu.org; Mon, 22 Jun 2009 07:57:27 -0400 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id n5MBvMSr013719; Mon, 22 Jun 2009 04:57:24 -0700 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.14.3/8.14.3/Submit) id n5MBt4cZ012988; Mon, 22 Jun 2009 04:55:04 -0700 X-Loop: owner@emacsbugs.donarmstrong.com Resent-From: Jason Rumney Original-Sender: Jason Rumney Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs , owner@emacsbugs.donarmstrong.com Resent-Date: Mon, 22 Jun 2009 11:55:04 +0000 Resent-Message-ID: Resent-Sender: owner@emacsbugs.donarmstrong.com X-Emacs-PR-Message: followup 3208 X-Emacs-PR-Package: emacs,w32 X-Emacs-PR-Keywords: Original-Received: via spool by 3208-submit@emacsbugs.donarmstrong.com id=B3208.124567155912827 (code B ref 3208); Mon, 22 Jun 2009 11:55:04 +0000 Original-Received: (at 3208) by emacsbugs.donarmstrong.com; 22 Jun 2009 11:52:39 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from mail-px0-f172.google.com (mail-px0-f172.google.com [209.85.216.172]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id n5MBqYRd012805 for <3208@emacsbugs.donarmstrong.com>; Mon, 22 Jun 2009 04:52:35 -0700 Original-Received: by pxi2 with SMTP id 2so1377881pxi.19 for <3208@emacsbugs.donarmstrong.com>; Mon, 22 Jun 2009 04:52:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:sender:message-id:date:from :user-agent:mime-version:to:cc:subject:references:in-reply-to :content-type:content-transfer-encoding; bh=ac1S8AqEsI7k2vAPyDsnaYQTEsXu6rDkhGVWnJd0mIw=; b=te1ubXIqvV1iL85afPicnyxFbZ8OhsquQVUCE76FN4M3ojkDFi83smGNYjSommiRrs 732Vwj2HAJQd43Z2QXbPWiS+an/5KMxwILk+u7RHkYLvKq+qstsCzSUTdKq2/u7lvAOz 8+RKsrdGn6a+T0Cr+pNgqiM3BYUN1GC3QcfwM= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; b=ZBYYooYEQcsthyc6CwI435VMANfH2OMuRbpcwIXo+PD7uVZbF2ZLfxvD+0rjxIT8jx yGBi/dNZ8wlw5kXxyQYkrqpPYjpsbswZ3lkySNgwho4Ab2RO0K2VXVbszF+XtQ9jh34F uKKb1HOhX8u18RG07INTwBXZ3VdiHM5v/q3Hs= Original-Received: by 10.142.234.16 with SMTP id g16mr2525329wfh.264.1245671548679; Mon, 22 Jun 2009 04:52:28 -0700 (PDT) Original-Received: from ?192.168.249.26? ([124.13.3.16]) by mx.google.com with ESMTPS id 24sm517074wfc.17.2009.06.22.04.52.26 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 22 Jun 2009 04:52:27 -0700 (PDT) User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) In-Reply-To: X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Resent-Date: Mon, 22 Jun 2009 07:57:32 -0400 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:28901 Archived-At: Kenichi Handa wrote: > That will lead to slow display, but I don't understand why > that leads to memory full problem. How many fonts do people > have on Windows roughly? On GNU/Linux, I have about 700 > fontconfig fonts and 4500 X fonts. > I have 2092 fonts available in Emacs (1692 available through the gdi backend, 420 through the uniscribe backend - I'm not sure where the other 20 went). The problem occurs even without the gdi backend enabled - so with 420 fonts. > ??? JISX0208 surely contains U+2203 (THERE EXISTS). > My mistake, so that is no problem. > By the way, in short, which part of the current code is > wrong? Do you mean that there's a bug, or that the current > strategy doesn't work for Windows? > I haven't found what is actually going wrong here yet. But it looks like the problem is caused by has_char returning -1, then later encode_char returns FONT_INVALID_CODE. The latter does not happen with the gdi backend, because it just keeps the code as unicode, rejecting only characters that are beyond the first and last characters covered by the font.