Euh... to be clear, this isn't related to the MMAP buckets, right? You're talking about the MMAP interface.
I would agree: the offset seems rather bogus. Why not just return the ptr/len of the mmap and let the user add to the pointer (as necessary). Oh, christ. Looking at the function, that is exactly what it does. A pointer add. Let's toss the darn function. And while looking at apr_mmap.h: why is the structure public? Ack! That guy should be private. Cheers, -g On Wed, Jun 06, 2001 at 02:04:41PM -0500, William A. Rowe, Jr. wrote: > LARGEFILE support errors threw me into win32's mmap code. This got me looking > at the mmap bucket support. I'll accept we should never be dumping 4+GB out > the > socket, but it opened my eyes to this quandry. > > What ARE the offset and size arguments? If the mmap_create call sets aside a > maximum 'window' into the file, and mmap_offset merely adjusts the offset, > then > I argue mmap_offset is worthless. IF, otoh, mmap_offset allows us change the > 'viewport' offset, then we need to know what the size of that viewport became. > > It's a goofy semantic altogether. Either mmap_offset grows a size, or goes > away. > It doesn't matter to me if its a size that the user specifies, or only a > return > value for the size of the available window. > > Bill > > p.s. I'm offline for a day and a half, if you find problems with the largefile > stuff, sendfile, read, write or seek changes, please feel free to fix them and > I'll review after they are committed. -- Greg Stein, http://www.lyra.org/
