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

Bug 323732

Summary: An unnecessary error in the error log appears when a closed remote C/C++ project is deleted
Product: [Tools] PTP Reporter: Michael Lindo <mlindo>
Component: RDTAssignee: Chris Recoskie <recoskie>
Status: RESOLVED FIXED QA Contact:
Severity: trivial    
Priority: P3 CC: ptp-inbox, recoskie
Version: unspecified   
Target Milestone: 4.0.3   
Hardware: All   
OS: All   
Whiteboard:
Attachments:
Description Flags
A proposed fix - don't call hasRemoteNature recoskie: iplog+

Description Michael Lindo CLA 2010-08-26 13:10:02 EDT
Build Identifier: 

The error "Project x is not open." appears in the error log when a closed remote C/C++ project is deleted. 



Reproducible: Always

Steps to Reproduce:
1. Create a remote C/C++ project
2. Close the project
3. Delete the project
4. Check the error log view for the error message "Project x is not open."
Comment 1 Michael Lindo CLA 2010-08-26 13:52:18 EDT
Created attachment 177548 [details]
A proposed fix - don't call hasRemoteNature

No longer check if the resource "hasRemoteNature" which will consequently stop the error from happening.

hasRemoteNature may incorrectly return false if the resource is inaccessible (closed).  This is because the hasNature method calls checkAccessible before it returns the nature. Just because the resource is inaccessible doesn't necessarily mean it is not remote. 

The end result is "projectStatusMap.remove(projectName)" will return null on a non remote nature project, which should not be a problem.
Comment 2 Chris Recoskie CLA 2010-08-26 14:25:14 EDT
Comment on attachment 177548 [details]
A proposed fix - don't call hasRemoteNature

Patch looks fine, I'll see about committing it today/tomorrow.
Comment 3 Chris Recoskie CLA 2010-08-26 14:55:55 EDT
Committed to ptp_4_0 and HEAD.