From c94d9685b644da6ebb52c92d7e85dc24fce84766 Mon Sep 17 00:00:00 2001 From: Changming Sun Date: Thu, 28 May 2020 10:06:16 -0700 Subject: [PATCH] Fix a problem in StacktraceTests::BasicTests (#4069) result.size() could be zero, in this case, we shouldn't access result[0] --- onnxruntime/test/platform/windows/stacktrace_test.cc | 3 --- 1 file changed, 3 deletions(-) diff --git a/onnxruntime/test/platform/windows/stacktrace_test.cc b/onnxruntime/test/platform/windows/stacktrace_test.cc index 0e07096a37..4cff8ac9cc 100644 --- a/onnxruntime/test/platform/windows/stacktrace_test.cc +++ b/onnxruntime/test/platform/windows/stacktrace_test.cc @@ -28,9 +28,6 @@ TEST(StacktraceTests, BasicTests) { // this method name should be the first on the stack as we hide the calls to the infrastructure that // creates the stack trace EXPECT_THAT(result[0], HasSubstr("BasicTests")); - else - // check that we have - EXPECT_THAT(result[0], HasSubstr("Unknown symbol")); try { ORT_THROW("Testing");