Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 326716

Summary: NPE in EDC's DsfTerminateCommand handling
Product: [Tools] CDT Reporter: John Cortell <john.cortell>
Component: cdt-debug-edcAssignee: Ken Ryall <ken.ryall>
Status: RESOLVED FIXED QA Contact: Ken Ryall <ken.ryall>
Severity: normal    
Priority: P3 Flags: ken.ryall: review+
Version: 8.0   
Target Milestone: 8.0   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
fix john.cortell: iplog-

Description John Cortell CLA 2010-09-30 17:00:31 EDT
There's a couple of issues.

1. DsfTerminateCommand.canExecute() assumes that IProcesses.canTerminate() is successful and returns a data object (a Boolean). It should assume neither. This is where the NPE happens (due to # 2)

2. Boolean properties in the EDC Run Control context should have implicit default values. Returning a null Boolean object to a requester doesn't make a lot of sense to me.
Comment 1 John Cortell CLA 2010-09-30 17:01:59 EDT
Created attachment 180001 [details]
fix
Comment 2 John Cortell CLA 2010-09-30 17:03:03 EDT
Committed to HEAD. Ken, please review.
Comment 4 Ken Ryall CLA 2010-10-01 08:19:58 EDT
+1 Nice cleanup.