Пример #1
0
 /* switch to _view_write.  normally, this is a bad idea since your changes will not
    show up in _view_private if there have been changes there; thus the leading underscore
    as a tad of a "warning".  but useful when done with some care, such as during
    initialization.
 */
 void* MongoMMF::_switchToWritableView(void *p) {
     size_t ofs;
     MongoMMF *f = privateViews.find(p, ofs);
     assert( f );
     return (((char *)f->_view_write)+ofs);
 }