|
Lines 278-284
uchar Reader::operator[] (off_t offset)
Link Here
|
| 278 |
"attempt to access past end of file"); |
278 |
"attempt to access past end of file"); |
| 279 |
|
279 |
|
| 280 |
off_t page_idx = offset/_pageSize; |
280 |
off_t page_idx = offset/_pageSize; |
|
|
281 |
#ifdef NDEBUG |
| 282 |
(void)loadPage( page_idx ); |
| 283 |
#else |
| 281 |
assert( loadPage( page_idx ) ); |
284 |
assert( loadPage( page_idx ) ); |
|
|
285 |
#endif |
| 282 |
return _data[page_idx][ offset%_pageSize ]; |
286 |
return _data[page_idx][ offset%_pageSize ]; |
| 283 |
} |
287 |
} |
| 284 |
|
288 |
|