From 1c909afe3998778e4cc045c9ab733e8afbf7c25b Mon Sep 17 00:00:00 2001 From: Don Kjer Date: Wed, 2 May 2007 21:24:47 +0000 Subject: svn merge -r 60342:61148 svn+ssh://svn/svn/linden/branches/maintenance into release --- indra/newview/llpatchvertexarray.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'indra/newview/llpatchvertexarray.cpp') diff --git a/indra/newview/llpatchvertexarray.cpp b/indra/newview/llpatchvertexarray.cpp index 62f8ac87bb..0278ba32f8 100644 --- a/indra/newview/llpatchvertexarray.cpp +++ b/indra/newview/llpatchvertexarray.cpp @@ -106,8 +106,16 @@ void LLPatchVertexArray::create(U32 surface_width, U32 patch_width, F32 meters_p mRenderStridep = new U32 [mPatchOrder + 1]; } + if (NULL == mRenderLevelp || NULL == mRenderStridep) + { + // init() and some other things all want to deref these + // pointers, so this is serious. + llerrs << "mRenderLevelp or mRenderStridep was NULL; we'd crash soon." << llendl; + return; + } - // Now that we've allocated memory, we can initialize the arrays... + // Now that we've allocated memory, we can initialize + // the arrays... init(); } -- cgit v1.2.3