You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by ca...@apache.org on 2006/09/05 07:20:48 UTC

svn commit: r440264 - in /logging/log4j/trunk: LICENSE LICENSE.txt NOTICE build.xml src/java/org/apache/log4j/net/SocketServer.java

Author: carnold
Date: Mon Sep  4 22:20:47 2006
New Revision: 440264

URL: http://svn.apache.org/viewvc?view=rev&rev=440264
Log:
Bug 40412: NOTICE file added to distribution and jars

Added:
    logging/log4j/trunk/LICENSE
      - copied unchanged from r438794, logging/log4j/trunk/LICENSE.txt
    logging/log4j/trunk/NOTICE
Removed:
    logging/log4j/trunk/LICENSE.txt
Modified:
    logging/log4j/trunk/build.xml
    logging/log4j/trunk/src/java/org/apache/log4j/net/SocketServer.java

Added: logging/log4j/trunk/NOTICE
URL: http://svn.apache.org/viewvc/logging/log4j/trunk/NOTICE?view=auto&rev=440264
==============================================================================
--- logging/log4j/trunk/NOTICE (added)
+++ logging/log4j/trunk/NOTICE Mon Sep  4 22:20:47 2006
@@ -0,0 +1,2 @@
+This product includes software developed by
+The Apache Software Foundation (http://www.apache.org/).

Modified: logging/log4j/trunk/build.xml
URL: http://svn.apache.org/viewvc/logging/log4j/trunk/build.xml?view=diff&rev=440264&r1=440263&r2=440264
==============================================================================
--- logging/log4j/trunk/build.xml (original)
+++ logging/log4j/trunk/build.xml Mon Sep  4 22:20:47 2006
@@ -394,6 +394,7 @@
 	          <attribute name="Implementation-Vendor" value="Apache Software Foundation"/>
 	        </section>
 	      </manifest>
+         <metainf dir="." includes="NOTICE,LICENSE"/>
 	  	</jar>
 	  </target>
 	
@@ -427,6 +428,7 @@
           <attribute name="Implementation-Vendor" value="Apache Software Foundation"/>
         </section>
       </manifest>
+	  <metainf dir="." includes="NOTICE,LICENSE"/>
   	</jar>
   </target>
 
@@ -462,7 +464,7 @@
             <attribute name="Implementation-Vendor" value="Apache Software Foundation"/>
           </section>
         </manifest>
-
+		<metainf dir="." includes="NOTICE,LICENSE"/>
   	</jar>
   </target>
 		
@@ -498,6 +500,7 @@
         <attribute name="Implementation-Vendor" value="Apache Software Foundation"/>
       </section>
     </manifest>
+    <metainf dir="." includes="NOTICE,LICENSE"/>
     </jar>
   </target>
 
@@ -531,6 +534,7 @@
         <attribute name="Implementation-Vendor" value="Apache Software Foundation"/>
       </section>
     </manifest>
+    <metainf dir="." includes="NOTICE,LICENSE"/>
     </jar>
   </target>
 
@@ -572,6 +576,7 @@
           <attribute name="Implementation-Vendor" value="Apache Software Foundation"/>
         </section>
       </manifest>
+	  <metainf dir="." includes="NOTICE,LICENSE"/>
     </jar>	
   </target>
 
@@ -599,6 +604,7 @@
                     <attribute name="Implementation-Vendor" value="Apache Software Foundation"/>
                 </section>
             </manifest>
+            <metainf dir="." includes="NOTICE,LICENSE"/>
         </jar>
     </target>
 
@@ -672,6 +678,7 @@
 	      <attribute name="Implementation-Vendor" value="Apache Software Foundation"/>
 	    </section>
 	  </manifest>
+	  <metainf dir="." includes="NOTICE,LICENSE"/>
 	</jar>	
   </target>
 	
@@ -762,6 +769,7 @@
           <attribute name="Implementation-Vendor" value="Apache Software Foundation"/>
         </section>
       </manifest>
+	  <metainf dir="." includes="NOTICE,LICENSE"/>
     </jar>
 
   </target>
@@ -783,6 +791,7 @@
           <attribute name="Implementation-Vendor" value="Apache Software Foundation"/>
         </section>
       </manifest>
+	  <metainf dir="." includes="NOTICE,LICENSE"/>
     </jar>
 
   </target>
@@ -1037,7 +1046,8 @@
          build.xml,
          build.properties.sample,
          INSTALL.txt,
-         LICENSE.txt"
+         LICENSE,
+		 NOTICE"
          excludes="**/*.bak,
          **/goEnv.bat,
          docs/pub-support/*,

Modified: logging/log4j/trunk/src/java/org/apache/log4j/net/SocketServer.java
URL: http://svn.apache.org/viewvc/logging/log4j/trunk/src/java/org/apache/log4j/net/SocketServer.java?view=diff&rev=440264&r1=440263&r2=440264
==============================================================================
--- logging/log4j/trunk/src/java/org/apache/log4j/net/SocketServer.java (original)
+++ logging/log4j/trunk/src/java/org/apache/log4j/net/SocketServer.java Mon Sep  4 22:20:47 2006
@@ -164,19 +164,7 @@
   LoggerRepository configureHierarchy(InetAddress inetAddress) {
     logger.info("Locating configuration file for " + inetAddress);
 
-    // We assume that the toSting method of InetAddress returns is in
-    // the format hostname/d1.d2.d3.d4 e.g. torino/192.168.1.1
-    String s = inetAddress.toString();
-    int i = s.indexOf("/");
-
-    if (i == -1) {
-      logger.warn(
-        "Could not parse the inetAddress [" + inetAddress
-        + "]. Using default hierarchy.");
-
-      return genericHierarchy();
-    } else {
-      String key = s.substring(0, i);
+      String key = inetAddress.getHostName();
 
       File configFile = new File(dir, key + CONFIG_FILE_EXT);
 
@@ -193,7 +181,6 @@
 
         return genericHierarchy();
       }
-    }
   }
 
   LoggerRepository genericHierarchy() {



---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org