From d2b18d7a8e23af6b27a8e2281e43bf72d715af66 Mon Sep 17 00:00:00 2001 From: Eduardo Speroni Date: Tue, 24 May 2022 16:23:27 -0300 Subject: [PATCH] fix: direct boot should not crash/ANR --- test-app/runtime/src/main/cpp/MetadataNode.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test-app/runtime/src/main/cpp/MetadataNode.cpp b/test-app/runtime/src/main/cpp/MetadataNode.cpp index 97e92b58e..9c5739eac 100644 --- a/test-app/runtime/src/main/cpp/MetadataNode.cpp +++ b/test-app/runtime/src/main/cpp/MetadataNode.cpp @@ -1812,7 +1812,7 @@ void MetadataNode::BuildMetadata(const string& filesPath) { // TODO: Is there a way to detect if the screen is locked as verification // We assume based on the error that this is the only way to get this specific error here at this point - if (errno == ENOENT) { + if (errno == ENOENT || errno == EACCES) { // Log the error with error code __android_log_print(ANDROID_LOG_ERROR, "TNS.error", "%s", ss.str().c_str());