OK, LangStrings can now really be defined after they are used

git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@1984 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
kichik 2002-12-20 19:14:57 +00:00
parent 61bd36d346
commit 88cfbb4702
3 changed files with 25 additions and 7 deletions

View file

@ -441,11 +441,10 @@ int CEXEBuild::add_string_main(const char *string, int process) // returns offse
free(cp);
return 0;
}
if (build_userlangstrings.find(cp, 0, &idx) < 0) idx = -1;
idx = GetUserString(cp);
}
free(cp);
if (idx < 0) SetUserString(cp, 0, 0, process);
return -((int)(idx+1+(sizeof(common_strings)+sizeof(installer_strings))/sizeof(int)));
if (idx >= 0) return -((int)(idx+1+(sizeof(common_strings)+sizeof(installer_strings))/sizeof(int)));
}
if (!process) return build_strlist.add(string,2);
@ -470,11 +469,10 @@ int CEXEBuild::add_string_uninst(const char *string, int process) // returns off
free(cp);
return 0;
}
if (ubuild_userlangstrings.find(cp, 0, &idx) < 0) idx = -1;
idx = GetUserString(cp);
}
free(cp);
if (idx < 0) SetUserString(cp, 0, 0, process);
return -((int)(idx+1+(sizeof(common_strings)+sizeof(uninstall_strings))/sizeof(int)));
if (idx >= 0) return -((int)(idx+1+(sizeof(common_strings)+sizeof(uninstall_strings))/sizeof(int)));
}
if (!process) return ubuild_strlist.add(string,2);