The usual C++ response: for backwards compatibility, because data was not required to null-terminate prior to C++11.