Author: andreas
Date: Tue Oct 2 07:02:23 2007
New Revision: 581245
URL: http://svn.apache.org/viewvc?rev=581245&view=rev
Log:
Don't attach port string if port is 80
Modified:
lenya/branches/branch_1_2_x_shibboleth/src/java/org/apache/lenya/ac/shibboleth/ShibbolethModule.java
Modified: lenya/branches/branch_1_2_x_shibboleth/src/java/org/apache/lenya/ac/shibboleth/ShibbolethModule.java
URL: http://svn.apache.org/viewvc/lenya/branches/branch_1_2_x_shibboleth/src/java/org/apache/lenya/ac/shibboleth/ShibbolethModule.java?rev=581245&r1=581244&r2=581245&view=diff
==============================================================================
--- lenya/branches/branch_1_2_x_shibboleth/src/java/org/apache/lenya/ac/shibboleth/ShibbolethModule.java (original)
+++ lenya/branches/branch_1_2_x_shibboleth/src/java/org/apache/lenya/ac/shibboleth/ShibbolethModule.java Tue Oct 2 07:02:23 2007
@@ -69,8 +69,9 @@
String outgoingUrl = rewriter.rewrite(webappUrl);
if (outgoingUrl.startsWith("/")) {
- String serverUrl = req.getScheme() + "://" + req.getServerName() + ":"
- + req.getServerPort();
+ int port = req.getServerPort();
+ String portSuffix = port == 80 ? "" : ":" + port;
+ String serverUrl = req.getScheme() + "://" + req.getServerName() + portSuffix;
outgoingUrl = serverUrl + outgoingUrl;
}
lmpx.com only provides a reader for public news (NNTP) servers. It is not
affiliated with the servers or forums shown here and is not responsible for
the content of articles, which is written by their respective authors.