xref: /aosp_15_r20/external/toolchain-utils/binary_search_tool/ndk/PATCH2 (revision 760c253c1ed00ce9abd48f8546f08516e57485fe)
1*760c253cSXin LiFrom 960134fb87a194595f2a0a36290be7961e12b946 Mon Sep 17 00:00:00 2001
2*760c253cSXin LiFrom: Cassidy Burden <[email protected]>
3*760c253cSXin LiDate: Tue, 9 Aug 2016 09:46:27 -0700
4*760c253cSXin LiSubject: [PATCH] FOR BISECTION TOOL: Insert error
5*760c253cSXin Li
6*760c253cSXin LiInsert error into code that will cause crash. This is the "compiler
7*760c253cSXin Lierror" that we will be triaging. We will be pretending the compiler
8*760c253cSXin Limistakenly inserted a nullptr where it shouldn't have.
9*760c253cSXin Li
10*760c253cSXin LiThis error causes the app to immediately crash upon starting. This makes
11*760c253cSXin Liit very easy to automatically test the app through adb. Not all compiler
12*760c253cSXin Liproblems will be this easy to test, and may require manual testing from
13*760c253cSXin Liyou (the user). See android/interactive_test.sh for an example on
14*760c253cSXin Limanual testing from the user.
15*760c253cSXin Li---
16*760c253cSXin Li Teapot/app/src/main/jni/TeapotRenderer.cpp | 2 +-
17*760c253cSXin Li 1 file changed, 1 insertion(+), 1 deletion(-)
18*760c253cSXin Li
19*760c253cSXin Lidiff --git a/Teapot/app/src/main/jni/TeapotRenderer.cpp b/Teapot/app/src/main/jni/TeapotRenderer.cpp
20*760c253cSXin Liindex 7cafdb3..75cadbf 100644
21*760c253cSXin Li--- a/Teapot/app/src/main/jni/TeapotRenderer.cpp
22*760c253cSXin Li+++ b/Teapot/app/src/main/jni/TeapotRenderer.cpp
23*760c253cSXin Li@@ -58,7 +58,7 @@ void TeapotRenderer::Init() {
24*760c253cSXin Li   num_vertices_ = sizeof(teapotPositions) / sizeof(teapotPositions[0]) / 3;
25*760c253cSXin Li   int32_t stride = sizeof(TEAPOT_VERTEX);
26*760c253cSXin Li   int32_t index = 0;
27*760c253cSXin Li-  TEAPOT_VERTEX* p = new TEAPOT_VERTEX[num_vertices_];
28*760c253cSXin Li+  TEAPOT_VERTEX* p = nullptr; //new TEAPOT_VERTEX[num_vertices_];
29*760c253cSXin Li   for (int32_t i = 0; i < num_vertices_; ++i) {
30*760c253cSXin Li     p[i].pos[0] = teapotPositions[index];
31*760c253cSXin Li     p[i].pos[1] = teapotPositions[index + 1];
32*760c253cSXin Li--
33*760c253cSXin Li2.8.0.rc3.226.g39d4020
34*760c253cSXin Li
35