[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
What's the point to keep mmaped objectfile opened?
From: |
rixed |
Subject: |
What's the point to keep mmaped objectfile opened? |
Date: |
Tue, 13 Dec 2011 11:15:14 +0100 |
User-agent: |
Mutt/1.5.20 (2009-06-14) |
I'm a little worried by the amount of file descriptors left opened
after the objcode is mmaped.
I saw this "note to self" from objcodes.c:
/* FIXME: we leak ourselves and the file descriptor. but then again so does
dlopen(). */
So apparently the author was well aware of the problem but decided to
ignore it, despite the fd being used nowhere as far as I can see
(also, I don't understand the remark about dlopen leaking a fd).
Anyway, the attached patch (which closes the fd and stores -1 inplace
of it in the cell) seams to works and seams to fix the issue (ie. no more
pending opened fd for .go files)
guile-close-fd-on-mmap.patch
Description: Text Data
- What's the point to keep mmaped objectfile opened?,
rixed <=