remove mapped_file nullptr if readonly stuff. it causes nothing but headaches.

This commit is contained in:
Kelvin Sherlock 2016-08-12 22:13:48 -04:00
parent 3db689389e
commit e61a54d0cf

View File

@ -95,7 +95,8 @@ public:
}
value_type *data() {
return _flags == readonly ? (value_type *)nullptr : (value_type *)_data;
return (value_type *)_data;
//return _flags == readonly ? (value_type *)nullptr : (value_type *)_data;
}
const_iterator cbegin() const {
@ -116,11 +117,13 @@ public:
iterator begin() {
return _flags == readonly ? (iterator)nullptr : (iterator)_data;
return (iterator)_data;
//return _flags == readonly ? (iterator)nullptr : (iterator)_data;
}
iterator end() {
return _flags == readonly ? (iterator)nullptr : (iterator)_data + size();
return (iterator)_data + size();
//return _flags == readonly ? (iterator)nullptr : (iterator)_data + size();
}
mapmode flags() const {