[GPL GS WORKS] evince (gs-esp) memory leak opening .eps files

Bug #75894 reported by Niall Creech
50
Affects Status Importance Assigned to Milestone
evince (Ubuntu)
Invalid
Undecided
Unassigned
gs-esp (Ubuntu)
Fix Released
High
Unassigned

Bug Description

Binary package hint: evince

when opening some .eps files evince grows to use up all system memory. on the few .eps files i have this doesnt happen, so far i have only one file that causes the problem (attached). This happens with the attached file when running gs-esp directly as well so this may not be the place to file this bug. attached is also a strace.

version info:
evince 0.6.1-0ubuntu3
gs-esp 8.15.3.dfsg1-2ubuntu1
(ubuntu feisty)

Revision history for this message
Niall Creech (sevenmachines-deactivatedaccount) wrote :

the problem file

Revision history for this message
Niall Creech (sevenmachines-deactivatedaccount) wrote :

strace before killing process before memory leak freezes desktop

Revision history for this message
burkaygenc (bgenc) wrote :

I am the creator of the above eps file and I have more examples that expose the same leak.
Here is one example:

Revision history for this message
burkaygenc (bgenc) wrote :

and another one...

Revision history for this message
Sebastien Bacher (seb128) wrote :

Thank you for your bug. evince only use gs-esp which has the same problem with that example, reassinging

Revision history for this message
fogman (sv) wrote :

Same problem here.

sudo apt-get install gs-gpl
sudo update-alternatives --config gs (<-choosing gs-gpl)

fixed it form me now.

Changed in gs-esp:
assignee: nobody → sv
Changed in gs-esp:
importance: Undecided → Medium
status: Unconfirmed → Confirmed
assignee: sv → nobody
Revision history for this message
yostral (y-o) wrote :

Evince with the default gs (gs-esp) can't show the content of ps files. Files for exemple printed with firefox or gedit.

It doesn't grow up the system memory, but nothing appears.

With gs-gpl all is fine.

Revision history for this message
Sebastien Bacher (seb128) wrote :

not an evince bug

Changed in evince:
status: Unconfirmed → Rejected
Revision history for this message
StefanPotyra (sistpoty) wrote :

if you need more samples, feel free to ask, as I'm stumbling on the problem as well. (Basically it happens all the time for me when exporting eps from dia diagrams).

Cheers,
    Stefan.

Revision history for this message
Claudiu Vlad (claudiu-vlad) wrote :

I saw the same memory leak when printing to pdf from konqueror. How can I help? I would like to attach here a trace or something...

Revision history for this message
fogman (sv) wrote :

Hello Stefan,

the exporting from dia (version 0.9.6?) to eps doesn't work at the moment.
Either dia is using some strange ps-commands or gs-esp isn't capable of interpreting those commands?
For example: "sh" is now "ashow" in dia? and so on.

I switched to inkscape because i'm not able to wait since i'am working on my thesis.

greetings, fogman.

Revision history for this message
Johan Christiansen (johandc) wrote :

 * Same problem here.
 * Confirmed that it happens to figures exported from Dia.
 * Also confirmed that shifting to gs-gpl solve the problem.

Revision history for this message
Steven S (mintcoffee) wrote :

Using LyX and generating PDF file causes gs-esp to leak memory on feisty. Switching to gs-gpl fixed the problem as well.

Revision history for this message
Ashton Batty (ashton) wrote :

Ouch. I just got hit by this when trying to insert an .eps into OpenOffice 2.2. Within seconds gs was using over 1gb of memory, and the computer was extremely unresponsive.

Dia export to EPS using Pango fonts didn't cause any trouble, but using Latin-1 fonts did.

Revision history for this message
Michael R. Head (burner) wrote :

RE: dia and this bug, I only am affected when I use the "eps-builtin" export, not the "eps-pango" export.

Revision history for this message
Claudiu Vlad (claudiu-vlad) wrote :

As of April 19th, GS-GPL works ok in feisty. I think the bug should be closed.

Revision history for this message
Michael R. Head (burner) wrote :

But the problem is that gs-esp doesn't work, not gs-gpl. What's more, gs-esp is the default and memory allocation bombs that occur when an eps file shows up in nautilus is a pretty big denial of service bug.

Or did you mean to say gs-esp is working?

Revision history for this message
Claudiu Vlad (claudiu-vlad) wrote :

I meant gs-esp is working ok for me now, and I must mention I am using kubuntu feisty, upgraded from edgy, upgraded from dapper, upgraded from breezy. Maybe others should check this also, in order to close this bug.

[11:21][claudiu:/>~]$ sudo update-alternatives --config gs
Password:

Există 2 alternative care furnizează „gs”.

  Selecţia Alternativa
-----------------------------------------------
*+ 1 /usr/bin/gs-esp
          2 /usr/bin/gs-gpl

Apăsaţi enter pentru a păstra valoarea implicită[*], sau introduceţi numărul selecţiei:

Revision history for this message
Ashton Batty (ashton) wrote :

Just tested. Bug still present for me, on a current Feisty machine. What is more, it seems that closing Evince alone doesn't kill the gs process... considering the possible DoS aspect of this bug, maybe it warrants more than a Medium importance?

Changed in gs-esp:
importance: Medium → High
Revision history for this message
Vincenzo Ciancia (vincenzo-ml) wrote :

Not only eps, also normal postscript files can make a system unusable at a point that even ctrl+alt+backspace will not allow you to get a shell. Just put the attached ps on your desktop, and nautilus will try to get a thumbnail, resulting in your system becoming unusable automatically at login (this happened to me).

Revision history for this message
Vincenzo Ciancia (vincenzo-ml) wrote :

I forgot to mention that the attached file is normally visible and "thumbnail-able" in edgy, where it was produced using mpage.

Revision history for this message
Andrej Prša (andrej-prsa) wrote :

Confirming this issue in Feisty for any powerpoint slide exported to .eps (an example attached). Switching to gs-gpl solves the problem.

Revision history for this message
bhaagensen (bhaagensen) wrote :

Hi, everybody.

Confirming bug. gs-esp will consume all memory when attempting to open the attached postscript file. It's a latex generated file, don't remember the details on how it was generated. The file is many years old and I've never had problems opening it on lots of systems. gs-gpl solves the problem.

Changed in gs-esp:
status: Confirmed → In Progress
Revision history for this message
Michael Nagel (nailor) wrote :

i have installed kile on my machine, and navigating nautilus to a project folder where there are *.eps files (auto-generated from jpegs and pngs i include) the bug will trigger reproducably.
this is *very* annoying and definitely a regression compared to edgy.

Revision history for this message
Marie (chaahrazade) wrote :

Hi everybody,

Same problem with latex, when attempting to view some dvi file or to convert them into pdf. gs-eps will consume all the memory and the computer eventually freeze.

gs-gpl solved the problem for the time being, thanks.

Revision history for this message
VladBlanton (vblanton) wrote :

I would like to say that I can reproduce this bug in Ubuntu 7.04 (Fiesty).

I first came across this bug in Inkscape when trying to save an svg I was working on in the .ai (Adobe Illustrator) format. installing gs-gpl and switching to it (using the program galternatives, or through the command line as mentioned above) fixed the issue for me. Still, GS-ESP is the default GS and this serious memory leak needs to be plugged. Googling hasn't shown me that anyone else/nor upstream knows about this issue. Could it be an ubuntu repackaging breakage? I can't imagine something so serious not being caught relatively quickly the gs-esp release.

Perhaps a shout to the gs-esp mailing list may be worth a go

Calling gs-esp from the command line also causes this serious mem leak.

Revision history for this message
VladBlanton (vblanton) wrote :

Bug:
https://bugs.launchpad.net/ubuntu/+source/gs-esp/+bug/108159

seems to be a duplicate and visa-versa. Both are set to high priority without anyone assigned to it as of this writing.

Changed in gs-esp:
status: In Progress → Fix Committed
Changed in gs-esp:
status: Fix Committed → Fix Released
Revision history for this message
Antti Kaihola (akaihola) wrote :

Here's a way to generate a PostScript file and process it with gs, causing the symptoms described above. First apt-get install mpage, then try this:
$ echo Test | mpage -b A4 -L 62 -1o - | ps2pdf -sPAPERSIZE=a4 - test.pdf

This is from https://bugs.launchpad.net/ubuntu/+source/mpage/+bug/116376

Revision history for this message
echienne (etienne-mouragnon) wrote :

I had the same problem using kubuntu feisty, just upgraded from edgy: working with gs-gpl

I am making illustations with dia and exporting to eps format for including into latex.
The problem is: text in eps files generated with feisty doesn't look like the same text in eps files generated with edgy (with the same dia file!).
That is annoying because I would like new pictures to be like older ones.
an example in attachment

Revision history for this message
echienne (etienne-mouragnon) wrote :

sorry for the file size

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.