Subject: bug#11236: 24.1.50; Maximum buffer size exceeded

From: Eli Zaretskii <[email-masked]>
Date: Fri, 13 Apr 2012 18:31:37 +0300

> From: Peter Dyballa <[email-masked]>
> Date: Fri, 13 Apr 2012 16:04:29 +0200
> 
> When I try 'make bootstrap' on PPC Mac OS X 10.5.8 (Leopard) for a  
> GTK2 or Athena/libXaw3d X client or the NS variant the build process  
> each time ends here:
> 
> 	Loading loadup.el (source)...
> 	Using load-path (.../emacs-24.1.50/lisp .../emacs-24.1.50/lisp/emacs- 
> lisp .../emacs-24.1.50/lisp/language .../emacs-24.1.50/lisp/ 
> international .../emacs-24.1.50/lisp/textmodes)
> 	Loading emacs-lisp/byte-run (source)...
> 	Loading emacs-lisp/backquote (source)...
> 	Loading subr (source)...
> 	Loading version.el (source)...
> 	Loading widget (source)...
> 	Loading custom (source)...
> 	Loading emacs-lisp/map-ynp (source)...
> 	Loading international/mule (source)...
> 	Loading international/mule-conf (source)...
> 	Loading env (source)...
> 	Loading format (source)...
> 	Loading bindings (source)...
> 	Loading cus-start (source)...
> 	Loading window (source)...
> 	Loading .../emacs-24.1.50/lisp/files.el (source)...
> 	Maximum buffer size exceeded
> 	make[2]: *** [bootstrap-emacs] Error 1
> 	make[1]: *** [src] Error 2
> 	make: *** [bootstrap] Error 2

Can you run under a debugger, but a breakpoint inside buffer_overflow,
and when it breaks, look around in make_gap_larger and see why exactly
this overflow happens?  E.g., what are the values of current_size and
of nbytes_added?  Please compile without optimizations, to make
debugging reliable.