diff options
author | 이형주/Common Platform Lab(SR)/삼성전자 <leee.lee@samsung.com> | 2022-09-15 13:54:47 +0900 |
---|---|---|
committer | GitHub Enterprise <noreply-CODE@samsung.com> | 2022-09-15 13:54:47 +0900 |
commit | cfb65e31c726662536b05d360b2fe9cd0f7a15bf (patch) | |
tree | ca3603fe88ca02b1d7a711ca2fec8977858556fb | |
parent | 5a8706bc0cdd19c5bc4047a0c35a77fd5c315ed1 (diff) | |
download | launcher-tizen_sec.tar.gz launcher-tizen_sec.tar.bz2 launcher-tizen_sec.zip |
Fix dll filter in doAOTList (#433)submit/tizen/20220915.050131tizen_sec
-rw-r--r-- | NativeLauncher/tool/ni_common.cc | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/NativeLauncher/tool/ni_common.cc b/NativeLauncher/tool/ni_common.cc index cecda2a..666ea2d 100644 --- a/NativeLauncher/tool/ni_common.cc +++ b/NativeLauncher/tool/ni_common.cc @@ -189,7 +189,7 @@ static bool isTPADll(const std::string& dllPath) /** * @brief create the directory including parents directory, and - * copy ownership and smack labels to the created directory. + * copy ownership and smack labels to the created directory. * @param[in] target directory path * @param[in] source directory path to get ownership and smack label * @return if directory created successfully, return true otherwise false @@ -683,24 +683,21 @@ static ni_error_e doAOTList(std::vector<std::string>& dllList, const std::string std::string coreLib = concatPath(__pm->getRuntimePath(), "System.Private.CoreLib.dll"); bool hasSPC = false; - std::vector<std::string> niList; for (auto it = dllList.begin(); it != dllList.end(); it++) { std::string f = *it; if (!isFile(f)) { _SERR("dll file is not exist : %s", f.c_str()); - dllList.erase(it--); + dllList.erase(it); } - if (!isManagedAssembly(f)) { + else if (!isManagedAssembly(f)) { _SERR("Input file is not a dll file : %s", f.c_str()); - dllList.erase(it--); + dllList.erase(it); } // handle System.Private.CoreLib.dll separately. // dllList and path manager contain absolute path. So, there is no need to change path to absolute path - if (f == coreLib) { + else if (f == coreLib) { hasSPC = true; - dllList.erase(it--); - } else { - niList.push_back(changeExtension(f, ".dll", ".ni.dll")); + dllList.erase(it); } } |