DESCRIPTION

Consider IResource.getLocation() being null

For non-local projects, i.e. ones backed by other EFS implementations,
IResource.getLocation() is designed to return null (cf.
getLoactionURI()).  Honor this fact by checking return values of
getLocation().

Bug: 413887
Change-Id: I7591ce439dc8e3719965a4516c9eb4692cfd5acb
Signed-off-by: Braedon Velazquez xxx@xxx.xxx

COMMENTS

author: Brenden Conley
date: 2013-07-29 12:29:40.000000000

Patch Set 1:

Build Started https://hudson.eclipse.org/sandbox/job/egit.gerrit/4728/

-------------------------------------
author: Brenden Conley
date: 2013-07-29 12:48:07.000000000

Patch Set 1: Code-Review-1

Build Unstable 

https://hudson.eclipse.org/sandbox/job/egit.gerrit/4728/ : UNSTABLE

-------------------------------------
author: Braedon Velazquez
date: 2013-07-29 13:13:09.000000000

Patch Set 1:

Test failure seems to be unrelated to this change.

-------------------------------------
author: Brenden Conley
date: 2013-07-29 16:06:16.000000000

Patch Set 1: -Code-Review

Build Started https://hudson.eclipse.org/sandbox/job/egit.gerrit/4729/

-------------------------------------
author: Brenden Conley
date: 2013-07-29 16:25:41.000000000

Patch Set 1: Verified+1

Build Successful 

https://hudson.eclipse.org/sandbox/job/egit.gerrit/4729/ : SUCCESS

-------------------------------------
author: Danika Greer
date: 2013-07-29 16:30:07.000000000

Patch Set 1: Verified+1 Code-Review+2 IP-Clean+1

Looks good, thanks!

-------------------------------------
author: Danika Greer
date: 2013-07-29 16:30:09.000000000

Change has been successfully merged into the git repository.

-------------------------------------
author: Danika Greer
date: 2013-07-30 11:47:34.000000000

Patch Set 1:

(1 comment)

Line:327, org.eclipse.egit.core/src/org/eclipse/egit/core/internal/util/ProjectUtil.java -> Hm, it occurred to me that we might be violating the comparator contract here, specifically this:

>  Finally, the implementor must ensure that compare(x, y)==0 implies that sgn(compare(x, z))==sgn(compare(y, z)) for all z.

Maybe we should change it to this?:

	if (l1 != null && l2 != null)
		return -l1.toFile().compareTo(l2.toFile());
	else if (l1 != null)
		return -1;
	else if (l2 != null)
		return 1;
	else
		return 0;

-------------------------------------
author: Braedon Velazquez
date: 2013-07-30 11:51:32.000000000

Patch Set 1:

(1 comment)

Line:327, org.eclipse.egit.core/src/org/eclipse/egit/core/internal/util/ProjectUtil.java -> +1

-------------------------------------
author: Danika Greer
date: 2013-07-30 12:11:12.000000000

Patch Set 1:

(1 comment)

Line:327, org.eclipse.egit.core/src/org/eclipse/egit/core/internal/util/ProjectUtil.java -> Pushed here: https://git.eclipse.org/r/14960

-------------------------------------
