summaryrefslogtreecommitdiff
path: root/indra/llcorehttp/tests/test_allocator.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llcorehttp/tests/test_allocator.cpp')
-rw-r--r--indra/llcorehttp/tests/test_allocator.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/indra/llcorehttp/tests/test_allocator.cpp b/indra/llcorehttp/tests/test_allocator.cpp
index 926de0a208..ea12dc58eb 100644
--- a/indra/llcorehttp/tests/test_allocator.cpp
+++ b/indra/llcorehttp/tests/test_allocator.cpp
@@ -166,13 +166,19 @@ void * operator new[](std::size_t size) THROW_BAD_ALLOC()
void operator delete(void * p) THROW_NOTHING()
{
- FreeMem( p );
+ if (p)
+ {
+ FreeMem( p );
+ }
}
void operator delete[](void * p) THROW_NOTHING()
{
- FreeMem( p );
+ if (p)
+ {
+ FreeMem( p );
+ }
}