View | Details | Raw Unified | Return to bug 250377 | Differences between
and this patch

Collapse All | Expand All

(-)src/java/org/eclipse/buckminster/subversive/internal/SubversiveSession.java (-18 / +29 lines)
Lines 509-515 Link Here
509
			if(scheme != null)
509
			if(scheme != null)
510
			{
510
			{
511
				bld.append(scheme);
511
				bld.append(scheme);
512
				bld.append(':');
512
				bld.append("://");
513
			}
513
			}
514
514
515
			String username = null;
515
			String username = null;
Lines 534-545 Link Here
534
							password = null;
534
							password = null;
535
					}
535
					}
536
				}
536
				}
537
				bld.append("//");
538
				bld.append(authority);
537
				bld.append(authority);
539
			}
538
			}
540
			m_username = username;
539
			m_username = username;
541
			m_password = password;
540
			m_password = password;
542
541
542
			if(fullPath.getDevice() != null)
543
			{
544
				bld.append('/');
545
			}
543
			bld.append(fullPath.removeLastSegments(relPathLen));
546
			bld.append(fullPath.removeLastSegments(relPathLen));
544
			String urlLeadIn = bld.toString();
547
			String urlLeadIn = bld.toString();
545
548
Lines 551-557 Link Here
551
			if(m_trunkStructure)
554
			if(m_trunkStructure)
552
			{
555
			{
553
				if(relPathLen > 1)
556
				if(relPathLen > 1)
557
				{
554
					modulePath = fullPath.removeFirstSegments(idx + 1);
558
					modulePath = fullPath.removeFirstSegments(idx + 1);
559
					modulePath = modulePath.setDevice(null);
560
				}
555
			}
561
			}
556
			else
562
			else
557
				modulePath = Path.fromPortableString(fullPath.lastSegment());
563
				modulePath = Path.fromPortableString(fullPath.lastSegment());
Lines 905-911 Link Here
905
		if(uri == null)
911
		if(uri == null)
906
			return null;
912
			return null;
907
913
908
		String path = uri.getPath();
914
		String path = uri.toString();
909
		if(path == null)
915
		if(path == null)
910
			return null;
916
			return null;
911
917
Lines 921-927 Link Here
921
		String parentPath = path.substring(0, lastSlash);
927
		String parentPath = path.substring(0, lastSlash);
922
		try
928
		try
923
		{
929
		{
924
			return new URI(uri.getScheme(), uri.getUserInfo(), uri.getHost(), uri.getPort(), parentPath, uri.getQuery(), uri.getFragment());
930
			return new URI(parentPath);
925
		}
931
		}
926
		catch(URISyntaxException e)
932
		catch(URISyntaxException e)
927
		{
933
		{
Lines 949-956 Link Here
949
				list = SVNUtility.list(m_proxy, new SVNEntryRevisionReference(url.toString(), null, m_revision), ISVNConnector.Depth.IMMEDIATES, SVNEntry.Fields.ALL, ISVNConnector.Options.NONE, svnMon);
955
				list = SVNUtility.list(m_proxy, new SVNEntryRevisionReference(url.toString(), null, m_revision), ISVNConnector.Depth.IMMEDIATES, SVNEntry.Fields.ALL, ISVNConnector.Options.NONE, svnMon);
950
				if(list == null || list.length == 0)
956
				if(list == null || list.length == 0)
951
				{
957
				{
952
					if(logger.isDebugEnabled())
958
					logger.debug("Remote folder had no entries %s", key);
953
						logger.debug(String.format("Remote folder had no entries %s", key));
954
					list = s_emptyFolder;
959
					list = s_emptyFolder;
955
				}
960
				}
956
				m_listCache.put(key, list);
961
				m_listCache.put(key, list);
Lines 993-1003 Link Here
993
		int port = url.getPort();
998
		int port = url.getPort();
994
		bld.append(protocol);
999
		bld.append(protocol);
995
		bld.append("://");
1000
		bld.append("://");
996
		bld.append(url.getHost());
1001
		if(url.getHost() != null)
997
		if(url.getPort() != -1)
998
		{
1002
		{
999
			bld.append(":");
1003
			bld.append(url.getHost());
1000
			bld.append(port);
1004
			if(port != -1)
1005
			{
1006
				bld.append(":");
1007
				bld.append(port);
1008
			}
1001
		}
1009
		}
1002
1010
1003
		bld.append(url.getPath());
1011
		bld.append(url.getPath());
Lines 1071-1078 Link Here
1071
					continue;
1079
					continue;
1072
1080
1073
				URI cmp = repoAccessCmp.getSvnURL();
1081
				URI cmp = repoAccessCmp.getSvnURL();
1074
				if(!(url.getHost().equals(cmp.getHost()) && url.getScheme().equals(cmp.getScheme()) && url
1082
				if(!(Trivial.equalsAllowNull(url.getHost(),cmp.getHost()) && Trivial.equalsAllowNull(url.getScheme(),cmp.getScheme()) 
1075
						.getPort() == cmp.getPort()))
1083
						&& url.getPort() == cmp.getPort()))
1076
					continue;
1084
					continue;
1077
1085
1078
				String[] cmpSegs = Path.fromPortableString(cmp.getPath()).segments();
1086
				String[] cmpSegs = Path.fromPortableString(cmp.getPath()).segments();
Lines 1111-1121 Link Here
1111
				StringBuilder bld = new StringBuilder();
1119
				StringBuilder bld = new StringBuilder();
1112
				bld.append(url.getScheme());
1120
				bld.append(url.getScheme());
1113
				bld.append("://");
1121
				bld.append("://");
1114
				bld.append(url.getHost());
1122
				if(url.getHost() != null)
1115
				if(url.getPort() >= 0)
1116
				{
1123
				{
1117
					bld.append(':');
1124
					bld.append(url.getHost());
1118
					bld.append(url.getPort());
1125
					if(url.getPort() != -1)
1126
					{
1127
						bld.append(":");
1128
						bld.append(url.getPort());
1129
					}
1119
				}
1130
				}
1120
				for(int pdx = 0; pdx < idx; ++pdx)
1131
				for(int pdx = 0; pdx < idx; ++pdx)
1121
				{
1132
				{
Lines 1159-1166 Link Here
1159
			for(RepositoryAccess repoAccessCmp : commonRoots)
1170
			for(RepositoryAccess repoAccessCmp : commonRoots)
1160
			{
1171
			{
1161
				URI cmp = repoAccessCmp.getSvnURL();
1172
				URI cmp = repoAccessCmp.getSvnURL();
1162
				if(!(url.getHost().equals(cmp.getHost()) && url.getScheme().equals(cmp.getScheme()) && url
1173
				if(!(Trivial.equalsAllowNull(url.getHost(),cmp.getHost()) && Trivial.equalsAllowNull(url.getScheme(),cmp.getScheme()) 
1163
						.getPort() == cmp.getPort()))
1174
						&& url.getPort() == cmp.getPort()))
1164
					continue;
1175
					continue;
1165
1176
1166
				String[] cmpSegs = Path.fromPortableString(cmp.getPath()).segments();
1177
				String[] cmpSegs = Path.fromPortableString(cmp.getPath()).segments();

Return to bug 250377