Show
Ignore:
Timestamp:
10/01/09 22:19:42 (5 years ago)
Author:
robert
Message:

Introduced new BufferObject? design + implementation in preperation of implementing a pool system for buffer objects

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • OpenSceneGraph/trunk/src/osgPlugins/ive/DrawElementsUInt.cpp

    r7648 r10600  
    3535    // Write array length and its elements. 
    3636    out->writeInt(size()); 
    37     out->writeCharArray((const char*)&front(), size() * INTSIZE); 
     37    if (size()!=0) out->writeCharArray((const char*)&front(), size() * INTSIZE); 
    3838} 
    3939 
     
    5656        int size = in->readInt(); 
    5757        resize(size); 
    58         in->readCharArray((char*)&front(), size * INTSIZE); 
     58        if (size!=0) in->readCharArray((char*)&front(), size * INTSIZE); 
    5959 
    6060        if (in->_byteswap)