GNU bug report logs - #27779
26.0.50: read -- Re-entering top level after C stack overflow

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Reported by: Keith David Bershatsky <esq@HIDDEN>; Keywords: confirmed; merged with #25160; dated Fri, 21 Jul 2017 02:13:01 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 2 May 2019 08:00:41 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 02 04:00:41 2019
Received: from localhost ([127.0.0.1]:45518 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hM6e1-0008MU-0u
	for submit <at> debbugs.gnu.org; Thu, 02 May 2019 04:00:41 -0400
Received: from gateway34.websitewelcome.com ([192.185.150.114]:13005)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <esq@HIDDEN>) id 1hM6dy-0008MK-0t
 for 27779 <at> debbugs.gnu.org; Thu, 02 May 2019 04:00:39 -0400
Received: from cm12.websitewelcome.com (cm12.websitewelcome.com [100.42.49.8])
 by gateway34.websitewelcome.com (Postfix) with ESMTP id 89B36297EFF7
 for <27779 <at> debbugs.gnu.org>; Thu,  2 May 2019 03:00:37 -0500 (CDT)
Received: from gator3053.hostgator.com ([50.87.144.69]) by cmsmtp with SMTP
 id M6dwhBJDziQerM6dxhqtVz; Thu, 02 May 2019 03:00:37 -0500
X-Authority-Reason: nr=8
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lawlist.com
 ; s=default;
 h=Content-Type:MIME-Version:Subject:Cc:To:From:Message-ID:Date:
 Sender:Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:
 Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
 In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=Ko18f4/iF87xfmvQs4CdV1ukGiaGfouXZ8YITBCnOXE=; b=d/UmmaH5nJXaCGuuav6mTfDJkS
 A8+NMIttYPHvTslzoHVw6QpEMZ9227F475PvByfycaMV6fnQL+ptOG75MzoNxRWFCzwM8ofur6tGE
 ZXT70rIYkW82ahCTlun9plXTHrhjc1+B1uSeMXE9CB9O0RkSuQjVjD7cYALt9kimndqMlnRSdVJ0f
 sxHymTmvg9gnvE9YiXItl3+zNmsvNmF52jj1Q7PQ6uiALvZPxqL67Dd0b9Or4dDnsRpQub3jVa2se
 syltkjz+tDit2txNoTX3us1YIk2y2LsNKoXcz2pg97zN2cAUnEZsLWySgZdewXqj5ISdawImv5ATF
 xcQ/xisQ==;
Received: from cpe-45-48-239-195.socal.res.rr.com ([45.48.239.195]:54426
 helo=server.local)
 by gator3053.hostgator.com with esmtpsa (TLSv1:DHE-RSA-AES256-SHA:256)
 (Exim 4.91) (envelope-from <esq@HIDDEN>)
 id 1hM6dw-000LLf-Es; Thu, 02 May 2019 03:00:36 -0500
Date: Thu, 02 May 2019 01:00:35 -0700
Message-ID: <m2ftpx1e1o.wl%esq@HIDDEN>
From: Keith David Bershatsky <esq@HIDDEN>
To: Paul Eggert <eggert@HIDDEN>
Subject: Re: bug#27779: #27779;
 C stack overflow from `read' on deeply nested lisp object.
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
X-AntiAbuse: This header was added to track abuse,
 please include it with any abuse report
X-AntiAbuse: Primary Hostname - gator3053.hostgator.com
X-AntiAbuse: Original Domain - debbugs.gnu.org
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - lawlist.com
X-BWhitelist: no
X-Source-IP: 45.48.239.195
X-Source-L: No
X-Exim-ID: 1hM6dw-000LLf-Es
X-Source: 
X-Source-Args: 
X-Source-Dir: 
X-Source-Sender: cpe-45-48-239-195.socal.res.rr.com (server.local)
 [45.48.239.195]:54426
X-Source-Auth: lawlist
X-Email-Count: 3
X-Source-Cap: bGF3bGlzdDtsYXdsaXN0O2dhdG9yMzA1My5ob3N0Z2F0b3IuY29t
X-Local-Domain: yes
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 27779
Cc: mail@HIDDEN, npostavs@HIDDEN, 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

TWO (2) TESTS:

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; TEST # 1.

SOURCE:  git clone -b emacs-26 git://git.sv.gnu.org/emacs.git

CONFIGURE:

CFLAGS='-Wall -O2 -g3' ./configure \
--with-ns \
--enable-checking='yes,glyphs' \
--enable-check-lisp-object-type \
--without-compress-install \
--without-makeinfo \
--with-gnutls=no \
--with-mailutils \
--without-makeinfo

LISP:

(require 'cl-lib)

(defun make-deep-object (depth)
    (let ((obj 1))
      (while (> (cl-decf depth) 0)
        (setq obj (vector (list obj))))
      obj))

;;; STACK OVERFLOW:  problem with `read'
;;; The bug was introduced on December 8, 2016 with
;;; commit:  f0a1e9ec3fba3d5bea5bd62f525dba3fb005d1b1
(let* ((print-circle t)
       (max-lisp-eval-depth most-positive-fixnum)
       (max-specpdl-size most-positive-fixnum)
       (deep-object (make-deep-object 6000))
       (string (prin1-to-string deep-object))
       (result (read string)))
  (when result
    (message "Bug #27779:  Success! (%d)" (length string))))

TEST:  Lanched without the terminal by opening Emacs.app.

RESULT:  Bug #27779:  Success! (23997)

No need to set the terminal with "ulimit -S -s unlimited" before launching Emacs from the terminal.

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; TEST # 2.

SOURCE:  git clone -b emacs-26 git://git.sv.gnu.org/emacs.git

CONFIGURE:

CFLAGS='-Wall -O0 -g3' ./configure \
--with-ns \
--enable-check-lisp-object-type \
--without-compress-install \
--without-makeinfo \
--with-gnutls=no \
--with-mailutils \
--without-makeinfo

LISP:

(require 'cl-lib)

(defun make-deep-object (depth)
    (let ((obj 1))
      (while (> (cl-decf depth) 0)
        (setq obj (vector (list obj))))
      obj))

;;; STACK OVERFLOW:  problem with `read'
;;; The bug was introduced on December 8, 2016 with
;;; commit:  f0a1e9ec3fba3d5bea5bd62f525dba3fb005d1b1
(let* ((print-circle t)
       (max-lisp-eval-depth most-positive-fixnum)
       (max-specpdl-size most-positive-fixnum)
       (deep-object (make-deep-object 6000))
       (string (prin1-to-string deep-object))
       (result (read string)))
  (when result
    (message "Bug #27779:  Success! (%d)" (length string))))

TEST:  Lanched without the terminal by opening Emacs.app.

RESULT:  Re-entering top level after C stack overflow

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

> Date: [05-02-2019 00:26:45] <2 May 2019 00:26:45 -0700>
> From: Paul Eggert <eggert@HIDDEN>
> To: Keith David Bershatsky <esq@HIDDEN>, Noam Postavsky <npostavs@HIDDEN>
> Cc: 27779 <at> debbugs.gnu.org, mail@HIDDEN
> Subject: Re: bug#27779: #27779; C stack overflow from `read' on deeply nested lisp object.
> 
> Keith David Bershatsky wrote:
> > CONFIGURE:  CFLAGS='-Wall -O0 -g3' ./configure \
> >              --with-ns \
> >              --enable-checking='yes,glyphs' \
> >              --enable-check-lisp-object-type \
> >              --without-compress-install \
> >              --without-makeinfo \
> >              --with-gnutls=no \
> >              --with-mailutils \
> >              --without-makeinfo
> 
> What happens if you try it with -O2 rather than -O0?
> 
> Also, what happens if you try it without --enable-checking='yes,glyphs'?
> 
> I have a suspicion that the debugging options are blowing the stack.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 2 May 2019 07:26:58 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 02 03:26:58 2019
Received: from localhost ([127.0.0.1]:45502 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hM67O-0007Yh-9B
	for submit <at> debbugs.gnu.org; Thu, 02 May 2019 03:26:58 -0400
Received: from zimbra.cs.ucla.edu ([131.179.128.68]:40838)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eggert@HIDDEN>) id 1hM67M-0007YO-3N
 for 27779 <at> debbugs.gnu.org; Thu, 02 May 2019 03:26:57 -0400
Received: from localhost (localhost [127.0.0.1])
 by zimbra.cs.ucla.edu (Postfix) with ESMTP id C71281618B2;
 Thu,  2 May 2019 00:26:49 -0700 (PDT)
Received: from zimbra.cs.ucla.edu ([127.0.0.1])
 by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032)
 with ESMTP id 4PWqTWEhDzFj; Thu,  2 May 2019 00:26:49 -0700 (PDT)
Received: from localhost (localhost [127.0.0.1])
 by zimbra.cs.ucla.edu (Postfix) with ESMTP id 2160F1618DB;
 Thu,  2 May 2019 00:26:49 -0700 (PDT)
X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu
Received: from zimbra.cs.ucla.edu ([127.0.0.1])
 by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026)
 with ESMTP id rjWOTVtEVg1M; Thu,  2 May 2019 00:26:49 -0700 (PDT)
Received: from [192.168.1.9] (cpe-23-242-74-103.socal.res.rr.com
 [23.242.74.103])
 by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id EA53B1618AF;
 Thu,  2 May 2019 00:26:48 -0700 (PDT)
Subject: Re: bug#27779: #27779; C stack overflow from `read' on deeply nested
 lisp object.
To: Keith David Bershatsky <esq@HIDDEN>,
 Noam Postavsky <npostavs@HIDDEN>
References: <m2h8ad1gkv.wl%esq@HIDDEN>
From: Paul Eggert <eggert@HIDDEN>
Organization: UCLA Computer Science Department
Message-ID: <1cd930be-72d6-75ba-9c8b-bd5d55e421c5@HIDDEN>
Date: Thu, 2 May 2019 00:26:45 -0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101
 Thunderbird/60.6.1
MIME-Version: 1.0
In-Reply-To: <m2h8ad1gkv.wl%esq@HIDDEN>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 27779
Cc: mail@HIDDEN, 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Keith David Bershatsky wrote:
> CONFIGURE:  CFLAGS='-Wall -O0 -g3' ./configure \
>              --with-ns \
>              --enable-checking='yes,glyphs' \
>              --enable-check-lisp-object-type \
>              --without-compress-install \
>              --without-makeinfo \
>              --with-gnutls=no \
>              --with-mailutils \
>              --without-makeinfo

What happens if you try it with -O2 rather than -O0?

Also, what happens if you try it without --enable-checking='yes,glyphs'?

I have a suspicion that the debugging options are blowing the stack.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 2 May 2019 07:05:58 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 02 03:05:58 2019
Received: from localhost ([127.0.0.1]:45470 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hM5n3-00072W-Pc
	for submit <at> debbugs.gnu.org; Thu, 02 May 2019 03:05:58 -0400
Received: from gateway23.websitewelcome.com ([192.185.49.219]:40549)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <esq@HIDDEN>) id 1hM5n0-00072M-VF
 for 27779 <at> debbugs.gnu.org; Thu, 02 May 2019 03:05:57 -0400
Received: from cm11.websitewelcome.com (cm11.websitewelcome.com [100.42.49.5])
 by gateway23.websitewelcome.com (Postfix) with ESMTP id 27CB42FC6
 for <27779 <at> debbugs.gnu.org>; Thu,  2 May 2019 02:05:54 -0500 (CDT)
Received: from gator3053.hostgator.com ([50.87.144.69]) by cmsmtp with SMTP
 id M5mzhxoU4dnCeM5n0hhnPW; Thu, 02 May 2019 02:05:54 -0500
X-Authority-Reason: nr=8
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lawlist.com
 ; s=default;
 h=Content-Type:MIME-Version:Subject:Cc:To:From:Message-ID:Date:
 Sender:Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:
 Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
 In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=rzT/g1ZTbb/0R37FRHStUkoKQv2tvtMJ1Swd98rhSaE=; b=IhOshCLPqGI5X5focBygRrogwa
 EHWsn+DlAGalFTIlMW7wbW0RLNjP7u/MquwGrIxyNaBHWhTbqwm8poSRRqmp0EBi+jt+dmJcdMWZU
 TBPaTH5UPRdfC6tQUO0CrklnRXak/+DHx7EeZ7KE150y+mLQwJ4QOG5F87+EjviuvocCEjZLIKeXz
 h8QBo+SXLKsjlo7BNM5DfA/SuSXx0Lnuyq1LhcBDxqfdrL+xq9WlgVb37X/IaJgAtbugv4FH8mn6+
 WltrFAQoOnU9jva2quLmyjVMyMVKskFn1lJq8R6bLmYLHIDxu4sEfj+ay8ZxvGjhK/T5Ac9hPL6u9
 KUc1Doyg==;
Received: from cpe-45-48-239-195.socal.res.rr.com ([45.48.239.195]:53848
 helo=server.local)
 by gator3053.hostgator.com with esmtpsa (TLSv1:DHE-RSA-AES256-SHA:256)
 (Exim 4.91) (envelope-from <esq@HIDDEN>)
 id 1hM5mz-004IEo-8v; Thu, 02 May 2019 02:05:53 -0500
Date: Thu, 02 May 2019 00:05:52 -0700
Message-ID: <m2h8ad1gkv.wl%esq@HIDDEN>
From: Keith David Bershatsky <esq@HIDDEN>
To: Noam Postavsky <npostavs@HIDDEN>
Subject: Re: bug#27779: #27779;
 C stack overflow from `read' on deeply nested lisp object.
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
X-AntiAbuse: This header was added to track abuse,
 please include it with any abuse report
X-AntiAbuse: Primary Hostname - gator3053.hostgator.com
X-AntiAbuse: Original Domain - debbugs.gnu.org
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - lawlist.com
X-BWhitelist: no
X-Source-IP: 45.48.239.195
X-Source-L: No
X-Exim-ID: 1hM5mz-004IEo-8v
X-Source: 
X-Source-Args: 
X-Source-Dir: 
X-Source-Sender: cpe-45-48-239-195.socal.res.rr.com (server.local)
 [45.48.239.195]:53848
X-Source-Auth: lawlist
X-Email-Count: 3
X-Source-Cap: bGF3bGlzdDtsYXdsaXN0O2dhdG9yMzA1My5ob3N0Z2F0b3IuY29t
X-Local-Domain: yes
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 27779
Cc: eggert@HIDDEN, mail@HIDDEN, 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

I performed the following tests on OSX 10.6.8 (Snow Leopard):

SOURCE:  git clone -b emacs-26 git://git.sv.gnu.org/emacs.git

CONFIGURE:  CFLAGS='-Wall -O0 -g3' ./configure \
            --with-ns \
            --enable-checking='yes,glyphs' \
            --enable-check-lisp-object-type \
            --without-compress-install \
            --without-makeinfo \
            --with-gnutls=no \
            --with-mailutils \
            --without-makeinfo

LISP:

(require 'cl-lib)

(defun make-deep-object (depth)
    (let ((obj 1))
      (while (> (cl-decf depth) 0)
        (setq obj (vector (list obj))))
      obj))

;;; STACK OVERFLOW:  problem with `read'
;;; The bug was introduced on December 8, 2016 with
;;; commit:  f0a1e9ec3fba3d5bea5bd62f525dba3fb005d1b1
(let* ((print-circle t)
       (max-lisp-eval-depth most-positive-fixnum)
       (max-specpdl-size most-positive-fixnum)
       (deep-object (make-deep-object 6000))
       (string (prin1-to-string deep-object))
       (result (read string)))
  (when result
    (message "Bug #27779:  Success! (%d)" (length string))))

RESULT _WITH_ TERMINAL (ulimit -S -s unlimited):  "Bug #27779:  Success! (23997)"

RESULT _WITHOUT_ TERMINAL (ulimit -S -s unlimited):  "Re-entering top level after C stack overflow"

I use a custom fork of undo-tree with a previous version of the CL Lisp libraries and have not done any testing to see how Emacs 26.2 would fair with my custom fork, or with the stock version of undo-tree.  I have a list of known issues affecting my fork, including, but not limited to:  Emacs Bug #27571 and a need for the old CL Lisp libraries ....  I have not done any testing to see whether #27571 still exists.

Keith

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

> Date: [05-01-2019 19:30:17] <01 May 2019 22:30:17 -0400>
> From: Noam Postavsky <npostavs@HIDDEN>
> To: Vasilij Schneidermann <mail@HIDDEN>
> Cc: Keith David Bershatsky <esq@HIDDEN>, Noam Postavsky <npostavs@HIDDEN>,
> Paul Eggert <eggert@HIDDEN>, 27779 <at> debbugs.gnu.org
> Subject: Re: bug#27779: #27779; C stack overflow from `read' on deeply nested lisp object.
> 
> Vasilij Schneidermann <mail@HIDDEN> writes:
> 
> > I've run into this issue today when loading up undo-tree on Emacs 26.1.
> 
> I'm wondering if Paul's patch at https://debbugs.gnu.org/31995#21 (which
> is in Emacs 26.2) effectively fixes this for practical use of undo-tree
> history?  That is, we know stack overflow is still possible for a
> sufficiently deep nested object, but that patch should make it possible
> for Emacs to read much deeper objects without overflowing.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 2 May 2019 02:30:29 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed May 01 22:30:29 2019
Received: from localhost ([127.0.0.1]:45314 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hM1UT-0000JD-Hk
	for submit <at> debbugs.gnu.org; Wed, 01 May 2019 22:30:29 -0400
Received: from mail-qt1-f181.google.com ([209.85.160.181]:45369)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <npostavs@HIDDEN>) id 1hM1UR-0000J0-2w
 for 27779 <at> debbugs.gnu.org; Wed, 01 May 2019 22:30:27 -0400
Received: by mail-qt1-f181.google.com with SMTP id t1so111017qtc.12
 for <27779 <at> debbugs.gnu.org>; Wed, 01 May 2019 19:30:27 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=from:to:cc:subject:references:date:in-reply-to:message-id
 :user-agent:mime-version;
 bh=YFWKCR+jIo/DYMCxJDozi+uvjHP1N3r4qgIyPqcHOC8=;
 b=HH1R5ygcbXLZNkGmfp7yXkQdF2f+h0kfyTqCXY7B2De3VMvgX7eiMwG7/2bvaYf2NJ
 djrMYe6yMfXqoJsjjnA7R5c76A4dmEx4zev24yUkQj5cBiEoCPcD2Fp1ezpEuGzxaMBC
 S8cO0TBIKhSyukT8MCUmE8DKqver/9IaxGpbCeaBIsNVIbPKCZZBrtzW04UuanIVef5n
 gYxEE0tmGbqMXEAAypHnfIQbJO/fA49YW8mSCy/o7Ot6wG8jOQvY6JvKCccf2G1FqR9v
 kDoFZUY3pUzUWYyYKBSNznWBg2uubqKkFJP63Gbib42bOcFgvRdaD8YLyuL9k3ZdV3uV
 Dp/g==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to
 :message-id:user-agent:mime-version;
 bh=YFWKCR+jIo/DYMCxJDozi+uvjHP1N3r4qgIyPqcHOC8=;
 b=qLA04V3fVSN60tw7sDQYFKq2U1fqQgww8dKjcYX7iNIXT2njlJgLMHAURHh9JFR1U6
 bxHHpFN5/aAO/fq/mubj05JXUi0yQRKT7WAL4Wsc4zx9daiqMPRGKO7vzz2nxv1BH5p4
 H3SX3qKuEg+gcriSwlUhVAgcPjqTSkWTTF/2JKfII3mBjkyw5cAGtlU1QBGLa7g6SB97
 ZF4gUkVzOiK1fzsbRhJe6u2XG9mDsIukeWJehAlxe8nVZw2WQrwP20tGNfyCOIIL4D7B
 7blHk/WzphaVIpgwBaM/FSJZPWoVGUfUBQEmoMfmuqRibdNP8jlHipgcy6j2XH6L3Aiy
 KRiw==
X-Gm-Message-State: APjAAAVIRMl+bpOEwidgee20MReJWUGQodmi6u0VuOmpSIGCVMsrxX08
 u5YgfmZhPFEqMeaqQqJ8ofErxkp7
X-Google-Smtp-Source: APXvYqxNasLKCeCGZKaO836jTgRr8cnKwpzy/coU+r6VRMEUpOxWgpCcraI4lrd5KJeWlkeSKe5p5A==
X-Received: by 2002:a0c:9592:: with SMTP id s18mr1158568qvs.204.1556764220378; 
 Wed, 01 May 2019 19:30:20 -0700 (PDT)
Received: from minid (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34])
 by smtp.googlemail.com with ESMTPSA id
 p19sm15443645qtp.19.2019.05.01.19.30.18
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Wed, 01 May 2019 19:30:18 -0700 (PDT)
From: Noam Postavsky <npostavs@HIDDEN>
To: Vasilij Schneidermann <mail@HIDDEN>
Subject: Re: bug#27779: #27779;
 C stack overflow from `read' on deeply nested lisp object.
References: <m2wp72h72g.wl%esq@HIDDEN>
 <20180606210439.b2hw5gx66ahiwube@HIDDEN>
Date: Wed, 01 May 2019 22:30:17 -0400
In-Reply-To: <20180606210439.b2hw5gx66ahiwube@HIDDEN> (Vasilij
 Schneidermann's message of "Wed, 6 Jun 2018 23:04:39 +0200")
Message-ID: <87ftpxoafa.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 27779
Cc: Paul Eggert <eggert@HIDDEN>, Keith David Bershatsky <esq@HIDDEN>,
 27779 <at> debbugs.gnu.org, Noam Postavsky <npostavs@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Vasilij Schneidermann <mail@HIDDEN> writes:

> I've run into this issue today when loading up undo-tree on Emacs 26.1.

I'm wondering if Paul's patch at https://debbugs.gnu.org/31995#21 (which
is in Emacs 26.2) effectively fixes this for practical use of undo-tree
history?  That is, we know stack overflow is still possible for a
sufficiently deep nested object, but that patch should make it possible
for Emacs to read much deeper objects without overflowing.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 7 Jun 2018 08:18:15 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Jun 07 04:18:15 2018
Received: from localhost ([127.0.0.1]:37394 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1fQq7b-0004Fk-J9
	for submit <at> debbugs.gnu.org; Thu, 07 Jun 2018 04:18:15 -0400
Received: from mx1.mailbox.org ([80.241.60.212]:15424)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <mail@HIDDEN>) id 1fQq7Z-0004FX-PN
 for 27779 <at> debbugs.gnu.org; Thu, 07 Jun 2018 04:18:14 -0400
Received: from smtp2.mailbox.org (smtp2.mailbox.org [80.241.60.241])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (No client certificate requested)
 by mx1.mailbox.org (Postfix) with ESMTPS id 444414666D;
 Thu,  7 Jun 2018 10:18:07 +0200 (CEST)
X-Virus-Scanned: amavisd-new at heinlein-support.de
Received: from smtp2.mailbox.org ([80.241.60.241])
 by spamfilter01.heinlein-hosting.de (spamfilter01.heinlein-hosting.de
 [80.241.56.115]) (amavisd-new, port 10030)
 with ESMTP id 7GS_L5PTC3aP; Thu,  7 Jun 2018 10:18:06 +0200 (CEST)
Date: Thu, 7 Jun 2018 10:18:03 +0200
From: Vasilij Schneidermann <mail@HIDDEN>
To: Noam Postavsky <npostavs@HIDDEN>
Subject: Re: bug#27779: #27779; C stack overflow from `read' on deeply nested
 lisp object.
Message-ID: <20180607081801.dzcldvkblxhakais@HIDDEN>
References: <m2wp72h72g.wl%esq@HIDDEN>
 <20180606210439.b2hw5gx66ahiwube@HIDDEN>
 <87o9gn4n7u.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <87o9gn4n7u.fsf@HIDDEN>
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 27779
Cc: Keith David Bershatsky <esq@HIDDEN>, 27779 <at> debbugs.gnu.org,
 Paul Eggert <eggert@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

> Only if they've set undo-tree-auto-save-history, right?  (which, for all
> I know, might be a really popular setting)

Hm, you're right.  This bug effectively neuters that feature, if I
disable it I can load up Emacs just fine.  The setting isn't nearly as
popular as Evil.

I can only wonder how many more packages rely on reading deeply nested
trees...




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 6 Jun 2018 21:30:40 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Jun 06 17:30:40 2018
Received: from localhost ([127.0.0.1]:37125 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1fQg0t-0008Lh-Pk
	for submit <at> debbugs.gnu.org; Wed, 06 Jun 2018 17:30:39 -0400
Received: from mail-io0-f176.google.com ([209.85.223.176]:35768)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <npostavs@HIDDEN>) id 1fQg0r-0008LU-Up
 for 27779 <at> debbugs.gnu.org; Wed, 06 Jun 2018 17:30:38 -0400
Received: by mail-io0-f176.google.com with SMTP id u4-v6so9378910iof.2
 for <27779 <at> debbugs.gnu.org>; Wed, 06 Jun 2018 14:30:37 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=from:to:cc:subject:references:date:in-reply-to:message-id
 :user-agent:mime-version;
 bh=fkY6/vEJTA7MVh4WsPXaL3MfqlG7xV/rrWQ4Q2ehApY=;
 b=WaSqHdbP34e5139xiQWYdzrZOtA5W9sW0yHLrYqJzz+bRNH+i6hiR7m3sAevpCNAqM
 Jlr2ZNWO/GAELnS/gipi/1Iaw0uMUHroJ9lrnbNPH0TJeZX9kDYiYjBg/b3hE4H82Nrb
 yviYliNLseFL6ExzMZ7+NUcUCGVvM+ZK9PFJvp+PWtKJEFi8aZocwB6l7SGdpAuaAOyN
 /3oaVoThGg7qrWSZmoX+Gv6j1v9ge03ETo8ZYRxecwnYv/A+cxdtLz1fVoO69Bib8BsH
 CgLKwuhbGi6U+0aEg4fewoBVOD6O8Fsve8YmTrdOndvxIlpp2NDduelMRxJ7xm7tBcyB
 UCdA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to
 :message-id:user-agent:mime-version;
 bh=fkY6/vEJTA7MVh4WsPXaL3MfqlG7xV/rrWQ4Q2ehApY=;
 b=o7jlZGdndxpbOedxsJkwG8cubWzSHSAz7N5JEj+2+JSXo7X17CiVC9iwxvq/0jIURC
 I4D5XMKq+Ok//VXOJK0HlCMWxr+uCZFs9B6iJNWmfQ4LK4EjTUhs7+IXoRH+GQlgVbb2
 P5cOsJ0yHIUe/S7tzx/P9bej2zy8k161/k/nF7mH2xapwDxoVq/YhQTv093Rhdd+X1R7
 bN47NV+r6ugukzH8TWHCuCCGMxkTyUtH5mUqaJCKMbEif72nM0sY6stynhCwtOkJs0wM
 n9/tjkzSLcREQ/fmUwSBALqM33aeuwUVB7PAc2XknhSOo5L5nwFSabPKAqioU+nPZRjW
 qF5g==
X-Gm-Message-State: APt69E30IDx6NswCPYOuuNR7Vb7X6VaRLZH23AvYMz0DbkjIzKmjpNZn
 83kqPmxmUGq5fb3yRHT5k6OQYwkX
X-Google-Smtp-Source: ADUXVKJv+8jKUWe0TygB9f5eUCpFhWB5O1ZzZacBcjcgrHBbA17LJlsw86BGnmu2PyfL1BhBQDwKKg==
X-Received: by 2002:a6b:32d4:: with SMTP id
 y203-v6mr4761968ioy.107.1528320632191; 
 Wed, 06 Jun 2018 14:30:32 -0700 (PDT)
Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34])
 by smtp.googlemail.com with ESMTPSA id
 s5-v6sm6433702ioj.13.2018.06.06.14.30.31
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Wed, 06 Jun 2018 14:30:31 -0700 (PDT)
From: Noam Postavsky <npostavs@HIDDEN>
To: Vasilij Schneidermann <mail@HIDDEN>
Subject: Re: bug#27779: #27779;
 C stack overflow from `read' on deeply nested lisp object.
References: <m2wp72h72g.wl%esq@HIDDEN>
 <20180606210439.b2hw5gx66ahiwube@HIDDEN>
Date: Wed, 06 Jun 2018 17:30:29 -0400
In-Reply-To: <20180606210439.b2hw5gx66ahiwube@HIDDEN> (Vasilij
 Schneidermann's message of "Wed, 6 Jun 2018 23:04:39 +0200")
Message-ID: <87o9gn4n7u.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 27779
Cc: Keith David Bershatsky <esq@HIDDEN>, 27779 <at> debbugs.gnu.org,
 Paul Eggert <eggert@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Vasilij Schneidermann <mail@HIDDEN> writes:

> I expect plenty more people to run into this as undo-tree is a
> dependency for Evil and therefore keeps Emacs users from properly
> booting their editor

Only if they've set undo-tree-auto-save-history, right?  (which, for all
I know, might be a really popular setting)




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 6 Jun 2018 21:04:51 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Jun 06 17:04:51 2018
Received: from localhost ([127.0.0.1]:37111 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1fQfbu-0007kL-OR
	for submit <at> debbugs.gnu.org; Wed, 06 Jun 2018 17:04:51 -0400
Received: from mx1.mailbox.org ([80.241.60.212]:26440)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <mail@HIDDEN>) id 1fQfbs-0007k4-N4
 for 27779 <at> debbugs.gnu.org; Wed, 06 Jun 2018 17:04:49 -0400
Received: from smtp2.mailbox.org (smtp2.mailbox.org [80.241.60.241])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (No client certificate requested)
 by mx1.mailbox.org (Postfix) with ESMTPS id C2FB9448B1;
 Wed,  6 Jun 2018 23:04:42 +0200 (CEST)
X-Virus-Scanned: amavisd-new at heinlein-support.de
Received: from smtp2.mailbox.org ([80.241.60.241])
 by spamfilter01.heinlein-hosting.de (spamfilter01.heinlein-hosting.de
 [80.241.56.115]) (amavisd-new, port 10030)
 with ESMTP id xMGuB9w2MsXg; Wed,  6 Jun 2018 23:04:41 +0200 (CEST)
Date: Wed, 6 Jun 2018 23:04:39 +0200
From: Vasilij Schneidermann <mail@HIDDEN>
To: Keith David Bershatsky <esq@HIDDEN>,
 Noam Postavsky <npostavs@HIDDEN>,
 Paul Eggert <eggert@HIDDEN>
Subject: #27779; C stack overflow from `read' on deeply nested lisp object.
Message-ID: <20180606210439.b2hw5gx66ahiwube@HIDDEN>
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="afqcybuizkygghrj"
Content-Disposition: inline
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 27779
Cc: 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)


--afqcybuizkygghrj
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline

Hello all,

I've run into this issue today when loading up undo-tree on Emacs 26.1.
The last patch fixes it for me, I only had to delete the first context
line of hunk #13 for it to apply with some fuzz.  I expect plenty more
people to run into this as undo-tree is a dependency for Evil and
therefore keeps Emacs users from properly booting their editor (it's
particularly fatal for the daemon, I couldn't get `emacsclient` to
successfully connect to it after it ran into the issue).

Vasilij

--afqcybuizkygghrj
Content-Type: text/plain; charset=utf-8
Content-Disposition: attachment; filename="stack-overflow.patch"

diff --git a/src/lread.c b/src/lread.c
index 45d6064..1219077 100644
--- a/src/lread.c
+++ b/src/lread.c
@@ -2272,28 +2272,16 @@ read0 (Lisp_Object readcharfun)
 	    Fmake_string (make_number (1), make_number (c)));
 }
 
-/* Grow a read buffer BUF that contains OFFSET useful bytes of data,
-   by at least MAX_MULTIBYTE_LENGTH bytes.  Update *BUF_ADDR and
-   *BUF_SIZE accordingly; 0 <= OFFSET <= *BUF_SIZE.  If *BUF_ADDR is
-   initially null, BUF is on the stack: copy its data to the new heap
-   buffer.  Otherwise, BUF must equal *BUF_ADDR and can simply be
-   reallocated.  Either way, remember the heap allocation (which is at
-   pdl slot COUNT) so that it can be freed when unwinding the stack.*/
-
-static char *
-grow_read_buffer (char *buf, ptrdiff_t offset,
-		  char **buf_addr, ptrdiff_t *buf_size, ptrdiff_t count)
+static ptrdiff_t read_buffer_size;
+static char *read_buffer;
+ 
+/* Grow the read buffer by at least MAX_MULTIBYTE_LENGTH bytes.  */
+ 
+static void
+grow_read_buffer (void)
 {
-  char *p = xpalloc (*buf_addr, buf_size, MAX_MULTIBYTE_LENGTH, -1, 1);
-  if (!*buf_addr)
-    {
-      memcpy (p, buf, offset);
-      record_unwind_protect_ptr (xfree, p);
-    }
-  else
-    set_unwind_protect_ptr (count, xfree, p);
-  *buf_addr = p;
-  return p;
+  read_buffer = xpalloc (read_buffer, &read_buffer_size,
+			 MAX_MULTIBYTE_LENGTH, -1, 1);
 }
 
 /* Return the scalar value that has the Unicode character name NAME.
@@ -2673,10 +2661,8 @@ static Lisp_Object
 read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
 {
   int c;
-  bool uninterned_symbol = false;
+  bool uninterned_symbol = 0;
   bool multibyte;
-  char stackbuf[MAX_ALLOCA];
-  current_thread->stack_top = stackbuf;
 
   *pch = 0;
 
@@ -3028,7 +3014,7 @@ read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
       /* #:foo is the uninterned symbol named foo.  */
       if (c == ':')
 	{
-	  uninterned_symbol = true;
+	  uninterned_symbol = 1;
 	  c = READCHAR;
 	  if (!(c > 040
 		&& c != NO_BREAK_SPACE
@@ -3285,20 +3271,16 @@ read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
 
     case '"':
       {
-	ptrdiff_t count = SPECPDL_INDEX ();
-	char *read_buffer = stackbuf;
-	ptrdiff_t read_buffer_size = sizeof stackbuf;
-	char *heapbuf = NULL;
 	char *p = read_buffer;
 	char *end = read_buffer + read_buffer_size;
 	int ch;
 	/* True if we saw an escape sequence specifying
 	   a multibyte character.  */
-	bool force_multibyte = false;
+	bool force_multibyte = 0;
 	/* True if we saw an escape sequence specifying
 	   a single-byte character.  */
-	bool force_singlebyte = false;
-	bool cancel = false;
+	bool force_singlebyte = 0;
+	bool cancel = 0;
 	ptrdiff_t nchars = 0;
 
 	while ((ch = READCHAR) >= 0
@@ -3307,9 +3289,7 @@ read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
 	    if (end - p < MAX_MULTIBYTE_LENGTH)
 	      {
 		ptrdiff_t offset = p - read_buffer;
-		read_buffer = grow_read_buffer (read_buffer, offset,
-						&heapbuf, &read_buffer_size,
-						count);
+		grow_read_buffer ();
 		p = read_buffer + offset;
 		end = read_buffer + read_buffer_size;
 	      }
@@ -3324,7 +3304,7 @@ read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
 		if (ch == -1)
 		  {
 		    if (p == read_buffer)
-		      cancel = true;
+		      cancel = 1;
 		    continue;
 		  }
 
@@ -3332,9 +3312,9 @@ read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
 		ch = ch & ~CHAR_MODIFIER_MASK;
 
 		if (CHAR_BYTE8_P (ch))
-		  force_singlebyte = true;
+		  force_singlebyte = 1;
 		else if (! ASCII_CHAR_P (ch))
-		  force_multibyte = true;
+		  force_multibyte = 1;
 		else		/* I.e. ASCII_CHAR_P (ch).  */
 		  {
 		    /* Allow `\C- ' and `\C-?'.  */
@@ -3360,7 +3340,7 @@ read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
 			   string.  */
 			modifiers &= ~CHAR_META;
 			ch = BYTE8_TO_CHAR (ch | 0x80);
-			force_singlebyte = true;
+			force_singlebyte = 1;
 		      }
 		  }
 
@@ -3373,9 +3353,9 @@ read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
 	      {
 		p += CHAR_STRING (ch, (unsigned char *) p);
 		if (CHAR_BYTE8_P (ch))
-		  force_singlebyte = true;
+		  force_singlebyte = 1;
 		else if (! ASCII_CHAR_P (ch))
-		  force_multibyte = true;
+		  force_multibyte = 1;
 	      }
 	    nchars++;
 	  }
@@ -3387,7 +3367,7 @@ read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
 	   return zero instead.  This is for doc strings
 	   that we are really going to find in etc/DOC.nn.nn.  */
 	if (!NILP (Vpurify_flag) && NILP (Vdoc_file_name) && cancel)
-	  return unbind_to (count, make_number (0));
+	  return make_number (0);
 
 	if (! force_multibyte && force_singlebyte)
 	  {
@@ -3398,11 +3378,9 @@ read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
 	    p = read_buffer + nchars;
 	  }
 
-	Lisp_Object result
-	  = make_specified_string (read_buffer, nchars, p - read_buffer,
-				   (force_multibyte
-				    || (p - read_buffer != nchars)));
-	return unbind_to (count, result);
+	return make_specified_string (read_buffer, nchars, p - read_buffer,
+				      (force_multibyte
+				       || (p - read_buffer != nchars)));
       }
 
     case '.':
@@ -3430,54 +3408,58 @@ read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
 
     read_symbol:
       {
-	ptrdiff_t count = SPECPDL_INDEX ();
-	char *read_buffer = stackbuf;
-	ptrdiff_t read_buffer_size = sizeof stackbuf;
-	char *heapbuf = NULL;
 	char *p = read_buffer;
-	char *end = read_buffer + read_buffer_size;
-	bool quoted = false;
+	bool quoted = 0;
 	EMACS_INT start_position = readchar_count - 1;
 
-	do
-	  {
-	    if (end - p < MAX_MULTIBYTE_LENGTH + 1)
-	      {
-		ptrdiff_t offset = p - read_buffer;
-		read_buffer = grow_read_buffer (read_buffer, offset,
-						&heapbuf, &read_buffer_size,
-						count);
-		p = read_buffer + offset;
-		end = read_buffer + read_buffer_size;
-	      }
+	{
+	  char *end = read_buffer + read_buffer_size;
+ 
+	  do
+	    {
+	      if (end - p < MAX_MULTIBYTE_LENGTH)
+		{
+		  ptrdiff_t offset = p - read_buffer;
+		  grow_read_buffer ();
+		  p = read_buffer + offset;
+		  end = read_buffer + read_buffer_size;
+		}
 
-	    if (c == '\\')
-	      {
-		c = READCHAR;
-		if (c == -1)
-		  end_of_file_error ();
-		quoted = true;
-	      }
+	      if (c == '\\')
+		{
+		  c = READCHAR;
+		  if (c == -1)
+		    end_of_file_error ();
+		  quoted = 1;
+		}
 
-	    if (multibyte)
-	      p += CHAR_STRING (c, (unsigned char *) p);
-	    else
-	      *p++ = c;
-	    c = READCHAR;
-	  }
-	while (c > 040
-	       && c != NO_BREAK_SPACE
-	       && (c >= 0200
-		   || strchr ("\"';()[]#`,", c) == NULL));
+	      if (multibyte)
+		p += CHAR_STRING (c, (unsigned char *) p);
+	      else
+		*p++ = c;
+	      c = READCHAR;
+	    }
+	  while (c > 040
+		 && c != NO_BREAK_SPACE
+		 && (c >= 0200
+		     || strchr ("\"';()[]#`,", c) == NULL));
 
-	*p = 0;
-	UNREAD (c);
+	  if (p == end)
+	    {
+	      ptrdiff_t offset = p - read_buffer;
+	      grow_read_buffer ();
+	      p = read_buffer + offset;
+	      end = read_buffer + read_buffer_size;
+	    }
+	  *p = 0;
+	  UNREAD (c);
+	}
 
 	if (!quoted && !uninterned_symbol)
 	  {
 	    Lisp_Object result = string_to_number (read_buffer, 10, 0);
 	    if (! NILP (result))
-	      return unbind_to (count, result);
+	      return result;
 	  }
         if (!quoted && multibyte)
           {
@@ -3498,48 +3480,25 @@ read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
           }
 	{
-	  Lisp_Object result;
+	  Lisp_Object name, result;
 	  ptrdiff_t nbytes = p - read_buffer;
 	  ptrdiff_t nchars
 	    = (multibyte
 	       ? multibyte_chars_in_text ((unsigned char *) read_buffer,
 					  nbytes)
 	       : nbytes);
-
-	  if (uninterned_symbol)
-	    {
-	      Lisp_Object name
-		= ((! NILP (Vpurify_flag)
-		    ? make_pure_string : make_specified_string)
-		   (read_buffer, nchars, nbytes, multibyte));
-	      result = Fmake_symbol (name);
-	    }
-	  else
-	    {
-	      /* Don't create the string object for the name unless
-		 we're going to retain it in a new symbol.
-
-		 Like intern_1 but supports multibyte names.  */
-	      Lisp_Object obarray = check_obarray (Vobarray);
-	      Lisp_Object tem = oblookup (obarray, read_buffer,
-					  nchars, nbytes);
-
-	      if (SYMBOLP (tem))
-		result = tem;
-	      else
-		{
-		  Lisp_Object name
-		    = make_specified_string (read_buffer, nchars, nbytes,
-					     multibyte);
-		  result = intern_driver (name, obarray, tem);
-		}
-	    }
-
+ 
+	  name = ((uninterned_symbol && ! NILP (Vpurify_flag)
+		   ? make_pure_string : make_specified_string)
+		  (read_buffer, nchars, nbytes, multibyte));
+	  result = (uninterned_symbol ? Fmake_symbol (name)
+		    : Fintern (name, Qnil));
+ 
 	  if (EQ (Vread_with_symbol_positions, Qt)
 	      || EQ (Vread_with_symbol_positions, readcharfun))
 	    Vread_symbol_positions_list
 	      = Fcons (Fcons (result, make_number (start_position)),
 		       Vread_symbol_positions_list);
-	  return unbind_to (count, result);
+	  return result;
 	}
       }
     }
@@ -4320,7 +4279,12 @@ OBARRAY defaults to the value of `obarray'.  */)
 void
 init_obarray (void)
 {
-  Vobarray = Fmake_vector (make_number (OBARRAY_SIZE), make_number (0));
+  Lisp_Object oblength;
+  ptrdiff_t size = 100 + MAX_MULTIBYTE_LENGTH;
+ 
+  XSETFASTINT (oblength, OBARRAY_SIZE);
+ 
+  Vobarray = Fmake_vector (oblength, make_number (0));
   initial_obarray = Vobarray;
   staticpro (&initial_obarray);
 
@@ -4343,6 +4307,9 @@ init_obarray (void)
   Vpurify_flag = Qt;
 
   DEFSYM (Qvariable_documentation, "variable-documentation");
+
+  read_buffer = xmalloc (size);
+  read_buffer_size = size;
 }
 
 void

--afqcybuizkygghrj--




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 9 Jan 2018 01:38:32 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon Jan 08 20:38:32 2018
Received: from localhost ([127.0.0.1]:41928 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1eYis4-0005j3-LE
	for submit <at> debbugs.gnu.org; Mon, 08 Jan 2018 20:38:32 -0500
Received: from gateway30.websitewelcome.com ([50.116.126.1]:49877)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <esq@HIDDEN>) id 1eYis1-0005iu-VK
 for 27779 <at> debbugs.gnu.org; Mon, 08 Jan 2018 20:38:30 -0500
Received: from cm11.websitewelcome.com (cm11.websitewelcome.com [100.42.49.5])
 by gateway30.websitewelcome.com (Postfix) with ESMTP id 5C582513B
 for <27779 <at> debbugs.gnu.org>; Mon,  8 Jan 2018 19:38:29 -0600 (CST)
Received: from gator3053.hostgator.com ([50.87.144.69]) by cmsmtp with SMTP
 id Yis0eRhYhvkfxYis1ezqix; Mon, 08 Jan 2018 19:38:29 -0600
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lawlist.com
 ; s=default;
 h=Content-Type:MIME-Version:Subject:Cc:To:From:Message-ID:Date:
 Sender:Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:
 Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
 In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=cBdiQ8ppofnqobTKyi8VOVTnbG7XFpbVhKOQjLg7y38=; b=Dqflcxe6S8BhOzWvD1msgYuIQt
 RTkAkm1bNlktJ20BgupkvFqFXHLwLJDci5Ex8HyM3eVPfoFpHOBcmKccwB3NS1j9g+ot4WvheaSWs
 omv4aTYDG3qj6o5Q7kPMs8Us+IsLVtPJ1LEJcTkuM7M6jEgQ9qJcTsSGSvXWyeK7VIQXbAYD1y/67
 fWkXzA/DKxnlcXzaANkeoMouxwz87k4nvj8oVxvSv7caTykrOxXGpCR+Y82S+TL9WV+lXeiiRLdWR
 3inFvMQ0pj2IlAn5te0Ejosw1WVPJdZ+81iSnmBIRICaOXOBx68O9qw54711l9ZHOrgEB1hx8FZCh
 7ogRip/g==;
Received: from cpe-45-48-239-195.socal.res.rr.com ([45.48.239.195]:54556
 helo=server.private)
 by gator3053.hostgator.com with esmtpsa (TLSv1:DHE-RSA-AES256-SHA:256)
 (Exim 4.89) (envelope-from <esq@HIDDEN>)
 id 1eYis0-003Chk-85; Mon, 08 Jan 2018 19:38:28 -0600
Date: Mon, 08 Jan 2018 17:38:27 -0800
Message-ID: <m2y3l7ke0c.wl%esq@HIDDEN>
From: Keith David Bershatsky <esq@HIDDEN>
To: Noam Postavsky <npostavs@HIDDEN>,
 Paul Eggert <eggert@HIDDEN>
Subject: #27779; C stack overflow from `read' on deeply nested lisp object.
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="Multipart_Mon_Jan__8_17:38:27_2018-1"
X-AntiAbuse: This header was added to track abuse,
 please include it with any abuse report
X-AntiAbuse: Primary Hostname - gator3053.hostgator.com
X-AntiAbuse: Original Domain - debbugs.gnu.org
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - lawlist.com
X-BWhitelist: no
X-Source-IP: 45.48.239.195
X-Source-L: No
X-Exim-ID: 1eYis0-003Chk-85
X-Source: 
X-Source-Args: 
X-Source-Dir: 
X-Source-Sender: cpe-45-48-239-195.socal.res.rr.com (server.private)
 [45.48.239.195]:54556
X-Source-Auth: lawlist
X-Email-Count: 1
X-Source-Cap: bGF3bGlzdDtsYXdsaXN0O2dhdG9yMzA1My5ob3N0Z2F0b3IuY29t
X-Local-Domain: yes
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 27779
Cc: 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: 0.0 (/)

--Multipart_Mon_Jan__8_17:38:27_2018-1
Content-Type: text/plain; charset=US-ASCII

Dear Paul and Noam:

I have determined that bug #27779 was introduced on December 8, 2016 with commit f0a1e9ec3fba3d5bea5bd62f525dba3fb005d1b1.  The following patch to the Emacs 26 branch as of today (01/08/2018) reverses the commit and enables the test below to be completed successfully.

[FYI:  I am on OSX 10.6.8 and am manually increasing the stack limit with `ulimit -S -s unlimited` so that I can have rather large custom undo-tree histories.]

(require 'cl-lib)

(defun make-deep-object (depth)
    (let ((obj 1))
      (while (> (cl-decf depth) 0)
        (setq obj (vector (list obj))))
      obj))

;;; STACK OVERFLOW:  problem with `read'
;;; The bug was introduced on December 8, 2016 with
;;; commit:  f0a1e9ec3fba3d5bea5bd62f525dba3fb005d1b1
(let* ((print-circle t)
       (max-lisp-eval-depth most-positive-fixnum)
       (max-specpdl-size most-positive-fixnum)
       (deep-object (make-deep-object 6000))
       (string (prin1-to-string deep-object))
       (result (read string)))
  (when result
    (message "Bug #27779:  Success! (%d)" (length string))))


--Multipart_Mon_Jan__8_17:38:27_2018-1
Content-Type: application/diff; type=patch
Content-Disposition: attachment; filename="patch.diff"
Content-Transfer-Encoding: base64

ZGlmZiAtLWdpdCBhL3NyYy9scmVhZC5jIGIvc3JjL2xyZWFkLmMKaW5kZXggNDVkNjA2NC4uMTIx
OTA3NyAxMDA2NDQKLS0tIGEvc3JjL2xyZWFkLmMKKysrIGIvc3JjL2xyZWFkLmMKQEAgLTIyNzIs
MjggKzIyNzIsMTYgQEAgcmVhZDAgKExpc3BfT2JqZWN0IHJlYWRjaGFyZnVuKQogCSAgICBGbWFr
ZV9zdHJpbmcgKG1ha2VfbnVtYmVyICgxKSwgbWFrZV9udW1iZXIgKGMpKSk7CiB9CiAMCi0vKiBH
cm93IGEgcmVhZCBidWZmZXIgQlVGIHRoYXQgY29udGFpbnMgT0ZGU0VUIHVzZWZ1bCBieXRlcyBv
ZiBkYXRhLAotICA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WSBkZWZhdWx0cyB0byB0aGUgdmFsdWUgb2YgYG9iYXJyYXknLiAgKi8pCiB2b2lkCiBpbml0X29i
YXJyYXkgKHZvaWQpCiB7Ci0gIFZvYmFycmF5ID0gRm1ha2VfdmVjdG9yIChtYWtlX251bWJlciAo
T0JBUlJBWV9TSVpFKSwgbWFrZV9udW1iZXIgKDApKTsKKyAgTGlzcF9PYmplY3Qgb2JsZW5ndGg7
CisgIHB0cmRpZmZfdCBzaXplID0gMTAwICsgTUFYX01VTFRJQllURV9MRU5HVEg7CisgCisgIFhT
RVRGQVNUSU5UIChvYmxlbmd0aCwgT0JBUlJBWV9TSVpFKTsKKyAKKyAgVm9iYXJyYXkgPSBGbWFr
ZV92ZWN0b3IgKG9ibGVuZ3RoLCBtYWtlX251bWJlciAoMCkpOwogICBpbml0aWFsX29iYXJyYXkg
PSBWb2JhcnJheTsKICAgc3RhdGljcHJvICgmaW5pdGlhbF9vYmFycmF5KTsKIApAQCAtNDM0Myw2
ICs0MzA3LDkgQEAgaW5pdF9vYmFycmF5ICh2b2lkKQogICBWcHVyaWZ5X2ZsYWcgPSBRdDsKIAog
ICBERUZTWU0gKFF2YXJpYWJsZV9kb2N1bWVudGF0aW9uLCAidmFyaWFibGUtZG9jdW1lbnRhdGlv
biIpOworCisgIHJlYWRfYnVmZmVyID0geG1hbGxvYyAoc2l6ZSk7CisgIHJlYWRfYnVmZmVyX3Np
emUgPSBzaXplOwogfQogDAogdm9pZAo=
--Multipart_Mon_Jan__8_17:38:27_2018-1--




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.
Merged 25160 27779. Request was from Noam Postavsky <npostavs@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 23 Jul 2017 22:28:45 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jul 23 18:28:45 2017
Received: from localhost ([127.0.0.1]:53692 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1dZPMj-0007fG-Ey
	for submit <at> debbugs.gnu.org; Sun, 23 Jul 2017 18:28:45 -0400
Received: from gateway22.websitewelcome.com ([192.185.47.65]:45346)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <esq@HIDDEN>) id 1dZPMh-0007f8-HI
 for 27779 <at> debbugs.gnu.org; Sun, 23 Jul 2017 18:28:44 -0400
Received: from cm11.websitewelcome.com (cm11.websitewelcome.com [100.42.49.5])
 by gateway22.websitewelcome.com (Postfix) with ESMTP id CE85973EC5
 for <27779 <at> debbugs.gnu.org>; Sun, 23 Jul 2017 17:28:41 -0500 (CDT)
Received: from gator3053.hostgator.com ([50.87.144.69]) by cmsmtp with SMTP
 id ZPLydmxd87GnJZPLydYEKX; Sun, 23 Jul 2017 17:27:58 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lawlist.com
 ; s=default;
 h=Content-Type:MIME-Version:Subject:Cc:To:From:Message-ID:Date:
 Sender:Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:
 Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
 In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=2bui22gQMdvjxV+h04MDKFbQZ3z/g611mmz3RgVQEqc=; b=KBUVztGHrhPQ0vVZp0WOWI1zFO
 +T6W/fAfpaeCE274WeL0BpmYD/MjuwA//yLe3j1x90B9s1qk9oHU/1VkVfuOaN7VyT4KGIG6mJLcP
 M9Gd3YmYq/r7Ijn7Oi3xQuDi02nwUfNBcE1SZ7xwGZPuwQvw0o1oJmtWzVFqiutMJTvcKAFWSWpxH
 3mWiCOnbtqzsfP2hXpVkBlRW65SPYxde534n8S5/em7H0Xhkd2CWyij8hl+G9JDzTHcXIHQhHLGhf
 pR6/RX9d2zMpDpHRqaYrAeie3MMjrlgLpQViBgUwrhCxbqBD6JodLRe5DFjCVUNnZsK/BhouB87bl
 raUlVnUA==;
Received: from cpe-45-48-239-195.socal.res.rr.com ([45.48.239.195]:54695
 helo=server.local)
 by gator3053.hostgator.com with esmtpsa (TLSv1:DHE-RSA-AES256-SHA:256)
 (Exim 4.87) (envelope-from <esq@HIDDEN>)
 id 1dZPMf-000WEL-0N; Sun, 23 Jul 2017 17:28:41 -0500
Date: Sun, 23 Jul 2017 15:28:40 -0700
Message-ID: <m2h8y2g547.wl%esq@HIDDEN>
From: Keith David Bershatsky <esq@HIDDEN>
To: npostavs@HIDDEN
Subject: Re: bug#27779: 26.0.50: read -- Re-entering top level after C stack
 overflow
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="Multipart_Sun_Jul_23_15:28:40_2017-1"
X-AntiAbuse: This header was added to track abuse,
 please include it with any abuse report
X-AntiAbuse: Primary Hostname - gator3053.hostgator.com
X-AntiAbuse: Original Domain - debbugs.gnu.org
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - lawlist.com
X-BWhitelist: no
X-Source-IP: 45.48.239.195
X-Exim-ID: 1dZPMf-000WEL-0N
X-Source: 
X-Source-Args: 
X-Source-Dir: 
X-Source-Sender: cpe-45-48-239-195.socal.res.rr.com (server.local)
 [45.48.239.195]:54695
X-Source-Auth: lawlist
X-Email-Count: 1
X-Source-Cap: bGF3bGlzdDtsYXdsaXN0O2dhdG9yMzA1My5ob3N0Z2F0b3IuY29t
X-Local-Domain: yes
X-Spam-Score: -2.8 (--)
X-Debbugs-Envelope-To: 27779
Cc: 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.8 (--)

--Multipart_Sun_Jul_23_15:28:40_2017-1
Content-Type: text/plain; charset=US-ASCII

This is a work in progress, but here is a partial:

The first time I see a break in the prior expected behavior was on 11/19/2017 (c61ee94959ba96b2a327df0684593f7e569e30be) when portions of Emacs 25 were merged with the master branch and `emacs.c` was modified.  Here is a partial reversal of the code that broke the ability to avoid a stack overflow by setting `ulimit -S -s unlimited`.  The patch applies to the above-mentioned head -- i.e., the patch will apply following a hard reset.

I have not yet been able to follow the subsequent breaks to avoid a stack overflow with the current master branch.


--Multipart_Sun_Jul_23_15:28:40_2017-1
Content-Type: application/diff; type=patch
Content-Disposition: attachment; filename="patch_5e2ae74df54d4090c591c79ab13e7713c6654b9c.diff"
Content-Transfer-Encoding: base64

ZGlmZiAtLWdpdCBhL3NyYy9lbWFjcy5jIGIvc3JjL2VtYWNzLmMKaW5kZXggMGZlYzcxNi4uMGNl
YzAyZiAxMDA2NDQKLS0tIGEvc3JjL2VtYWNzLmMKKysrIGIvc3JjL2VtYWNzLmMKQEAgLTY3Niw3
ICs2NzYsMTAgQEAgbWFpbiAoaW50IGFyZ2MsIGNoYXIgKiphcmd2KQogICBib29sIGRvX2luaXRp
YWxfc2V0bG9jYWxlOwogICBib29sIGR1bXBpbmc7CiAgIGludCBza2lwX2FyZ3MgPSAwOwotICBi
b29sIG5vX2xvYWR1cCA9IGZhbHNlOworI2lmZGVmIEhB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BIQVZFX1NFVFJMSU1JVCBhbmQgUkxJTUlUX1NUQUNLIGFu
ZCBub3QgQ1lHV0lOICovCiAK
--Multipart_Sun_Jul_23_15:28:40_2017-1--




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 23 Jul 2017 02:43:48 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Jul 22 22:43:48 2017
Received: from localhost ([127.0.0.1]:52783 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1dZ6s0-0003Tk-Jj
	for submit <at> debbugs.gnu.org; Sat, 22 Jul 2017 22:43:48 -0400
Received: from mail-io0-f195.google.com ([209.85.223.195]:37754)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <npostavs@HIDDEN>) id 1dZ6ry-0003TX-9n
 for 27779 <at> debbugs.gnu.org; Sat, 22 Jul 2017 22:43:47 -0400
Received: by mail-io0-f195.google.com with SMTP id p5so2295440ioo.4
 for <27779 <at> debbugs.gnu.org>; Sat, 22 Jul 2017 19:43:46 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=sender:from:to:cc:subject:references:date:in-reply-to:message-id
 :user-agent:mime-version;
 bh=28aSGaQyk78+rgtgei74orSnPNchsvvy/HIQhvSQsag=;
 b=tWAjdsP2KtTTnu9B33VA9NFt53rRkKMw5oA7i/Shm5u7qn8gyhxl0WMkOxvOiLxDHW
 UUoEl06txUhXxE0YkITGwVWkuQjjfNrOjovgQdqNEj80hIl7BiSg+02R9n4Fkuk3yS4V
 KTCVjm1W6iSTXViryX5wdGQXW1HYrY9RnyV5yA5NYwxxIlMmJFL4kxnSPlOWSUp2LCN9
 Gw/WJUk6CD8aLIJuWBACiVznBJuluALm5VbwCUUrY0MWZ5SuiEVcAnsHfrdmOofHYJA9
 SrXFsbYCbRKNwjmD7eZeqhvyLvKI832cebn5vxMo6JsxswjvQFqkz4+ZdSSf1iaBQsvZ
 wkgA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:sender:from:to:cc:subject:references:date
 :in-reply-to:message-id:user-agent:mime-version;
 bh=28aSGaQyk78+rgtgei74orSnPNchsvvy/HIQhvSQsag=;
 b=qnjpK6gvuO0n7NErhUqpdj/EvGHNZExuErSfsKu/f1uQvFzX8Pas1B9Q+Xcb665qAv
 TsblAgdTu7eD3nTpzKFrWLbiI8J2S7oDrd1gV7oAEhm3Sw63xstK4Zw0IniGZauZ1MSb
 3lnidFMmZ32tcbl8EMxFxksC9Bx/9ExqbAXiWlvT3SiTmEF0m2zAibY+BafKiss1J4ek
 j1UsQ1uUtnRMZjjk8LWwAO8MrKs5CKxx3aoazlIQ8T5YDElKYfO27xNM4b5pON9zrK6Q
 MmQ5N4oEkJFcmOui/6+oFIRPE6m9eYpRy9ACpGKTDwu1pZulB9jpFJSMu/D51Ldt/Pk8
 c3TQ==
X-Gm-Message-State: AIVw1119cIT5/1UDZvgBKCO+xHNGmCFoO3wrwOPRkyfzK5CspA+8abhs
 SbsT8gfAIfODqSIm
X-Received: by 10.107.170.170 with SMTP id g42mr201725ioj.19.1500777820465;
 Sat, 22 Jul 2017 19:43:40 -0700 (PDT)
Received: from zony ([45.2.7.65])
 by smtp.googlemail.com with ESMTPSA id b17sm2212138itd.0.2017.07.22.19.43.39
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Sat, 22 Jul 2017 19:43:39 -0700 (PDT)
From: npostavs@HIDDEN
To: Keith David Bershatsky <esq@HIDDEN>
Subject: Re: bug#27779: 26.0.50: read -- Re-entering top level after C stack
 overflow
References: <m2wp72h72g.wl%esq@HIDDEN> <m24lu4kvk8.wl%esq@HIDDEN>
Date: Sat, 22 Jul 2017 22:45:14 -0400
In-Reply-To: <m24lu4kvk8.wl%esq@HIDDEN> (Keith David Bershatsky's message
 of "Sat, 22 Jul 2017 14:31:35 -0700")
Message-ID: <87r2x798hx.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: -2.1 (--)
X-Debbugs-Envelope-To: 27779
Cc: 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.1 (--)

Keith David Bershatsky <esq@HIDDEN> writes:

> By process of elimination via the lo-tech method of trying different
> nightly builds from https://emacsformacosx.com/builds/all , I have
> determined that December 8, 2016 was the last build where I am able to
> successfully run from the terminal:

Likely candidate: [1: f0a1e9ec3f], specifically the addition of stackbuf
in this hunk means read1 will use a lot more stack per call.

@@ -2541,8 +2556,9 @@ read_integer (Lisp_Object readcharfun, EMACS_INT radix)
 read1 (Lisp_Object readcharfun, int *pch, bool first_in_list)
 {
   int c;
-  bool uninterned_symbol = 0;
+  bool uninterned_symbol = false;
   bool multibyte;
+  char stackbuf[MAX_ALLOCA];
 
   *pch = 0;

> At some point AFTER June 11, 2017, Emacs changed from
> crashing to just throwing an error message "Re-entering top level
> after C stack overflow".

I presume that's from [2: 9dee1c884e].

[1: f0a1e9ec3f]: 2016-12-08 13:00:32 -0800
  Make read1 more reentrant
  http://git.savannah.gnu.org/cgit/emacs.git/commit/?id=f0a1e9ec3fba3d5bea5bd62f525dba3fb005d1b1

[2: 9dee1c884e]: 2017-07-14 04:57:18 -0700
  Improve stack-overflow heuristic on GNU/Linux
  http://git.savannah.gnu.org/cgit/emacs.git/commit/?id=9dee1c884eb50ba282eb9dd2495c5269add25963




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 22 Jul 2017 21:31:39 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Jul 22 17:31:39 2017
Received: from localhost ([127.0.0.1]:52631 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1dZ1zv-0004nd-BZ
	for submit <at> debbugs.gnu.org; Sat, 22 Jul 2017 17:31:39 -0400
Received: from gateway23.websitewelcome.com ([192.185.47.80]:36803)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <esq@HIDDEN>) id 1dZ1zt-0004nV-6f
 for 27779 <at> debbugs.gnu.org; Sat, 22 Jul 2017 17:31:38 -0400
Received: from cm15.websitewelcome.com (cm15.websitewelcome.com [100.42.49.9])
 by gateway23.websitewelcome.com (Postfix) with ESMTP id 9AACA1198A
 for <27779 <at> debbugs.gnu.org>; Sat, 22 Jul 2017 16:31:36 -0500 (CDT)
Received: from gator3053.hostgator.com ([50.87.144.69]) by cmsmtp with SMTP
 id Z20Sd23QdnlKZZ20SdA9S9; Sat, 22 Jul 2017 16:32:12 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lawlist.com
 ; s=default;
 h=Content-Type:MIME-Version:Subject:Cc:To:From:Message-ID:Date:
 Sender:Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:
 Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
 In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=CazurzosBV2KFegnXkY4+g62UNU2azNvN4FfUz2MSMc=; b=c6TWtZFNz88H991KyBxVidWCRn
 Q4TyOuelaiQp3RGThnGZaanKsmFvKCXdEL1oQXzRBsXvGvusW1GZWMwZZqh3aIAaI2EolhBS4ZpyA
 mBq5IGA0GCLKr/i2PWtfxbxbBUFhuqZTn2Zqqqrns5t+efZqK6wiRmqcOSzSLbwz37LXAhAbzwWQb
 Cc9tKxrnm9nMZ2MmCzXcQ8ri3sh6Kgq5egpLgkjnXYygNdGKGTfDYSTlx+RCC6JWP4mtvdGQzQGoG
 Hbv43jj+h21rotuKpkyOb78J1gcbhfoyXBOwyhOmmZZe9aVrkg83l/8sce6fR4VVzVrgjbLa8Zwjs
 CUeJWWxQ==;
Received: from cpe-45-48-239-195.socal.res.rr.com ([45.48.239.195]:53624
 helo=server.local)
 by gator3053.hostgator.com with esmtpsa (TLSv1:DHE-RSA-AES256-SHA:256)
 (Exim 4.87) (envelope-from <esq@HIDDEN>)
 id 1dZ1zr-000NOU-Rv; Sat, 22 Jul 2017 16:31:35 -0500
Date: Sat, 22 Jul 2017 14:31:35 -0700
Message-ID: <m24lu4kvk8.wl%esq@HIDDEN>
From: Keith David Bershatsky <esq@HIDDEN>
To: npostavs@HIDDEN
Subject: Re: bug#27779: 26.0.50: read -- Re-entering top level after C stack
 overflow
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
X-AntiAbuse: This header was added to track abuse,
 please include it with any abuse report
X-AntiAbuse: Primary Hostname - gator3053.hostgator.com
X-AntiAbuse: Original Domain - debbugs.gnu.org
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - lawlist.com
X-BWhitelist: no
X-Source-IP: 45.48.239.195
X-Exim-ID: 1dZ1zr-000NOU-Rv
X-Source: 
X-Source-Args: 
X-Source-Dir: 
X-Source-Sender: cpe-45-48-239-195.socal.res.rr.com (server.local)
 [45.48.239.195]:53624
X-Source-Auth: lawlist
X-Email-Count: 1
X-Source-Cap: bGF3bGlzdDtsYXdsaXN0O2dhdG9yMzA1My5ob3N0Z2F0b3IuY29t
X-Local-Domain: yes
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 27779
Cc: 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: 0.0 (/)

By process of elimination via the lo-tech method of trying different nightly builds from https://emacsformacosx.com/builds/all , I have determined that December 8, 2016 was the last build where I am able to successfully run from the terminal:

ulimit -S -s unlimited

/path/to/gui/version/emacs/built/12_08_2016

and then from the *scratch* buffer, evaluate the following:

(require 'cl-lib)

(defun make-deep-object (depth)
    (let ((obj 1))
      (while (> (cl-decf depth) 0)
        (setq obj (vector (list obj))))
      obj))

(let* ((print-circle t)
       (max-lisp-eval-depth most-positive-fixnum)
       (max-specpdl-size most-positive-fixnum)
       (deep-object (make-deep-object 6000))
       (string (prin1-to-string deep-object))
       (result (read string)))
  (when result
    (message "Success! (%d)" (length string))))

The builds that were made AFTER December 8, 2016 all crash through June 11, 2017.  At some point AFTER June 11, 2017, Emacs changed from crashing to just throwing an error message "Re-entering top level after C stack overflow".

The build of December 8, 2016 does not have `emacs-repository-version` defined, so it will be necessary to look at the commits on December 7, 2016 and December 8, 2016 to see what changed that eliminated the prior ability to use `ulimit -S -s unlimited` as a workaround to the stack overflow problem.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 22 Jul 2017 17:21:56 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Jul 22 13:21:56 2017
Received: from localhost ([127.0.0.1]:52579 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1dYy6G-0007bZ-Jp
	for submit <at> debbugs.gnu.org; Sat, 22 Jul 2017 13:21:56 -0400
Received: from mail-io0-f182.google.com ([209.85.223.182]:34698)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <npostavs@HIDDEN>) id 1dYy6E-0007bM-Gr
 for 27779 <at> debbugs.gnu.org; Sat, 22 Jul 2017 13:21:54 -0400
Received: by mail-io0-f182.google.com with SMTP id l7so31679739iof.1
 for <27779 <at> debbugs.gnu.org>; Sat, 22 Jul 2017 10:21:54 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=sender:from:to:cc:subject:references:date:in-reply-to:message-id
 :user-agent:mime-version;
 bh=dKFCulTlIgSlKNf+JhaqvTheiGKC0JXcRVyqVmb/Hlg=;
 b=BDSfdccGObgMXsEkzx3fxl/61WT04UbgTVcASkWq8ApU7LnhdjACWqS4jxs6id6Lqw
 FoHKhM5H9TkYKpM8eYIL93UrEpUiw9wT4KkZNLIbYg5nj7rOVPq/OgF0s+m4TPqZYdl2
 VfxvDyap8dWoHUtk79isjh0+jebSMRtCsLuTs4xBEO4X6VmMbSEE+eQynWqXZYL8VJ04
 smdLNwgrsROZXAEaol5e7F2woDoyd6RfYlUJQPd/mq4rIGXfxGjFH5ML+6RkKOo/Pq0n
 5cXalxnyVahoceDB1g75YBorA9pXKLAPXHwSEYiGkKxUua9782KgAe/MpIONdfPJ1j0q
 1vdA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:sender:from:to:cc:subject:references:date
 :in-reply-to:message-id:user-agent:mime-version;
 bh=dKFCulTlIgSlKNf+JhaqvTheiGKC0JXcRVyqVmb/Hlg=;
 b=izFtJVcd9uygnMgCwuxRYLOW95XkQJJa+7KegA3sQKUoVu0/pzakOoKJ2Nm9x9vIp5
 TgZqi+GkXmpfbxj0ZcekAQ4cUtG3xSF0asacW40e0oURhpaFChlqaqIF/6lcVHvfK1Rk
 ITCwV3NBsXp89OAIAO7U6vWlE7FXmElA2PPo+A4XkfTOY9InTRpNBSoAHb1rq2rcyMiW
 VFIoaTiVwuXHQiJrTiAvyePUWR8MCTU2VaevMhntZiMci4XzpY7du6JB/K4acA2J+hlK
 zwGrypa14/PwBrYleFCWPYiw5UtNVGHa6exHo73PVBeePNQvcecjcRreTe6cssPin/6k
 h/Hg==
X-Gm-Message-State: AIVw111n2G+xw7FKgxaAlwcsFxcEx+38qN9D/9vUMEuXJmOeoth+/dnO
 jMxH+SrURWCc2mHk
X-Received: by 10.107.159.65 with SMTP id i62mr10424185ioe.92.1500744108634;
 Sat, 22 Jul 2017 10:21:48 -0700 (PDT)
Received: from zony ([45.2.7.65])
 by smtp.googlemail.com with ESMTPSA id 201sm3726439iof.21.2017.07.22.10.21.47
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Sat, 22 Jul 2017 10:21:47 -0700 (PDT)
From: npostavs@HIDDEN
To: Keith David Bershatsky <esq@HIDDEN>
Subject: Re: bug#27779: 26.0.50: read -- Re-entering top level after C stack
 overflow
References: <m2wp72h72g.wl%esq@HIDDEN> <m2r2x8mnyr.wl%esq@HIDDEN>
Date: Sat, 22 Jul 2017 13:23:23 -0400
In-Reply-To: <m2r2x8mnyr.wl%esq@HIDDEN> (Keith David Bershatsky's message
 of "Sat, 22 Jul 2017 09:32:44 -0700")
Message-ID: <87wp708jxw.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: -2.1 (--)
X-Debbugs-Envelope-To: 27779
Cc: 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.1 (--)

Keith David Bershatsky <esq@HIDDEN> writes:

> Setting `ulimit -S -s unlimited` from the terminal prior to launching
> the GUI version of Emacs 26.0.50 from the same terminal session on OSX
> 10.6.8 does NOT resolve/fix the "Re-entering top level after C stack
> overflow" that appears in the *Messages* buffer.  :(

Hmm, the trick works on GNU/Linux.

>
> Emacs 25.2.1, on the other hand, IS able to successfully handle the following example:

Yes, it's a bit strange that on 26.0.50 prin1-to-string can go up to
almost 60000, while `read' gives up at 4600.  By the way, for future
reference, I suggest adding a length count to the "Success!" output; I
got confused for a bit when seeing C-M-x easily succeed up to very large
depths (which is because it binds print-level to a small value).

(let* ((print-circle t)
       (max-lisp-eval-depth most-positive-fixnum)
       (max-specpdl-size most-positive-fixnum)
       (deep-object (make-deep-object 6000))
       (string (prin1-to-string deep-object))
       (result (read string)))
  (when result
    (message "Success! (%d)" (length string))))




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 22 Jul 2017 16:33:59 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Jul 22 12:33:59 2017
Received: from localhost ([127.0.0.1]:52556 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1dYxLq-0006Tu-TI
	for submit <at> debbugs.gnu.org; Sat, 22 Jul 2017 12:33:59 -0400
Received: from gateway22.websitewelcome.com ([192.185.47.100]:12121)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <esq@HIDDEN>) id 1dYxLp-0006Tl-QP
 for 27779 <at> debbugs.gnu.org; Sat, 22 Jul 2017 12:33:58 -0400
Received: from cm12.websitewelcome.com (cm12.websitewelcome.com [100.42.49.8])
 by gateway22.websitewelcome.com (Postfix) with ESMTP id 930F03587B
 for <27779 <at> debbugs.gnu.org>; Sat, 22 Jul 2017 11:32:45 -0500 (CDT)
Received: from gator3053.hostgator.com ([50.87.144.69]) by cmsmtp with SMTP
 id YxJzdr9f4dHTnYxK0dK3Pw; Sat, 22 Jul 2017 11:32:04 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lawlist.com
 ; s=default;
 h=Content-Type:MIME-Version:Subject:Cc:To:From:Message-ID:Date:
 Sender:Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:
 Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
 In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=UnPNwPlWrTs2KuJp4ze/WlF3OaaG12QxyTe4/O3q9pQ=; b=nXTQpaOQ4TdIMpT2LfxUTfsXkG
 5dS5AhuFcyosyJdWPVtbCW/2PghPGxGIuEqAcpotG8W/tSf53lwoK4UKu8CJxGQ/dO9fuZjn+oNBw
 hO8tLjHXTh03LioDJ93FXvd8C++lh+4JDf3aCpGHfS2To9EQiUoLJkLC2jXxm3uabWdsuQRNpWDJj
 2+n8KZ6nfl6uer7DmmSBu1JqIR+LuAD7BpexFJNzZxPQxz08BX/fpQ0r8V50tKgZQpII60MoAm4JI
 4ocQB0lHKodVPdzeXM2F9m8HwXMiTs8FNIyQDAFdBnI/+9QAi0EW4wVwwgaaN18TJAJ08I12kiOKa
 bEIA/Faw==;
Received: from cpe-45-48-239-195.socal.res.rr.com ([45.48.239.195]:49946
 helo=server.local)
 by gator3053.hostgator.com with esmtpsa (TLSv1:DHE-RSA-AES256-SHA:256)
 (Exim 4.87) (envelope-from <esq@HIDDEN>)
 id 1dYxKe-001I8H-OP; Sat, 22 Jul 2017 11:32:44 -0500
Date: Sat, 22 Jul 2017 09:32:44 -0700
Message-ID: <m2r2x8mnyr.wl%esq@HIDDEN>
From: Keith David Bershatsky <esq@HIDDEN>
To: npostavs@HIDDEN
Subject: Re: bug#27779: 26.0.50: read -- Re-entering top level after C stack
 overflow
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
X-AntiAbuse: This header was added to track abuse,
 please include it with any abuse report
X-AntiAbuse: Primary Hostname - gator3053.hostgator.com
X-AntiAbuse: Original Domain - debbugs.gnu.org
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - lawlist.com
X-BWhitelist: no
X-Source-IP: 45.48.239.195
X-Exim-ID: 1dYxKe-001I8H-OP
X-Source: 
X-Source-Args: 
X-Source-Dir: 
X-Source-Sender: cpe-45-48-239-195.socal.res.rr.com (server.local)
 [45.48.239.195]:49946
X-Source-Auth: lawlist
X-Email-Count: 1
X-Source-Cap: bGF3bGlzdDtsYXdsaXN0O2dhdG9yMzA1My5ob3N0Z2F0b3IuY29t
X-Local-Domain: yes
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 27779
Cc: 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: 0.0 (/)

Setting `ulimit -S -s unlimited` from the terminal prior to launching the GUI version of Emacs 26.0.50 from the same terminal session on OSX 10.6.8 does NOT resolve/fix the "Re-entering top level after C stack overflow" that appears in the *Messages* buffer.  :(

Emacs 25.2.1, on the other hand, IS able to successfully handle the following example:

(require 'cl-lib)

(defun make-deep-object (depth)
    (let ((obj 1))
      (while (> (cl-decf depth) 0)
        (setq obj (vector (list obj))))
      obj))

(let* ((print-circle t)
       (max-lisp-eval-depth most-positive-fixnum)
       (max-specpdl-size most-positive-fixnum)
       (deep-object (make-deep-object 4600))
       (string (prin1-to-string deep-object))
       (result (read string)))
  (when result
    (message "Success!")))




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 22 Jul 2017 12:04:06 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Jul 22 08:04:06 2017
Received: from localhost ([127.0.0.1]:51978 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1dYt8g-0006iQ-AQ
	for submit <at> debbugs.gnu.org; Sat, 22 Jul 2017 08:04:06 -0400
Received: from mail-io0-f196.google.com ([209.85.223.196]:36770)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <npostavs@HIDDEN>) id 1dYt8d-0006hw-Db
 for 27779 <at> debbugs.gnu.org; Sat, 22 Jul 2017 08:04:03 -0400
Received: by mail-io0-f196.google.com with SMTP id z74so3504318ioz.3
 for <27779 <at> debbugs.gnu.org>; Sat, 22 Jul 2017 05:04:03 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=sender:from:to:cc:subject:references:date:in-reply-to:message-id
 :user-agent:mime-version;
 bh=g6vsxV4PKnuo41JqXXbpl2ZBISSXb1QMF0t96gUqLz0=;
 b=WQyt6re1Je9UT+ZZ1zxc9C+gZKez7RtKM8o9ch+ApgSH2lXBC50rzslNqcoDTphd3P
 /ZyxfQdZmxcsZoKsRexEeeXFbeh4lNqmrkqX67d2ULt5H49BQd3S42wiKvzlUu8SAazo
 iyWwgYGsYYaIFY0uSobGpnVfnOIH+OHqi+Pp1hn+ykPyFjs3VTVe/KYStFBqvuiARf2m
 UFB9Ut2sgJ+iDc0eAoTnXm4/TZ8K6Ba0w5lZsKgeAlFw8ZOFXyG1LQM0l2pwdOCrYCTc
 qpzYgZ0fteEWohbiml4h/l4fZIR+6k9i1/jp8TMuoKz5KO7ewkoJm6p5CrI2f4GKEufo
 tkvQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:sender:from:to:cc:subject:references:date
 :in-reply-to:message-id:user-agent:mime-version;
 bh=g6vsxV4PKnuo41JqXXbpl2ZBISSXb1QMF0t96gUqLz0=;
 b=nS0bEKB3406VqlzQuks23K4fAIKJIgsDd4CqWaK9kxNWssF5JlY4Pv5+7Db+IysCow
 tl53wdpKTaPvZHrUv2XYryJUWwXpC5SX7Ct9TBIzNxuAYyzVSqDI4c/A/TICMw+YyFuz
 5p80gTzmr1oFUsS1631H/zSjSningMO4Zg03Gkg93yAy7cYsoGrMcM7JaE9bEtHoWO6I
 /SmnOcg6E973/LmtdaliW7ijHoLYOlklSfSWANgyl/NDzbffc1/4cr6cqVccmRckNo9a
 39YCaA4BSEsEDO2/b8WcBsKsgQfPbDQgbe7uRG1BlGrbVopTPr+n4t6OAPn8tGyyzSh9
 ZRLQ==
X-Gm-Message-State: AIVw110BVKim3gTpETM4lE0suttDQsBmqjAlP06ja6M2dZhnCB6pbRQJ
 rC/L74jSyGQuCr8y
X-Received: by 10.107.47.21 with SMTP id j21mr10421879ioo.323.1500725037687;
 Sat, 22 Jul 2017 05:03:57 -0700 (PDT)
Received: from zony ([45.2.7.65])
 by smtp.googlemail.com with ESMTPSA id t7sm1573991ita.1.2017.07.22.05.03.56
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Sat, 22 Jul 2017 05:03:56 -0700 (PDT)
From: npostavs@HIDDEN
To: Keith David Bershatsky <esq@HIDDEN>
Subject: Re: bug#27779: 26.0.50: read -- Re-entering top level after C stack
 overflow
References: <m2wp72h72g.wl%esq@HIDDEN> <m260el587x.wl%esq@HIDDEN>
Date: Sat, 22 Jul 2017 08:05:32 -0400
In-Reply-To: <m260el587x.wl%esq@HIDDEN> (Keith David Bershatsky's message
 of "Fri, 21 Jul 2017 22:52:34 -0700")
Message-ID: <8760ekad83.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: -2.1 (--)
X-Debbugs-Envelope-To: 27779
Cc: 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.1 (--)

Keith David Bershatsky <esq@HIDDEN> writes:

> I was not able to workaround this problem in Emacs 26.0.50 by issuing the following command from the terminal prior to launching Emacs from the same terminal session:

s/not able/able/ ? (it worked for me)

> ulimit -S -s unlimited




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 22 Jul 2017 05:52:40 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Jul 22 01:52:40 2017
Received: from localhost ([127.0.0.1]:51795 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1dYnLE-0002pC-HX
	for submit <at> debbugs.gnu.org; Sat, 22 Jul 2017 01:52:40 -0400
Received: from gateway20.websitewelcome.com ([192.185.52.45]:31993)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <esq@HIDDEN>) id 1dYnLC-0002p4-FN
 for 27779 <at> debbugs.gnu.org; Sat, 22 Jul 2017 01:52:39 -0400
Received: from cm13.websitewelcome.com (cm13.websitewelcome.com [100.42.49.6])
 by gateway20.websitewelcome.com (Postfix) with ESMTP id D0416400F8805
 for <27779 <at> debbugs.gnu.org>; Sat, 22 Jul 2017 00:52:35 -0500 (CDT)
Received: from gator3053.hostgator.com ([50.87.144.69]) by cmsmtp with SMTP
 id YnNndXlLNR2HBYnNndBIlo; Sat, 22 Jul 2017 00:55:20 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lawlist.com
 ; s=default;
 h=Content-Type:MIME-Version:Subject:Cc:To:From:Message-ID:Date:
 Sender:Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:
 Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
 In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=3z9B/4zC+0+GsAkj1F/GW3gpenY0dMsUr1/nAdL9q2M=; b=bGFefxftxS9TAfYJnhMq25XBT2
 CtAXzd7iqYSPJw3LXBXgPvzO9j/N3q44U/1QrNWyqUNf6nwsaLnMlYHm5KbY0MVz8mEHcs6daDjq7
 8SFKlJW+jUCmyXkZZh3beNpslLYv+DgOjXtizGmu/+l5sXWESBUsIavmkuGeHFQ41MD+66ija4lgY
 WZxMZgvx6zXX/XiwOFvvZWoK6zKlAB/nd9HsR4tcz4+f3b+ZF+SvZ12rdmaco66foAw1dwcmfFyw2
 t3KXmo13+U8kGQxsNgxhx4wFrEY+lwDqxL9kWgMaT7Xbf4KycFm4elHcokX+4OXkiBlQTW7Wzzl5V
 7VzYf67Q==;
Received: from cpe-45-48-239-195.socal.res.rr.com ([45.48.239.195]:49787
 helo=server.local)
 by gator3053.hostgator.com with esmtpsa (TLSv1:DHE-RSA-AES256-SHA:256)
 (Exim 4.87) (envelope-from <esq@HIDDEN>)
 id 1dYnL8-001PW8-Op; Sat, 22 Jul 2017 00:52:34 -0500
Date: Fri, 21 Jul 2017 22:52:34 -0700
Message-ID: <m260el587x.wl%esq@HIDDEN>
From: Keith David Bershatsky <esq@HIDDEN>
To: npostavs@HIDDEN
Subject: Re: bug#27779: 26.0.50: read -- Re-entering top level after C stack
 overflow
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
X-AntiAbuse: This header was added to track abuse,
 please include it with any abuse report
X-AntiAbuse: Primary Hostname - gator3053.hostgator.com
X-AntiAbuse: Original Domain - debbugs.gnu.org
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - lawlist.com
X-BWhitelist: no
X-Source-IP: 45.48.239.195
X-Exim-ID: 1dYnL8-001PW8-Op
X-Source: 
X-Source-Args: 
X-Source-Dir: 
X-Source-Sender: cpe-45-48-239-195.socal.res.rr.com (server.local)
 [45.48.239.195]:49787
X-Source-Auth: lawlist
X-Email-Count: 1
X-Source-Cap: bGF3bGlzdDtsYXdsaXN0O2dhdG9yMzA1My5ob3N0Z2F0b3IuY29t
X-Local-Domain: yes
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 27779
Cc: 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: 0.0 (/)

Thank you for coming up with a test to reproduce this issue.

I was not able to workaround this problem in Emacs 26.0.50 by issuing the following command from the terminal prior to launching Emacs from the same terminal session:

ulimit -S -s unlimited

Keith




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.
Added tag(s) confirmed. Request was from npostavs@HIDDEN to control <at> debbugs.gnu.org. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 22 Jul 2017 03:22:53 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Jul 21 23:22:53 2017
Received: from localhost ([127.0.0.1]:51759 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1dYl0G-0005qg-T6
	for submit <at> debbugs.gnu.org; Fri, 21 Jul 2017 23:22:53 -0400
Received: from mail-it0-f45.google.com ([209.85.214.45]:33654)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <npostavs@HIDDEN>)
 id 1dYl0E-0005qK-PI; Fri, 21 Jul 2017 23:22:51 -0400
Received: by mail-it0-f45.google.com with SMTP id a62so3789874itd.0;
 Fri, 21 Jul 2017 20:22:50 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=sender:from:to:cc:subject:references:date:in-reply-to:message-id
 :user-agent:mime-version;
 bh=BZRDgWIbP/Vh+jANZdJtMOrUNEAEfVEJRiUSJYpCcKg=;
 b=qljmU+dzvzGaKF048BlfRFJY1Wpt2/4g1IqkafQYWa3imhTIhJ0HoezRpm3aoRpfe/
 x8xB8n2C6FtTzc1jGE1siI6e7bdQpD2jVexvbOfVAzIse8AE7TQJYdMp8Rqz/N6gu9NA
 jJkmC7FFXovC/+6cUHlf7xP1Hfctm9vEmOAWKQgJsJDrYvtu6DQ+TWsfhF8b0ZqMZSVH
 Vtr6OTkUlDapYPPBfC+a8f4g8+v8aDy5cvVlVV7uGvXGt59DZf+JMKbNajSQqMRFi54c
 EtHI3sIfNYGKZvuLwJ/5kcg3uwmMI4BJx72Ln2NcWQXBpJeBCCMiTrqHlJqR9M1WsPot
 qB/w==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:sender:from:to:cc:subject:references:date
 :in-reply-to:message-id:user-agent:mime-version;
 bh=BZRDgWIbP/Vh+jANZdJtMOrUNEAEfVEJRiUSJYpCcKg=;
 b=n6b9QzgbHqohhhpIG8knng5cYmXdqFMm1u0XPL0ihmEd8O+5b4WX8klihIyZgEVXJ9
 P887u3T0qmk2R+iwXuDjaVk+E7UaeKigHGVoags/2G+jHZK0UJ5LogDqtTMfrJ+1eMTK
 Am9pcZq326Cgkdkm3GDhgQgeH0rXJxIV0ZOK6qQshtargN1aEQFyGcsbUg5mkqBRzRme
 ZFPwrAi4LoyklkTj8kGoEoatF6M2H1gUoCXUyf/YoWzTw73K4FMvCKN+VN4REglta7WU
 T7/sgDD1az5YJDzBrDMm/PWWz6tYT9LCj0OZ4B7KwF4p4cTDS6JCqUxbDmZgSMlQ+GMM
 L74w==
X-Gm-Message-State: AIVw113tAqGGC/fBt/tI4Byi9iROE74VoOSm42Y6/YNLATBE7VVVgcvt
 MHRZ1ztiPBfxULUs
X-Received: by 10.36.68.193 with SMTP id o184mr983154ita.59.1500693765173;
 Fri, 21 Jul 2017 20:22:45 -0700 (PDT)
Received: from zony ([45.2.7.65])
 by smtp.googlemail.com with ESMTPSA id a127sm1347483itd.33.2017.07.21.20.22.43
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Fri, 21 Jul 2017 20:22:44 -0700 (PDT)
From: npostavs@HIDDEN
To: Keith David Bershatsky <esq@HIDDEN>
Subject: Re: bug#27779: 26.0.50: read -- Re-entering top level after C stack
 overflow
References: <m2wp72h72g.wl%esq@HIDDEN> <m2tw26h4pj.wl%esq@HIDDEN>
Date: Fri, 21 Jul 2017 23:24:19 -0400
In-Reply-To: <m2tw26h4pj.wl%esq@HIDDEN> (Keith David Bershatsky's message
 of "Thu, 20 Jul 2017 20:03:04 -0700")
Message-ID: <87d18t9msc.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 0.7 (/)
X-Debbugs-Envelope-To: 27779
Cc: 27779 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: 0.7 (/)

tags 27779 + confirmed
quit

Keith David Bershatsky <esq@HIDDEN> writes:

> Perhaps we can use a prior function written by @npostavs --
> (make-deep-object DEPTH) -- to create a large enough example of nested
> vectors and lists such that someone on the Emacs development team can
> duplicate the C stack overflow with `read`:
>
>     (require 'cl-lib)
>
>     (defun make-deep-object (depth)
>       (let ((obj 1))
>         (while (> (cl-decf depth) 0)
>           (setq obj (vector (list obj))))
>         obj))

Hah, yes, it seems that `read' uses up more stack than `print', e.g.,
(make-deep-object 4600) succeeds, but (read (prin1-to-string
(make-deep-object 4600))) overflows.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at 27779 <at> debbugs.gnu.org:


Received: (at 27779) by debbugs.gnu.org; 21 Jul 2017 03:03:13 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Jul 20 23:03:13 2017
Received: from localhost ([127.0.0.1]:50210 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1dYODg-0001UP-VU
	for submit <at> debbugs.gnu.org; Thu, 20 Jul 2017 23:03:13 -0400
Received: from gateway32.websitewelcome.com ([192.185.145.12]:25859)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <esq@HIDDEN>) id 1dYODe-0001UH-RY
 for 27779 <at> debbugs.gnu.org; Thu, 20 Jul 2017 23:03:11 -0400
Received: from cm15.websitewelcome.com (cm15.websitewelcome.com [100.42.49.9])
 by gateway32.websitewelcome.com (Postfix) with ESMTP id 2F4375F06C2
 for <27779 <at> debbugs.gnu.org>; Thu, 20 Jul 2017 22:03:07 -0500 (CDT)
Received: from gator3053.hostgator.com ([50.87.144.69]) by cmsmtp with SMTP
 id YOE9dPrpFnlKZYOEAdYICN; Thu, 20 Jul 2017 22:03:42 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lawlist.com
 ; s=default;
 h=Content-Type:MIME-Version:Subject:To:From:Message-ID:Date:
 Sender:Reply-To:Cc:Content-Transfer-Encoding:Content-ID:Content-Description:
 Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
 In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=rZ13F69JbdVMkqqfJt9WSbwyWmANwv6yqATBYLLvTpM=; b=eijisAjutWC/duYHzQamOgRdAn
 SfKmKG8pGK1VZ4h9RhRzJhoMh8ctRtD4DG28Okq0aUKV77Vf9P7D/JqvCLGfyeiNJif+WJeCqphbz
 JyvGDLOLeEORX1HE6+KpcrtRDIovMpvIYClf80QSI5FCmVW6SGfX0zYTaYXr4F5lKScykoXZm8Ivr
 Swsa9MZL/4/4iuXg4C/wZxJGTZ1YRAL6PBx6/tIyLjn+b38NXBlld8C1nfN7uHAoVidaiRbB8sQAV
 X1gRRuAkoZVXWDhc1RUZ8L9e7Zy+4Om8IMXfkn+gjIGqNmyGaH01U4lmQdlbcglafh1v+5xVM9QhC
 osnnZxhQ==;
Received: from cpe-45-48-239-195.socal.res.rr.com ([45.48.239.195]:50838
 helo=server.local)
 by gator3053.hostgator.com with esmtpsa (TLSv1:DHE-RSA-AES256-SHA:256)
 (Exim 4.87) (envelope-from <esq@HIDDEN>) id 1dYODa-002Bub-3o
 for 27779 <at> debbugs.gnu.org; Thu, 20 Jul 2017 22:03:06 -0500
Date: Thu, 20 Jul 2017 20:03:04 -0700
Message-ID: <m2tw26h4pj.wl%esq@HIDDEN>
From: Keith David Bershatsky <esq@HIDDEN>
To: 27779 <at> debbugs.gnu.org
Subject: 26.0.50:  read -- Re-entering top level after C stack overflow
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
X-AntiAbuse: This header was added to track abuse,
 please include it with any abuse report
X-AntiAbuse: Primary Hostname - gator3053.hostgator.com
X-AntiAbuse: Original Domain - debbugs.gnu.org
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - lawlist.com
X-BWhitelist: no
X-Source-IP: 45.48.239.195
X-Exim-ID: 1dYODa-002Bub-3o
X-Source: 
X-Source-Args: 
X-Source-Dir: 
X-Source-Sender: cpe-45-48-239-195.socal.res.rr.com (server.local)
 [45.48.239.195]:50838
X-Source-Auth: lawlist
X-Email-Count: 1
X-Source-Cap: bGF3bGlzdDtsYXdsaXN0O2dhdG9yMzA1My5ob3N0Z2F0b3IuY29t
X-Local-Domain: yes
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 27779
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: 0.0 (/)

Perhaps we can use a prior function written by @npostavs -- (make-deep-object DEPTH) -- to create a large enough example of nested vectors and lists such that someone on the Emacs development team can duplicate the C stack overflow with `read`:

    (require 'cl-lib)

    (defun make-deep-object (depth)
      (let ((obj 1))
        (while (> (cl-decf depth) 0)
          (setq obj (vector (list obj))))
        obj))




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 21 Jul 2017 02:12:37 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Jul 20 22:12:37 2017
Received: from localhost ([127.0.0.1]:50173 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1dYNQi-0006w8-Qa
	for submit <at> debbugs.gnu.org; Thu, 20 Jul 2017 22:12:37 -0400
Received: from eggs.gnu.org ([208.118.235.92]:40442)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <esq@HIDDEN>) id 1dYNQg-0006vw-8u
 for submit <at> debbugs.gnu.org; Thu, 20 Jul 2017 22:12:35 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <esq@HIDDEN>) id 1dYNQZ-0006Zq-RR
 for submit <at> debbugs.gnu.org; Thu, 20 Jul 2017 22:12:28 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: *
X-Spam-Status: No, score=1.3 required=5.0 tests=BAYES_50,RCVD_IN_SORBS_SPAM,
 T_DKIM_INVALID autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:54931)
 by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <esq@HIDDEN>) id 1dYNQZ-0006Zm-NN
 for submit <at> debbugs.gnu.org; Thu, 20 Jul 2017 22:12:27 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59629)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <esq@HIDDEN>) id 1dYNQY-0008Qa-4V
 for bug-gnu-emacs@HIDDEN; Thu, 20 Jul 2017 22:12:27 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <esq@HIDDEN>) id 1dYNQU-0006X6-Sb
 for bug-gnu-emacs@HIDDEN; Thu, 20 Jul 2017 22:12:26 -0400
Received: from gateway24.websitewelcome.com ([192.185.51.253]:46544)
 by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <esq@HIDDEN>) id 1dYNQU-0006T8-Ia
 for bug-gnu-emacs@HIDDEN; Thu, 20 Jul 2017 22:12:22 -0400
Received: from cm17.websitewelcome.com (cm17.websitewelcome.com [100.42.49.20])
 by gateway24.websitewelcome.com (Postfix) with ESMTP id 3C481B04C
 for <bug-gnu-emacs@HIDDEN>; Thu, 20 Jul 2017 21:12:10 -0500 (CDT)
Received: from gator3053.hostgator.com ([50.87.144.69]) by cmsmtp with SMTP
 id YNPodisFKc72gYNPodfFkv; Thu, 20 Jul 2017 21:11:42 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lawlist.com
 ; s=default;
 h=Content-Type:MIME-Version:Subject:To:From:Message-ID:Date:
 Sender:Reply-To:Cc:Content-Transfer-Encoding:Content-ID:Content-Description:
 Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
 In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=4lhzbZ5Jz39P8Nas7hBJVjqd3Q460wHBr9LIAuHCvBo=; b=gUb4JS6oHdtjEFt8xwTJ+k4FYT
 pE01W2zCn+yl07KAIai0xdWadxcChVyMpLH5SkNtwvf2Slq+UpYFFMz2FqGQQLWGvltsoC+O3FtBE
 L8aytUmbe6dsd5U7q2+ZizDPvuCjMC7ybDat8XDGxg5V7u1gV3tnKzxeVtR4vj4Qx/85A24lT8Cdd
 bLzRramh+1Nx2sjSl3pIWER5Atc9ehjrDzEsgPo/bpqzmgfU1/YNxp6i230EHmiOwvUgh/mVfWWus
 aMiIFo/RMrpMadkW4hBTWakJVEQGEW4lTjW7Z2o0VhFJPXqWNsUcnbobKSXxeH1AAnxPrVyDmnmmd
 J11wNkow==;
Received: from cpe-45-48-239-195.socal.res.rr.com ([45.48.239.195]:50042
 helo=server.local)
 by gator3053.hostgator.com with esmtpsa (TLSv1:DHE-RSA-AES256-SHA:256)
 (Exim 4.87) (envelope-from <esq@HIDDEN>) id 1dYNQG-001a3C-Cm
 for bug-gnu-emacs@HIDDEN; Thu, 20 Jul 2017 21:12:08 -0500
Date: Thu, 20 Jul 2017 19:12:07 -0700
Message-ID: <m2wp72h72g.wl%esq@HIDDEN>
From: Keith David Bershatsky <esq@HIDDEN>
To: Emacs Bug Reports <bug-gnu-emacs@HIDDEN>
Subject: 26.0.50:  read -- Re-entering top level after C stack overflow
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
X-AntiAbuse: This header was added to track abuse,
 please include it with any abuse report
X-AntiAbuse: Primary Hostname - gator3053.hostgator.com
X-AntiAbuse: Original Domain - gnu.org
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - lawlist.com
X-BWhitelist: no
X-Source-IP: 45.48.239.195
X-Exim-ID: 1dYNQG-001a3C-Cm
X-Source: 
X-Source-Args: 
X-Source-Dir: 
X-Source-Sender: cpe-45-48-239-195.socal.res.rr.com (server.local)
 [45.48.239.195]:50042
X-Source-Auth: lawlist
X-Email-Count: 1
X-Source-Cap: bGF3bGlzdDtsYXdsaXN0O2dhdG9yMzA1My5ob3N0Z2F0b3IuY29t
X-Local-Domain: yes
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
 [fuzzy]
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -3.5 (---)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.5 (---)

I have modified versions of undo-tree.el and the cl family of functions (with different names [e.g., "lcl-..."] that use the old-style defstruct), which may be able to still take advantage of the vector method of dealing with structs.  I am receiving a message "Re-entering top level after C stack overflow".  It appears that `read` can no longer handle the following type of structure, perhaps because there is no built-in backwards compatibility -- this is a small example of the what `read` is able to handle in earlier versions of Emacs, but not the current master branch:

[cl-struct-undo-tree [nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil ([nil (#1=[nil nil ((26 . 27)) nil (22874 59645 117315 0) 0 nil (((22874 59645 117309 0) . t)) nil nil]) ((25 . 26)) nil (22874 59645 117331 0) 0 nil (((22874 59645 107309 0))) nil nil]) ((24 . 25)) nil (22874 59645 117335 0) 0 nil (((22874 59645 97309 0))) nil nil]) ((23 . 24)) nil (22874 59645 117339 0) 0 nil (((22874 59645 87309 0))) nil nil]) ((22 . 23)) nil (22874 59645 117343 0) 0 nil (((22874 59645 77309 0))) nil nil]) ((21 . 22)) nil (22874 59645 117347 0) 0 nil (((22874 59645 67309 0))) nil nil]) ((20 . 21)) nil (22874 59645 117351 0) 0 nil (((22874 59645 57309 0))) nil nil]) ((19 . 20)) nil (22874 59645 117354 0) 0 nil (((22874 59645 47309 0))) nil nil]) ((18 . 19)) nil (22874 59645 117358 0) 0 nil (((22874 59645 37309 0))) nil nil]) ((17 . 18)) nil (22874 59645 117363 0) 0 nil (((22874 59645 27309 0))) nil
  nil]) ((16 . 17)) nil (22874 59645 117366 0) 0 nil (((22874 59645 17309 0))) nil nil]) ((15 . 16)) nil (22874 59645 117370 0) 0 nil (((22874 59645 7309 0))) nil nil]) ((14 . 15)) nil (22874 59645 117374 0) 0 nil (((22874 59644 997309 0))) nil nil]) ((13 . 14)) nil (22874 59645 117378 0) 0 nil (((22874 59644 987309 0))) nil nil]) ((12 . 13)) nil (22874 59645 117382 0) 0 nil (((22874 59644 977309 0))) nil nil]) ((11 . 12)) nil (22874 59645 117386 0) 0 nil (((22874 59644 967309 0))) nil nil]) ((10 . 11)) nil (22874 59645 117390 0) 0 nil (((22874 59644 957309 0))) nil nil]) ((9 . 10)) nil (22874 59645 117394 0) 0 nil (((22874 59644 947309 0))) nil nil]) ((8 . 9)) nil (22874 59645 117398 0) 0 nil (((22874 59644 937309 0))) nil nil]) ((7 . 8)) nil (22874 59645 117402 0) 0 nil (((22874 59644 927309 0))) nil nil]) ((6 . 7)) nil (22874 59645 117405 0) 0 nil (((22874 59644 917309 0))) nil nil]) ((5 . 6)) nil (22874 59645 117409 0) 0 nil (((22874 59644 907309 0))) nil nil]) ((4 . 5)) nil (228
 74 59645 117413 0) 0 nil (((22874 59644 897309 0))) nil nil]) ((3 . 4)) nil (22874 59645 117417 0) 0 nil (((22874 59644 887309 0))) nil nil]) ((2 . 3)) nil (22874 59645 117420 0) 0 nil (((22874 59644 877309 0))) nil nil]) ((1 . 2) (t 22874 59561 0 0)) nil (22874 59645 117425 0) 0 nil (((22874 59644 867309 0))) nil nil]) nil nil (22874 59632 379899 0) 0 nil (((0 0))) nil nil] #1# 216 26 nil #1#]

Here is the backtrace for the first 20 frames:

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x00007fff5f26ef08
0x000000010023ae38 in read1 (readcharfun=Cannot access memory at address 0x7fff5f26ef08
) at lread.c:2674
2674	{
(gdb) bt
#0  0x000000010023ae38 in read1 (readcharfun=Cannot access memory at address 0x7fff5f26ef08
) at lread.c:2674
#1  0x000000010023eba5 in read_list (flag=true, readcharfun={i = 4773552677}) at lread.c:3866
#2  0x000000010023e7d6 in read_vector (readcharfun={i = 4773552677}, bytecodeflag=false) at lread.c:3776
#3  0x000000010023b01e in read1 (readcharfun={i = 4773552677}, pch=0x7fff5f2777a4, first_in_list=true) at lread.c:2695
#4  0x000000010023eba5 in read_list (flag=false, readcharfun={i = 4773552677}) at lread.c:3866
#5  0x000000010023b001 in read1 (readcharfun={i = 4773552677}, pch=0x7fff5f27bc24, first_in_list=false) at lread.c:2692
#6  0x000000010023eba5 in read_list (flag=true, readcharfun={i = 4773552677}) at lread.c:3866
#7  0x000000010023e7d6 in read_vector (readcharfun={i = 4773552677}, bytecodeflag=false) at lread.c:3776
#8  0x000000010023b01e in read1 (readcharfun={i = 4773552677}, pch=0x7fff5f280134, first_in_list=true) at lread.c:2695
#9  0x000000010023eba5 in read_list (flag=false, readcharfun={i = 4773552677}) at lread.c:3866
#10 0x000000010023b001 in read1 (readcharfun={i = 4773552677}, pch=0x7fff5f2845b4, first_in_list=false) at lread.c:2692
#11 0x000000010023eba5 in read_list (flag=true, readcharfun={i = 4773552677}) at lread.c:3866
#12 0x000000010023e7d6 in read_vector (readcharfun={i = 4773552677}, bytecodeflag=false) at lread.c:3776
#13 0x000000010023b01e in read1 (readcharfun={i = 4773552677}, pch=0x7fff5f288ac4, first_in_list=true) at lread.c:2695
#14 0x000000010023eba5 in read_list (flag=false, readcharfun={i = 4773552677}) at lread.c:3866
#15 0x000000010023b001 in read1 (readcharfun={i = 4773552677}, pch=0x7fff5f28cf44, first_in_list=false) at lread.c:2692
#16 0x000000010023eba5 in read_list (flag=true, readcharfun={i = 4773552677}) at lread.c:3866
#17 0x000000010023e7d6 in read_vector (readcharfun={i = 4773552677}, bytecodeflag=false) at lread.c:3776
#18 0x000000010023b01e in read1 (readcharfun={i = 4773552677}, pch=0x7fff5f291454, first_in_list=true) at lread.c:2695
#19 0x000000010023eba5 in read_list (flag=false, readcharfun={i = 4773552677}) at lread.c:3866
#20 0x000000010023b001 in read1 (readcharfun={i = 4773552677}, pch=0x7fff5f2958d4, first_in_list=false) at lread.c:2692

***




Acknowledgement sent to Keith David Bershatsky <esq@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#27779; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Mon, 25 Nov 2019 12:00:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.