diff options
author | David Kalnischkies <kalnischkies@gmail.com> | 2010-02-27 02:02:25 +0100 |
---|---|---|
committer | David Kalnischkies <kalnischkies@gmail.com> | 2010-02-27 02:02:25 +0100 |
commit | 06afffcc24f339e8735acd4698af6e5995ad24aa (patch) | |
tree | 8360c31e2e53446816eddb8e2610f6bdea0ecc3e /apt-pkg/contrib/mmap.h | |
parent | d1082b44827dc90ddeffb246f3eacfff387a9c5e (diff) |
* apt-pkg/contrib/mmap.{h,cc}:
- add char[] fallback for filesystems without shared writable
mmap() like JFFS2. Thanks to Marius Vollmer for writing
and to Loïc Minier for pointing to the patch! (Closes: #314334)
Diffstat (limited to 'apt-pkg/contrib/mmap.h')
-rw-r--r-- | apt-pkg/contrib/mmap.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/apt-pkg/contrib/mmap.h b/apt-pkg/contrib/mmap.h index cd2b15ba2..5ca951204 100644 --- a/apt-pkg/contrib/mmap.h +++ b/apt-pkg/contrib/mmap.h @@ -44,6 +44,11 @@ class MMap unsigned long iSize; void *Base; + // In case mmap can not be used, we keep a dup of the file + // descriptor that should have been mmaped so that we can write to + // the file in Sync(). + FileFd *SyncToFd; + bool Map(FileFd &Fd); bool Close(bool DoSync = true); |