Re: Dropping mmap from the virtual file system



Hello,

On Sun, 27 Feb 2005, Roland Illig wrote:

> Roland Illig wrote:
> >>> I would like to drop the mmap() and munmap() methods from the vfs code.
>
> Leonard den Ottolander wrote:
> >> Why?
>
> Roland Illig wrote:
> > To make the source code of mc smaller and better understandable. For the
> > virtual file system, it nearly makes no sense to provide an mmap()
> > method, as most of the filesystems would have to implement it using
> > read() anyways.
> >
> > At least, no vfs other than localfs currently implements the mmap() calls.
> >
> > Another thing is that mmap() does not work reliably on FreeBSD when
> > using it with files in /proc. The Midnight Commander crashes then with a
> > SIGBUS error.
> >
> > There would be two methods less that a vfs implementor has to think about.
>
> And here's the patch to do it. Note that mc is still using mmap(), but
> not in the virtual file system. It does not lose any functionality, just
> code size.
>
> Roland

Please, take a look at the following post:
http://mail.gnome.org/archives/mc-devel/2002-July/msg00093.html



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]