mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-09-09 03:24:59 -06:00
Fix ide crash when empty build method is saved #1186
git-svn-id: svn://ultimatepp.org/upp/trunk@8687 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
46a564dd84
commit
040b014f3d
2 changed files with 9 additions and 5 deletions
|
|
@ -445,7 +445,9 @@ void BuildMethods::Load()
|
|||
VectorMap<String, String> map;
|
||||
String fn = ConfigFile(ff.GetName());
|
||||
if(LoadVarFile(fn, map)) {
|
||||
String builderName = map.Get("BUILDER");
|
||||
int builderIdx = map.Find("BUILDER");
|
||||
String builderName = builderIdx >= 0 ? map[builderIdx] : "";
|
||||
|
||||
int setupIdx = -1;
|
||||
String prefix;
|
||||
for(int i = 0; i < setups.GetCount(); i++) {
|
||||
|
|
@ -646,8 +648,9 @@ VectorMap<String, String> BuildMethods::MapBuilderVars(const VectorMap<String, S
|
|||
{
|
||||
VectorMap<String, String> mapedMap;
|
||||
Index<String> varsToMaped;
|
||||
|
||||
String builder = map.Get("BUILDER");
|
||||
|
||||
int builderIdx = map.Find("BUILDER");
|
||||
String builder = builderIdx >= 0 ? map[builderIdx] : "";
|
||||
if(builder.IsEmpty())
|
||||
return VectorMap<String, String>();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue