- Now NetBuffer and DynamicBuffer agree and the smallest buffer size posible.

- This means that buffers with a initial size of 0 work now.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29006 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Bruno G. Albuquerque
2009-01-24 23:42:43 +00:00
parent 52e59b292b
commit ef93221da6
2 changed files with 4 additions and 4 deletions
+1 -1
View File
@@ -14,7 +14,7 @@
class DynamicBuffer {
public:
DynamicBuffer(size_t initialSize = 1);
DynamicBuffer(size_t initialSize = 0);
~DynamicBuffer();
DynamicBuffer(const DynamicBuffer& buffer);
+1 -1
View File
@@ -23,7 +23,7 @@ DynamicBuffer::DynamicBuffer(size_t initialSize) :
fDataEnd(0),
fInit(B_NO_INIT)
{
if (initialSize > 0) {
if (initialSize >= 0) {
fBuffer = new (std::nothrow) unsigned char[initialSize];
if (fBuffer != NULL) {
fBufferSize = initialSize;