diff --git a/src/osgPlugins/ive/Text.cpp b/src/osgPlugins/ive/Text.cpp index 0031a0810..ae9da298f 100644 --- a/src/osgPlugins/ive/Text.cpp +++ b/src/osgPlugins/ive/Text.cpp @@ -129,7 +129,8 @@ void Text::write(DataOutputStream* out){ else { // do it the hardway...output each character as an int - osg::ref_ptr strarr = new osg::UIntArray(textstring.size()); + osg::ref_ptr strarr = new osg::UIntArray(); + strarr->reserve(textstring.size()); for(itr=textstring.begin(); itr!=textstring.end();