Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 367280 - endless loop on bad project
Summary: endless loop on bad project
Status: RESOLVED FIXED
Alias: None
Product: EGit
Classification: Technology
Component: Core (show other bugs)
Version: unspecified   Edit
Hardware: PC Mac OS X - Carbon (unsup.)
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-12-21 04:33 EST by Denny Valliant CLA
Modified: 2013-02-10 16:42 EST (History)
1 user (show)

See Also:


Attachments
patch for repository mapping null check (801 bytes, patch)
2011-12-21 04:35 EST, Denny Valliant CLA
no flags Details | Diff
resource util tweak (595 bytes, application/octet-stream)
2011-12-21 04:36 EST, Denny Valliant CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Denny Valliant CLA 2011-12-21 04:33:18 EST
Build Identifier: 

if one has a "bad" project in their workspace, you can get into an endless loop between getMapping() and getMappingForNonExistentResource().

This patch is a simple one-liner.

There's another patch for ResourceUtil isNonWorkspace() as well, but I dunno if it's needed.  Instead of getLocation() I did getLocationURI(), as that will resolve "virtual" stuff (like the ultimately "bad" RSE project I had perhaps)-- but as I said, I dunno if virtual stuff should be resolved.

The null check is probably a must tho.  Apologies for not going the gerrit route.

Reproducible: Always

Steps to Reproduce:
1.have a non-existent/error-ed project in your workspace
2.start eclipse
3.
Comment 1 Denny Valliant CLA 2011-12-21 04:35:26 EST
Created attachment 208661 [details]
patch for repository mapping null check

now that I see it, I wonder if I should have done getLocationURI here too.  Whateves.
Comment 2 Denny Valliant CLA 2011-12-21 04:36:04 EST
Created attachment 208662 [details]
resource util tweak

not sure if this is needed, see ticket
Comment 3 Kevin Sawicki CLA 2011-12-21 12:32:28 EST
Hi, 

Could you push this change to Gerrit for review?

Instructions are here: http://wiki.eclipse.org/EGit/Contributor_Guide#Contributing_Patches
Comment 4 Robin Rosenberg CLA 2013-02-10 16:42:25 EST
Looks like this has been fixed in e65101e7eeb28cd9cdb4bc1c7702fe91a59c534f or earlier