summaryrefslogtreecommitdiff
path: root/utests
diff options
context:
space:
mode:
authorYan Wang <yan.wang@linux.intel.com>2014-12-09 12:57:52 +0800
committerZhigang Gong <zhigang.gong@intel.com>2014-12-16 16:06:02 +0800
commit430284d29039a52f7ccefab33e9fbd6e538f0fdb (patch)
tree3b00f88181b40d35a45aa7dc4f82d88201b944a9 /utests
parentbc0febf1f466bb13601c62fd7e8159eda463544d (diff)
Fix delete operator using.
The 2 delete operators work on array pointer. Signed-off-by: Yan Wang <yan.wang@linux.intel.com> Reviewed-by: Zhigang Gong <zhigang.gong@linux.intel.com>
Diffstat (limited to 'utests')
-rw-r--r--utests/compiler_fill_gl_image.cpp2
-rw-r--r--utests/utest_helper.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/utests/compiler_fill_gl_image.cpp b/utests/compiler_fill_gl_image.cpp
index 87d2fcd6..f1eb8e78 100644
--- a/utests/compiler_fill_gl_image.cpp
+++ b/utests/compiler_fill_gl_image.cpp
@@ -70,7 +70,7 @@ static void compiler_fill_gl_image(void)
for (uint32_t i = 0; i < w; i++)
OCL_ASSERT(resultColor[j * w + i] == color);
OCL_UNMAP_BUFFER(0);
- delete resultColor;
+ delete[] resultColor;
}
MAKE_UTEST_FROM_FUNCTION(compiler_fill_gl_image);
diff --git a/utests/utest_helper.cpp b/utests/utest_helper.cpp
index 606c1bfc..591054e9 100644
--- a/utests/utest_helper.cpp
+++ b/utests/utest_helper.cpp
@@ -401,7 +401,7 @@ cl_ocl_init(void)
error:
if (props)
- delete props;
+ delete[] props;
return status;
}