diff options
author | seokgil.kang <seokgil.kang@samsung.com> | 2015-05-12 16:36:13 +0900 |
---|---|---|
committer | seokgil.kang <seokgil.kang@samsung.com> | 2015-05-12 16:36:13 +0900 |
commit | 8ae4b64cacbd128dffaa74409247e09f754cad60 (patch) | |
tree | 56359cd00359c2bbc309338bfe87893d9e702f08 | |
parent | 9eb480a9e9f54c74c23f08fb595ed350a1329b39 (diff) | |
download | dynamic-analysis-ide-eplugin-8ae4b64cacbd128dffaa74409247e09f754cad60.tar.gz dynamic-analysis-ide-eplugin-8ae4b64cacbd128dffaa74409247e09f754cad60.tar.bz2 dynamic-analysis-ide-eplugin-8ae4b64cacbd128dffaa74409247e09f754cad60.zip |
COMMON : fix some potential bugs
Change-Id: I9fa336f9e14c2eb988ff5b4f2e5248228a053145
Signed-off-by: seokgil.kang <seokgil.kang@samsung.com>
2 files changed, 21 insertions, 14 deletions
diff --git a/org.tizen.dynamicanalysis.ide.eplugin/src/org/tizen/dynamicanalysis/ide/eplugin/launch/TizenNativeApplicationDADelegate.java b/org.tizen.dynamicanalysis.ide.eplugin/src/org/tizen/dynamicanalysis/ide/eplugin/launch/TizenNativeApplicationDADelegate.java index 0072c6c..32aa691 100644 --- a/org.tizen.dynamicanalysis.ide.eplugin/src/org/tizen/dynamicanalysis/ide/eplugin/launch/TizenNativeApplicationDADelegate.java +++ b/org.tizen.dynamicanalysis.ide.eplugin/src/org/tizen/dynamicanalysis/ide/eplugin/launch/TizenNativeApplicationDADelegate.java @@ -400,20 +400,23 @@ public class TizenNativeApplicationDADelegate extends TizenLaunchDelegate { } private List<String> getRpmFiles() { - List<String> rpms = new ArrayList<String>(); - if (project != null) { - String rpmFolderPath = project.getFolder(getBuildConfiguration(project).getName()).getLocation().toOSString(); - File rpmFolder = new File(rpmFolderPath); - File[] rpmList = rpmFolder.listFiles(new ExtFilter(PLATFORM_PKG_TYPE.toLowerCase())); - if (rpmList == null) { - return rpms; - } - for (int i = 0; i < rpmList.length; i++) { - rpms.add(rpmList[i].getAbsolutePath()); - } - } - return rpms; - } + List<String> rpms = new ArrayList<String>(); + if (project != null) { + IConfiguration config = getBuildConfiguration(project); + if (config != null) { + String rpmFolderPath = project.getFolder(config.getName()).getLocation().toOSString(); + File rpmFolder = new File(rpmFolderPath); + File[] rpmList = rpmFolder.listFiles(new ExtFilter(PLATFORM_PKG_TYPE.toLowerCase())); + if (rpmList == null) { + return rpms; + } + for (int i = 0; i < rpmList.length; i++) { + rpms.add(rpmList[i].getAbsolutePath()); + } + } + } + return rpms; + } @Override protected String getPluginID() { diff --git a/org.tizen.dynamicanalysis.ide.eplugin/src/org/tizen/dynamicanalysis/ide/eplugin/launch/TizenNativeApplicationDAShortcut.java b/org.tizen.dynamicanalysis.ide.eplugin/src/org/tizen/dynamicanalysis/ide/eplugin/launch/TizenNativeApplicationDAShortcut.java index dcce132..6503dac 100755 --- a/org.tizen.dynamicanalysis.ide.eplugin/src/org/tizen/dynamicanalysis/ide/eplugin/launch/TizenNativeApplicationDAShortcut.java +++ b/org.tizen.dynamicanalysis.ide.eplugin/src/org/tizen/dynamicanalysis/ide/eplugin/launch/TizenNativeApplicationDAShortcut.java @@ -391,6 +391,10 @@ public class TizenNativeApplicationDAShortcut extends TizenLaunchShortcut { protected void setPkgCommandTarget(IProject project) { IConfiguration config = PlatformConfigurationManager.getDefaultConfiguration(project); + if (config == null) { + DALog.printLog("Configuration is null"); + return; + } String targetId = PlatformConfigurationManager.getBuildTargetName(config); String rootId = SmartBuildInterface.getInstance().getRootstrapIDFromTargetID(targetId); PlatformRootstrap rootstrap = RootstrapManager.getRootstrap(rootId); |