Fix a static-analyzer warning.
frameworks/base/tools/aapt2/util/Files.cpp:81:21: warning: Null pointer
passed as an argument to a 'nonnull' parameter
while ((entry = readdir(dir))) {
Bug: None.
Test: Warning no longer appears.
Change-Id: If242598405e995928378ce317a2e909654e1e985
diff --git a/tools/aapt2/util/Files.cpp b/tools/aapt2/util/Files.cpp
index f5e49f1..042ff0e 100644
--- a/tools/aapt2/util/Files.cpp
+++ b/tools/aapt2/util/Files.cpp
@@ -72,8 +72,8 @@
std::stringstream errorStr;
errorStr << "unable to open file: " << strerror(errno);
*outError = errorStr.str();
- return {};
}
+ return {};
}
std::vector<std::string> files;