Commits

Jason Harris committed 591d896

- Fix issue 50. If the stringByResolvingSymlinksAndAliases returns null Ie the path is no
longer there, then degrade gracefully. This issue actually only occurred after the
switch to handling symlinks better.

Comments (0)

Files changed (1)

Classes/Sidebar/SidebarNode.m

 	{
 		if ([path length] < PATH_MAX)
 		{
+			NSString* cachedPath = path;
 			path = [path stringByResolvingSymlinksAndAliases];
-			path = caseSensitiveFilePath(path);
+			if (path)
+				path = caseSensitiveFilePath(path);
+			else
+				path = cachedPath;
 		}
 		else
 			NSRunCriticalAlertPanel(@"Max Path Length exceeded", fstr(@"The maximum path length for the path to the repository root was exceeded. Functionality for this repository could be erratic. The path is", path), @"OK", nil, nil);