aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Services/LLLoginService/LLLoginService.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Services/LLLoginService/LLLoginService.cs')
-rw-r--r--OpenSim/Services/LLLoginService/LLLoginService.cs18
1 files changed, 15 insertions, 3 deletions
diff --git a/OpenSim/Services/LLLoginService/LLLoginService.cs b/OpenSim/Services/LLLoginService/LLLoginService.cs
index a5a728b..5d1779a 100644
--- a/OpenSim/Services/LLLoginService/LLLoginService.cs
+++ b/OpenSim/Services/LLLoginService/LLLoginService.cs
@@ -516,6 +516,7 @@ namespace OpenSim.Services.LLLoginService
516 // free uri form 516 // free uri form
517 // e.g. New Moon&135&46 New Moon@osgrid.org:8002&153&34 517 // e.g. New Moon&135&46 New Moon@osgrid.org:8002&153&34
518 where = "url"; 518 where = "url";
519 GridRegion region = null;
519 Regex reURI = new Regex(@"^uri:(?<region>[^&]+)&(?<x>\d+)&(?<y>\d+)&(?<z>\d+)$"); 520 Regex reURI = new Regex(@"^uri:(?<region>[^&]+)&(?<x>\d+)&(?<y>\d+)&(?<z>\d+)$");
520 Match uriMatch = reURI.Match(startLocation); 521 Match uriMatch = reURI.Match(startLocation);
521 if (uriMatch == null) 522 if (uriMatch == null)
@@ -546,8 +547,18 @@ namespace OpenSim.Services.LLLoginService
546 } 547 }
547 else 548 else
548 { 549 {
549 m_log.InfoFormat("[LLLOGIN SERVICE]: Got Custom Login URI {0}, Grid does not provide default regions.", startLocation); 550 m_log.Info("[LLOGIN SERVICE]: Last Region Not Found Attempting to find random region");
550 return null; 551 region = FindAlternativeRegion(scopeID);
552 if (region != null)
553 {
554 where = "safe";
555 return region;
556 }
557 else
558 {
559 m_log.InfoFormat("[LLLOGIN SERVICE]: Got Custom Login URI {0}, Grid does not provide default regions and no alternative found.", startLocation);
560 return null;
561 }
551 } 562 }
552 } 563 }
553 return regions[0]; 564 return regions[0];
@@ -575,7 +586,8 @@ namespace OpenSim.Services.LLLoginService
575 if (parts.Length > 1) 586 if (parts.Length > 1)
576 UInt32.TryParse(parts[1], out port); 587 UInt32.TryParse(parts[1], out port);
577 588
578 GridRegion region = FindForeignRegion(domainName, port, regionName, out gatekeeper); 589// GridRegion region = FindForeignRegion(domainName, port, regionName, out gatekeeper);
590 region = FindForeignRegion(domainName, port, regionName, out gatekeeper);
579 return region; 591 return region;
580 } 592 }
581 } 593 }