aboutsummaryrefslogtreecommitdiffstats
path: root/src/alloc/alloc_mmap
Commit message (Collapse)AuthorAgeFilesLines
* s/u32bit/size_t/ in alloclloyd2010-10-122-6/+18
| | | | Also handle partial writes in alloc_mmap
* Use a full write instead of seek+write to create a sparselloyd2010-10-121-9/+7
| | | | | file. FreeBSD's man page for mmap warns that using NOSYNC with sparse files causes problems. Closes PR 30
* Cast the first argument to msync, munmap, mlock, and munlock to char*lloyd2010-09-071-2/+2
| | | | | to fix compilation on Solaris. Everybody else, including POSIX.1, uses void* here, but as usual Solaris likes to be special.
* Doxygenlloyd2010-06-211-1/+4
|
* More Doxygen fixeslloyd2010-06-151-2/+5
|
* Change how alloc_mmap's TemporaryFile class works. Don't exposelloyd2010-06-131-10/+17
| | | | | | | | | | | | | | | | | | | | | | the name at all; instead unlink it at the end of the constructor, so by the time it is fully constructed it is purely an anonymous file descriptor. mkstemp has a weird interface and returns the final name of the file in its template argument. This prevented us from using a std::string, since c_str's return is const (and we can't use &string[0], because that might not be NULL-terminated). This previously required doing nasty things like explicit new/delete and using strcpy (the strcpy was what got me started on looking at this; OpenBSD complains about it, so I was trying to figure out a good way to remove it). Instead, use the idea from http://www.gotw.ca/gotw/042.htm, and use a std::vector to hold the mkstemp argument/result. That works consistently everywhere, and we don't need to rely on strcpy, and don't have to worry about memory leaks either. Only minor nit is having to add an explicit NULL terminator as the std::string doesn't contain it.
* Make many more headers internal-only.lloyd2009-12-163-5/+11
| | | | | | | | | | | | | Fixes for the amalgamation generator for internal headers. Remove BOTAN_DLL exporting macros from all internal-only headers; the classes/functions there don't need to be exported, and avoiding the PIC/GOT indirection can be a big win. Add missing BOTAN_DLLs where necessary, mostly gfpmath and cvc For GCC, use -fvisibility=hidden and set BOTAN_DLL to the visibility __attribute__ to export those classes/functions.
* Move most code that relies heavily on Filters into src/filters.lloyd2009-11-171-6/+0
| | | | | | Remove support for (unused) modset settings. Move tss, fpe, cryptobox, and aont to new dir constructs
* Remove the 'realname' attribute on all modules and cc/cpu/os info files.lloyd2009-10-291-2/+0
| | | | | Pretty much useless and unused, except for listing the module names in build.h and the short versions totally suffice for that.
* Add support for Dragonfly BSD (a fork of FreeBSD).lloyd2009-07-251-0/+1
| | | | Contributed by Patrick Georgi
* Add a script that reads the output of print_deps.py and rewriteslloyd2009-07-151-0/+4
| | | | | | the info.txt files with the right module dependencies. Apply it across the codebase.
* Thomas Moschny passed along a request from the Fedora packagers which camelloyd2009-03-302-20/+24
| | | | | | | | | | | | | | | up during the Fedora submission review, that each source file include some text about the license. One handy Perl script later and each file now has the line Distributed under the terms of the Botan license after the copyright notices. While I was in there modifying every file anyway, I also stripped out the remainder of the block comments (lots of astericks before and after the text); this is stylistic thing I picked up when I was first learning C++ but in retrospect it is not a good style as the structure makes it harder to modify comments (with the result that comments become fewer, shorter and are less likely to be updated, which are not good things).
* Check the return value of lseek in the mmap allocatorlloyd2009-03-271-1/+3
|
* Rickard Bondesson reported on botan-devel about some problems buildinglloyd2008-12-021-8/+0
| | | | | | | | | | | | | | | | | | | | on Solaris 10 with GCC 3.4.3. First, remove the definition of _XOPEN_SOURCE_EXTENDED=1 in mmap_mem.cpp and unix_cmd.cpp, because apparently on Solaris defining this macro breaks C++ compilation entirely with GCC: http://bugs.opensolaris.org/bugdatabase/view_bug.do?bug_id=6395191 In es_egd.cpp and es_dev.cpp, include <fcntl.h> to get the declaration of open(), which is apparently where open(2) lives on Solaris - this matches the include the *BSD man pages for open(2) show, though AFAIK the BSDs all compiled fine without it (probably due to greater efforts to be source-compatible with Linux systems by *BSD developers). I have not been able to test these changes personally on Solaris but Rickard reports that with these changes everything compiles OK. Update lib version to 1.8.0-pre. ZOMG. Finally.
* Add BOTAN_DLL macro to public class definitions that were missing it.lloyd2008-10-091-1/+1
|
* Move allocator base code into core/, alloc_mmap to alloc/lloyd2008-09-303-0/+181