From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Richard M. Stallman" Newsgroups: gmane.emacs.devel Subject: Re: image size limit? Date: Mon, 17 Oct 2005 13:30:41 -0400 Message-ID: References: <87oe5v7q19.fsf@stupidchicken.com> <87k6giiqh3.fsf@pacem.orebokech.com> <87hdbht7v9.fsf@stupidchicken.com> Reply-To: rms@gnu.org NNTP-Posting-Host: main.gmane.org Content-Type: text/plain; charset=ISO-8859-15 X-Trace: sea.gmane.org 1129570388 10610 80.91.229.2 (17 Oct 2005 17:33:08 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 17 Oct 2005 17:33:08 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Oct 17 19:33:01 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1ERYpM-0000XU-PR for ged-emacs-devel@m.gmane.org; Mon, 17 Oct 2005 19:31:13 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ERYpM-0007M2-0U for ged-emacs-devel@m.gmane.org; Mon, 17 Oct 2005 13:31:12 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1ERYot-0007DU-Ao for emacs-devel@gnu.org; Mon, 17 Oct 2005 13:30:43 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1ERYos-0007D2-Jc for emacs-devel@gnu.org; Mon, 17 Oct 2005 13:30:42 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ERYos-0007Co-1w for emacs-devel@gnu.org; Mon, 17 Oct 2005 13:30:42 -0400 Original-Received: from [199.232.76.164] (helo=fencepost.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.34) id 1ERYos-0000AC-78 for emacs-devel@gnu.org; Mon, 17 Oct 2005 13:30:42 -0400 Original-Received: from rms by fencepost.gnu.org with local (Exim 4.34) id 1ERYor-0008Uh-Cs; Mon, 17 Oct 2005 13:30:41 -0400 Original-To: Chong Yidong In-reply-to: <87hdbht7v9.fsf@stupidchicken.com> (message from Chong Yidong on Sun, 16 Oct 2005 18:27:54 -0400) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:44199 Archived-At: + #define MAX_IMAGE_SIZE 100000 + EMACS_INT Vmax_image_size; 100000 as a limit of linear dimension is too large. A square image 100000-1 on each side will be 10 billion pixels, far too large to fit in a 32 bit machine. Such a limit should be more like 3000. (That would allow almost 10 million pixels, which is still very big.) But I don't think this limit should be absolute. I think it should be specified as a multiple of the frame height and width, and it should be given as a floating point number. I'd suggest 2.0 as the default for this ratio. The error messages should say "Image too large" rather than "Invalid image size".