summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYifan Hong2017-07-12 17:57:32 -0500
committerandroid-build-merger2017-07-12 17:57:32 -0500
commit7b6f8c93d08a7b62b1fa8f5fb75a7df5635e64d3 (patch)
treedbb2b526d64f0ac44648fc45ad2890d43713b72b
parent7593afbd47233510537cd6f8b8bfe4dc8d40b159 (diff)
parentd4bc5d800d3264fd94b783e79b6e0211bfa85fcc (diff)
downloadplatform-system-libvintf-7b6f8c93d08a7b62b1fa8f5fb75a7df5635e64d3.tar.gz
platform-system-libvintf-7b6f8c93d08a7b62b1fa8f5fb75a7df5635e64d3.tar.xz
platform-system-libvintf-7b6f8c93d08a7b62b1fa8f5fb75a7df5635e64d3.zip
Do not abort when assemble_vintf does not get env vars am: 488e16a673 am: 084e18dc6e am: 24aed79b09
am: d4bc5d800d Change-Id: I4df0575a6276aaaef91baf2075c3f01b8e5ef23e
-rw-r--r--assemble_vintf.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/assemble_vintf.cpp b/assemble_vintf.cpp
index 98fdae3..8b7e609 100644
--- a/assemble_vintf.cpp
+++ b/assemble_vintf.cpp
@@ -42,8 +42,9 @@ public:
42 static bool getFlag(const std::string& key, T* value) { 42 static bool getFlag(const std::string& key, T* value) {
43 const char *envValue = getenv(key.c_str()); 43 const char *envValue = getenv(key.c_str());
44 if (envValue == NULL) { 44 if (envValue == NULL) {
45 std::cerr << "Required " << key << " flag." << std::endl; 45 std::cerr << "Warning: " << key << " is missing, defaulted to " << (*value)
46 return false; 46 << std::endl;
47 return true;
47 } 48 }
48 49
49 if (!parse(envValue, value)) { 50 if (!parse(envValue, value)) {