Merge "Support importing property file with expanded name"

am: 69880e1a39

Change-Id: Ic2453514c72ddd88269cef659df42642997427c9
This commit is contained in:
Dongcheol Shin 2019-06-13 17:31:18 -07:00 committed by android-build-merger
commit c3967a111d

View file

@ -645,8 +645,14 @@ static void LoadProperties(char* data, const char* filter, const char* filename,
while (isspace(*key)) key++;
}
load_properties_from_file(fn, key, properties);
std::string raw_filename(fn);
std::string expanded_filename;
if (!expand_props(raw_filename, &expanded_filename)) {
LOG(ERROR) << "Could not expand filename '" << raw_filename << "'";
continue;
}
load_properties_from_file(expanded_filename.c_str(), key, properties);
} else {
value = strchr(key, '=');
if (!value) continue;