From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Wolfgang Jenkner Newsgroups: gmane.emacs.bugs Subject: bug#19393: 25.0.50; Emacs cannot determine coding system of ISO-8859 encoded files Date: Thu, 15 Jan 2015 14:38:10 +0100 Message-ID: <85bnm088oh.fsf@iznogoud.viz> References: <87sigfpqmx.fsf@thinkpad-t440p.tsdh.org> <85oar3xwc1.fsf@iznogoud.viz> <871tnzs7y6.fsf@thinkpad-t440p.tsdh.org> <85mw6m4aqs.fsf@iznogoud.viz> <83zjamuvgf.fsf@gnu.org> <85egry464g.fsf@iznogoud.viz> <83y4q6us1v.fsf@gnu.org> <85bnn1pvr1.fsf@iznogoud.viz> <83388dudvt.fsf@gnu.org> <85vbl8nce4.fsf@iznogoud.viz> <83tx0suajy.fsf@gnu.org> <85vbl7qa3x.fsf@iznogoud.viz> <83ioh6srv8.fsf@gnu.org> <85h9vuai48.fsf@iznogoud.viz> <85oaq1gnc8.fsf@iznogoud.viz> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1421329222 10976 80.91.229.3 (15 Jan 2015 13:40:22 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 15 Jan 2015 13:40:22 +0000 (UTC) Cc: 19393@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Jan 15 14:40:15 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YBkel-0001gl-26 for geb-bug-gnu-emacs@m.gmane.org; Thu, 15 Jan 2015 14:40:15 +0100 Original-Received: from localhost ([::1]:50798 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YBkej-0008Ie-8X for geb-bug-gnu-emacs@m.gmane.org; Thu, 15 Jan 2015 08:40:13 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54856) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YBkef-0008IH-Vt for bug-gnu-emacs@gnu.org; Thu, 15 Jan 2015 08:40:11 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YBkea-0001q8-1K for bug-gnu-emacs@gnu.org; Thu, 15 Jan 2015 08:40:09 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:48565) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YBkeZ-0001pa-UO for bug-gnu-emacs@gnu.org; Thu, 15 Jan 2015 08:40:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1YBkeZ-0005ds-Eu for bug-gnu-emacs@gnu.org; Thu, 15 Jan 2015 08:40:03 -0500 X-Loop: help-debbugs@gnu.org In-Reply-To: <87sigfpqmx.fsf@thinkpad-t440p.tsdh.org> Resent-From: Wolfgang Jenkner Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 15 Jan 2015 13:40:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 19393 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 19393-submit@debbugs.gnu.org id=B19393.142132918021651 (code B ref 19393); Thu, 15 Jan 2015 13:40:03 +0000 Original-Received: (at 19393) by debbugs.gnu.org; 15 Jan 2015 13:39:40 +0000 Original-Received: from localhost ([127.0.0.1]:57426 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YBkeB-0005d9-Ut for submit@debbugs.gnu.org; Thu, 15 Jan 2015 08:39:40 -0500 Original-Received: from b2bfep11.mx.upcmail.net ([62.179.121.56]:60600) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YBke7-0005cs-Mq for 19393@debbugs.gnu.org; Thu, 15 Jan 2015 08:39:37 -0500 Original-Received: from edge11.upcmail.net ([192.168.13.81]) by b2bfep11.mx.upcmail.net (InterMail vM.8.01.05.11 201-2260-151-128-20120928) with ESMTP id <20150115133928.UPEY22355.b2bfep11-int.chello.at@edge11.upcmail.net> for <19393@debbugs.gnu.org>; Thu, 15 Jan 2015 14:39:28 +0100 Original-Received: from iznogoud.viz ([91.119.120.37]) by edge11.upcmail.net with edge id gDfT1p00H0oWRX70BDfToM; Thu, 15 Jan 2015 14:39:28 +0100 X-SourceIP: 91.119.120.37 Original-Received: from wolfgang by iznogoud.viz with local (Exim 4.84 (FreeBSD)) (envelope-from ) id 1YBkdy-0000LM-Sg; Thu, 15 Jan 2015 14:39:26 +0100 User-Agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/25.0.50 (berkeley-unix) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:98366 Archived-At: On Wed, Jan 14 2015, Wolfgang Jenkner wrote: > There remains the problem, though, that emacs on FreeBSD also uses > gmalloc and hence, IIUC, sbrk() for memory allocation, and at this point > I'm too ignorant about almost everything involved here to be confident > that mmap()ed pages can't overlap with the process (BSS) data segment > when MAP_EXCL | MAP_FIXED is among the flags. > > Without the MAP_EXCL mmap flag they definitely can overlap, as the > following test program shows when it is _statically_ linked. > > Here's the output when I run it: > > r0 = 0x800663000 > Cannot allocate memory > r2 = 0x800662000 However, I somehow forgot that, quite contrary to my test program, src/buffer.c would use MAP_FIXED only when trying to add some other pages on top of an existing region, the beginning of which was mmap'd without MAP_FIXED. Hence the new region could only reach into the data segment if the old one was already there. That is, the patch doesn't change the current situation in this regard. So I think that the patch would be OK, after all.