GNU bug report logs - #20220
severe memory leak on emacs 24.4.1

Previous Next

Package: emacs;

Reported by: Mario Valencia <mariovalspi <at> gmail.com>

Date: Sat, 28 Mar 2015 23:40:03 UTC

Severity: normal

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#20220: closed (severe memory leak on emacs 24.4.1)
Date: Thu, 23 Apr 2015 07:19:02 +0000
[Message part 1 (text/plain, inline)]
Your message dated Thu, 23 Apr 2015 10:18:27 +0300
with message-id <834mo72tz0.fsf <at> gnu.org>
and subject line Re: bug#20220: severe memory leak on emacs 24.4.1
has caused the debbugs.gnu.org bug report #20220,
regarding severe memory leak on emacs 24.4.1
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
20220: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=20220
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Mario Valencia <mariovalspi <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: severe memory leak on emacs 24.4.1
Date: Sat, 28 Mar 2015 17:39:38 -0600
[Message part 3 (text/plain, inline)]
to reproduce it, i create a small emtpy html document. then i evaluate the
following expression:

(dotimes (i 100) (browse-url-of-file))

This causes emacs to start opening the file using google chrome. In the
task manager, i can see emacs' memory usage go up by about 5 megabytes each
time a tab is opened. When it opens about 30 tabs, emacs is using 138
megabytes of memory, and it gives the error below.
the translation is something like this: "ShellExecute failed: Storage space
insufficient to process this command"
My harddrive has enough storage space btw.

I was able to reproduce this bug 3 times. I ran emacs with -Q on windows 8.
Im using emacs version:
GNU Emacs 24.4.1 (i686-pc-mingw32)
 of 2014-10-24 on LEG570

Debugger entered--Lisp error: (error "ShellExecute failed: Espacio de
almacenamiento insuficiente para procesar este comando.")
  w32-shell-execute("open" "file:///c:/Users/mario/Desktop/x.html")

browse-url-default-windows-browser("file:///c:/Users/mario/Desktop/x.html"
nil)
  apply(browse-url-default-windows-browser
"file:///c:/Users/mario/Desktop/x.html" nil)
  browse-url-default-browser("file:///c:/Users/mario/Desktop/x.html" nil)
  apply(browse-url-default-browser "file:///c:/Users/mario/Desktop/x.html"
nil)
  browse-url("file:///c:/Users/mario/Desktop/x.html")
  browse-url-of-file("c:/Users/mario/Desktop/x.html")
  browse-url-of-buffer()
  (while (< i --dotimes-limit--) (browse-url-of-buffer) (setq i (1+ i)))
  (let ((--dotimes-limit-- 100) (i 0)) (while (< i --dotimes-limit--)
(browse-url-of-buffer) (setq i (1+ i))))
  (dotimes (i 100) (browse-url-of-buffer))
  eval((dotimes (i 100) (browse-url-of-buffer)) nil)
  eval-expression((dotimes (i 100) (browse-url-of-buffer)) nil)
  call-interactively(eval-expression nil nil)
  command-execute(eval-expression)

In GNU Emacs 24.4.1 (i686-pc-mingw32)
 of 2014-10-24 on LEG570
Windowing system distributor `Microsoft Corp.', version 6.3.9600
Configured using:
 `configure --prefix=/c/usr'

Important settings:
  value of $LANG: ESM
  locale-coding-system: cp1252

Major mode: Fundamental

Minor modes in effect:
  tooltip-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  buffer-read-only: t
  line-number-mode: t
  transient-mark-mode: t

Recent input:
<help-echo> C-x C-f <backspace> <backspace> <backspace>
<backspace> <backspace> <backspace> <backspace> <backspace>
<backspace> <backspace> <backspace> <backspace> <backspace>
<backspace> <backspace> x . h m l <backspace> <backspace>
t m l <return> C-k C-k C-k C-k C-k C-k C-k C-k C-k
C-k C-k C-x C-s M-: <up> ( d o t i m e s - <backspace>
SPC ( i SPC 1 0 0 ) SPC ( b r o w s e - u r l <tab>
<backspace> <backspace> <backspace> b u f <tab> ) )
<return> C-a <S-down> <S-down> <S-down> <S-down> <S-down>
<S-down> <S-down> <S-down> <S-down> <S-down> <S-down>
<S-down> <S-down> <S-down> <S-down> <S-down> <S-down>
<S-down> <S-down> <S-down> <S-down> <S-down> M-w <help-echo>
e i <return> <help-echo> <help-echo> <help-echo> q
C-h C-a <down> <S-down> <S-down> C-c <help-echo> <help-echo>
<help-echo> <help-echo> <help-echo> M-w M-w <help-echo>
<help-echo> <help-echo> M-x r e p o r t - e m <tab>
<return>

Recent messages:
Wrote c:/Users/mario/Desktop/x.html
user-error: Beginning of history; no preceding item
Entering debugger...
Mark set
End of buffer [6 times]
Saved text from "Debugger entered--Lisp error: (error "Sh"
30 (#o36, #x1e, ?\C-^)
Back to top level.
Mark set
C-c M-w is undefined

Load-path shadows:
None found.

Features:
(shadow sort gnus-util mail-extr emacsbug message format-spec rfc822 mml
mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev
gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util
help-fns mail-prsvr mail-utils mule-util help-mode easymenu debug
browse-url sgml-mode time-date tooltip electric uniquify ediff-hook
vc-hooks lisp-float-type mwheel dos-w32 ls-lisp w32-common-fns
disp-table w32-win w32-vars tool-bar dnd fontset image regexp-opt fringe
tabulated-list newcomment lisp-mode prog-mode register page menu-bar
rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax
facemenu font-core frame cham georgian utf-8-lang misc-lang vietnamese
tibetan thai tai-viet lao korean japanese hebrew greek romanian slovak
czech european ethiopic indian cyrillic chinese case-table epa-hook
jka-cmpr-hook help simple abbrev minibuffer nadvice loaddefs button
faces cus-face macroexp files text-properties overlay sha1 md5 base64
format env code-pages mule custom widget hashtable-print-readable
backquote make-network-process w32notify w32 multi-tty emacs)

Memory information:
((conses 8 82170 4244)
 (symbols 32 17933 0)
 (miscs 32 88 151)
 (strings 16 12976 3656)
 (string-bytes 1 327227)
 (vectors 8 10094)
 (vector-slots 4 391999 3862)
 (floats 8 61 285)
 (intervals 28 398 48)
 (buffers 508 15))
[Message part 4 (text/html, inline)]
[Message part 5 (message/rfc822, inline)]
From: Eli Zaretskii <eliz <at> gnu.org>
To: mariovalspi <at> gmail.com
Cc: 20220-done <at> debbugs.gnu.org
Subject: Re: bug#20220: severe memory leak on emacs 24.4.1
Date: Thu, 23 Apr 2015 10:18:27 +0300
> Date: Fri, 10 Apr 2015 14:24:18 +0300
> From: Eli Zaretskii <eliz <at> gnu.org>
> Cc: 20220 <at> debbugs.gnu.org
> 
> > Date: Fri, 10 Apr 2015 06:16:46 -0500
> > From: Mario Valencia <mariovalspi <at> gmail.com>
> > Cc: Daniel Colascione <dancol <at> dancol.org>, Stefan Monnier <monnier <at> iro.umontreal.ca>, 20220 <at> debbugs.gnu.org
> > 
> > You are correct; the problem only happens with a file:/// url. The following
> > executes without problem and emacs memory stays constant:
> > (dotimes (i 100) (w32-shell-execute "open" "c:/users/mario/desktop/x.html"))
> > With a file:/// url it triggers the bug:
> > (dotimes (i 100) (w32-shell-execute "open"
> > "file:///c:/users/mario/desktop/x.html"))
> 
> Thanks, that's good to know.
> 
> So I think the solution is to change w32-shell-execute to convert
> file:/// URLs into the normal file-name format internally, and use
> that in the call to ShellExecute.

Now done in the development sources for Emacs 25.1 (commit f2e2cd5).

I'm closing this bug.  Feel free to reopen if some new information
emerges about this.


This bug report was last modified 10 years and 29 days ago.

Previous Next


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