# HG changeset patch # User stechong # Date 1267047124 21600 # Node ID e4dfdbcc09269fe831d4575cdbad10533b091cc4 # Parent 3720b50bf185d83bd5e17beb581474dc625ccb01 Fix for Bug 10689, binaries disappearing when added to the Executables view. diff -r 3720b50bf185 -r e4dfdbcc0926 cdt/cdt_6_0_x/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/executables/ExecutablesManager.java --- a/cdt/cdt_6_0_x/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/executables/ExecutablesManager.java Wed Feb 10 13:31:11 2010 -0600 +++ b/cdt/cdt_6_0_x/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/executables/ExecutablesManager.java Wed Feb 24 15:32:04 2010 -0600 @@ -104,7 +104,10 @@ // store the list of executables for this project synchronized (executablesMap) { - executablesMap.put(project, provider.getExecutables(project, subMonitor.newChild(1, SubMonitor.SUPPRESS_NONE))); + List executables = provider.getExecutables(project, subMonitor.newChild(1, SubMonitor.SUPPRESS_NONE)); + if (executables != null) { + executablesMap.put(project, executables); + } } } } diff -r 3720b50bf185 -r e4dfdbcc0926 cdt/cdt_6_0_x/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/executables/IProjectExecutablesProvider.java --- a/cdt/cdt_6_0_x/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/executables/IProjectExecutablesProvider.java Wed Feb 10 13:31:11 2010 -0600 +++ b/cdt/cdt_6_0_x/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/executables/IProjectExecutablesProvider.java Wed Feb 24 15:32:04 2010 -0600 @@ -38,7 +38,7 @@ * Get the list of executables for the given project * @param project the project to get the executables for * @param monitor progress monitor - * @return the list of executables (which may be empty) + * @return the list of executables (which may be empty), or null if request is cancelled */ List getExecutables(IProject project, IProgressMonitor monitor); diff -r 3720b50bf185 -r e4dfdbcc0926 cdt/cdt_6_0_x/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/executables/StandardExecutableProvider.java --- a/cdt/cdt_6_0_x/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/executables/StandardExecutableProvider.java Wed Feb 10 13:31:11 2010 -0600 +++ b/cdt/cdt_6_0_x/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/executables/StandardExecutableProvider.java Wed Feb 24 15:32:04 2010 -0600 @@ -55,7 +55,7 @@ for (IBinary binary : binaries) { if (progress.isCanceled()) { - break; + return null; } if (binary.isExecutable() || binary.isSharedLib()) {