From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: oops? read/write vs type of length parameter Date: Tue, 12 Apr 2011 05:41:25 -0400 Message-ID: References: <87wrj1jhfc.fsf@rho.meyering.net> <87hba5yq0p.fsf@uwakimon.sk.tsukuba.ac.jp> <834o64sxd7.fsf@gnu.org> <4DA3A7F8.1020503@cs.ucla.edu> <83k4f0qijz.fsf@gnu.org> <4DA3DDCD.10700@cs.ucla.edu> <4DA40AFE.8050406@cs.ucla.edu> Reply-To: Eli Zaretskii NNTP-Posting-Host: lo.gmane.org X-Trace: dough.gmane.org 1302601298 3674 80.91.229.12 (12 Apr 2011 09:41:38 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 12 Apr 2011 09:41:38 +0000 (UTC) Cc: jim@meyering.net, emacs-devel@gnu.org To: Paul Eggert Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Apr 12 11:41:34 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from [140.186.70.17] (helo=lists.gnu.org) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Q9a6G-0001UB-Lk for ged-emacs-devel@m.gmane.org; Tue, 12 Apr 2011 11:41:32 +0200 Original-Received: from localhost ([::1]:40137 helo=lists2.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q9a6G-00041n-75 for ged-emacs-devel@m.gmane.org; Tue, 12 Apr 2011 05:41:32 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:39097) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q9a6A-00041R-VI for emacs-devel@gnu.org; Tue, 12 Apr 2011 05:41:31 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q9a69-00055W-Q2 for emacs-devel@gnu.org; Tue, 12 Apr 2011 05:41:26 -0400 Original-Received: from fencepost.gnu.org ([140.186.70.10]:48024) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q9a69-00055P-MM for emacs-devel@gnu.org; Tue, 12 Apr 2011 05:41:25 -0400 Original-Received: from eliz by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1Q9a69-0004AT-Gc; Tue, 12 Apr 2011 05:41:25 -0400 In-reply-to: <4DA40AFE.8050406@cs.ucla.edu> (message from Paul Eggert on Tue, 12 Apr 2011 01:19:10 -0700) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 140.186.70.10 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 X-Broken-Reverse-DNS: no host name found for IP address 140.186.70.17 Xref: news.gmane.org gmane.emacs.devel:138432 Archived-At: > Date: Tue, 12 Apr 2011 01:19:10 -0700 > From: Paul Eggert > CC: emacs-devel@gnu.org, Jim Meyering > > I added a runtime check for this, which I don't think > will ever fail, but I've been surprised in the past. If it ever fails, aborting is too harsh, I think. The original code was well defended against that possibility, see write-region. It would signal an IO error. > With that check in place we might as well use size_t for the size, Which will cause annoying compiler warnings, at least with some optional switches. > with the goal of removing the runtime checks once we have > carefully checked that they aren't needed. Which will never happen, so these aborts will stay in the code forever. > Here's the patch I installed for that. I don't understand why you went ahead and installed such a change, although it was clear that your opinion on this is being disputed, and at least I explicitly expressed my disagreement with changing that argument to an unsigned type. As long as you are not the head maintainer, I think such unilateral actions are inappropriate. But if I'm the only one who objects to that (both the change and disregarding the disagreement), then so be it.