hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From omal...@apache.org
Subject svn commit: r818546 - in /hadoop/common/branches/branch-0.21: ./ CHANGES.txt src/contrib/ec2/ src/docs/ src/java/ src/java/org/apache/hadoop/http/HtmlQuoting.java src/test/core/ src/test/core/org/apache/hadoop/http/TestHtmlQuoting.java
Date Thu, 24 Sep 2009 16:59:21 GMT
Author: omalley
Date: Thu Sep 24 16:59:19 2009
New Revision: 818546

URL: http://svn.apache.org/viewvc?rev=818546&view=rev
Log:
HADOOP-6281. Avoid null pointer exceptions when the jsps don't have 
paramaters (omalley)

Modified:
    hadoop/common/branches/branch-0.21/   (props changed)
    hadoop/common/branches/branch-0.21/CHANGES.txt   (contents, props changed)
    hadoop/common/branches/branch-0.21/src/contrib/ec2/   (props changed)
    hadoop/common/branches/branch-0.21/src/docs/   (props changed)
    hadoop/common/branches/branch-0.21/src/java/   (props changed)
    hadoop/common/branches/branch-0.21/src/java/org/apache/hadoop/http/HtmlQuoting.java
    hadoop/common/branches/branch-0.21/src/test/core/   (props changed)
    hadoop/common/branches/branch-0.21/src/test/core/org/apache/hadoop/http/TestHtmlQuoting.java

Propchange: hadoop/common/branches/branch-0.21/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Sep 24 16:59:19 2009
@@ -1 +1,2 @@
+/hadoop/common/trunk:818543
 /hadoop/core/branches/branch-0.19/core:713112

Modified: hadoop/common/branches/branch-0.21/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-0.21/CHANGES.txt?rev=818546&r1=818545&r2=818546&view=diff
==============================================================================
--- hadoop/common/branches/branch-0.21/CHANGES.txt (original)
+++ hadoop/common/branches/branch-0.21/CHANGES.txt Thu Sep 24 16:59:19 2009
@@ -690,8 +690,9 @@
 
     HADOOP-5292. Fix NPE in KFS::getBlockLocations. (Sriram Rao via lohit)
 
-    HADOOP-5219. Adds a new property io.seqfile.local.dir for use by SequenceFile,
-    which earlier used mapred.local.dir. (Sharad Agarwal via ddas)
+    HADOOP-5219. Adds a new property io.seqfile.local.dir for use by
+    SequenceFile, which earlier used mapred.local.dir. (Sharad Agarwal
+    via ddas)
 
     HADOOP-5300. Fix ant javadoc-dev target and the typo in the class name
     NameNodeActivtyMBean.  (szetszwo)
@@ -708,7 +709,7 @@
     HADOOP-5383. Avoid building an unused string in NameNode's 
     verifyReplication(). (Raghu Angadi)
 
-    HADOOP-5347. Create a job output directory for the bbp examples.  (szetszwo)
+    HADOOP-5347. Create a job output directory for the bbp examples. (szetszwo)
 
     HADOOP-5341. Make hadoop-daemon scripts backwards compatible with the
     changes in HADOOP-4868. (Sharad Agarwal via yhemanth)
@@ -814,8 +815,8 @@
     in the JobTracker to get the FileSystem objects as per the JobTracker's
     configuration. (Amar Kamat via ddas) 
 
-    HADOOP-5648. Not able to generate gridmix.jar on the already compiled version of hadoop.
-    (gkesavan)	
+    HADOOP-5648. Not able to generate gridmix.jar on the already compiled 
+    version of hadoop. (gkesavan)	
 
     HADOOP-5808. Fix import never used javac warnings in hdfs. (szetszwo)
 
@@ -899,7 +900,8 @@
     in DataBlockScanner.  (Kan Zhang via szetszwo)
 
     HADOOP-4864. Fixes a problem to do with -libjars with multiple jars when
-    client and cluster reside on different OSs. (Amareshwari Sriramadasu via ddas)
+    client and cluster reside on different OSs. (Amareshwari Sriramadasu via 
+    ddas)
 
     HADOOP-5623. Fixes a problem to do with status messages getting overwritten
     in streaming jobs. (Rick Cox and Jothi Padmanabhan via ddas)
@@ -907,8 +909,8 @@
     HADOOP-5895. Fixes computation of count of merged bytes for logging.
     (Ravi Gummadi via ddas)
 
-    HADOOP-5805. problem using top level s3 buckets as input/output directories.
-    (Ian Nowland via tomwhite)
+    HADOOP-5805. problem using top level s3 buckets as input/output 
+    directories. (Ian Nowland via tomwhite)
    
     HADOOP-5940. trunk eclipse-plugin build fails while trying to copy 
     commons-cli jar from the lib dir (Giridharan Kesavan via gkesavan)
@@ -1007,8 +1009,9 @@
     HADOOP-6123. Add missing classpaths in hadoop-config.sh.  (Sharad Agarwal
     via szetszwo)
 
-    HADOOP-6172. Fix jar file names in hadoop-config.sh and include ${build.src}
-    as a part of the source list in build.xml.  (Hong Tang via szetszwo)
+    HADOOP-6172. Fix jar file names in hadoop-config.sh and include 
+    ${build.src} as a part of the source list in build.xml.  (Hong Tang via 
+    szetszwo)
 
     HADOOP-6124. Fix javac warning detection in test-patch.sh.  (Giridharan
     Kesavan via szetszwo)
@@ -1066,7 +1069,10 @@
 
     HADOOP-6274. Fix TestLocalFSFileContextMainOperations test failure. (Gary Murry via suresh).
 
-Release 0.20.1 - Unreleased
+    HADOOP-6281. Avoid null pointer exceptions when the jsps don't have 
+    paramaters (omalley)
+
+Release 0.20.1 - 2009-09-01
 
   INCOMPATIBLE CHANGES
 

Propchange: hadoop/common/branches/branch-0.21/CHANGES.txt
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Sep 24 16:59:19 2009
@@ -1,3 +1,4 @@
+/hadoop/common/trunk/CHANGES.txt:818543
 /hadoop/core/branches/branch-0.18/CHANGES.txt:727226
 /hadoop/core/branches/branch-0.19/CHANGES.txt:713112
 /hadoop/core/trunk/CHANGES.txt:776175-785643,785929-786278

Propchange: hadoop/common/branches/branch-0.21/src/contrib/ec2/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Sep 24 16:59:19 2009
@@ -1,2 +1,3 @@
+/hadoop/common/trunk/src/contrib/ec2:818543
 /hadoop/core/branches/branch-0.19/core/src/contrib/ec2:713112
 /hadoop/core/trunk/src/contrib/ec2:776175-784663

Propchange: hadoop/common/branches/branch-0.21/src/docs/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Sep 24 16:59:19 2009
@@ -1 +1,2 @@
+/hadoop/common/trunk/src/docs:818543
 /hadoop/core/branches/branch-0.19/src/docs:713112

Propchange: hadoop/common/branches/branch-0.21/src/java/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Sep 24 16:59:19 2009
@@ -1,2 +1,3 @@
+/hadoop/common/trunk/src/java:818543
 /hadoop/core/branches/branch-0.19/core/src/java:713112
 /hadoop/core/trunk/src/core:776175-785643,785929-786278

Modified: hadoop/common/branches/branch-0.21/src/java/org/apache/hadoop/http/HtmlQuoting.java
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-0.21/src/java/org/apache/hadoop/http/HtmlQuoting.java?rev=818546&r1=818545&r2=818546&view=diff
==============================================================================
--- hadoop/common/branches/branch-0.21/src/java/org/apache/hadoop/http/HtmlQuoting.java (original)
+++ hadoop/common/branches/branch-0.21/src/java/org/apache/hadoop/http/HtmlQuoting.java Thu
Sep 24 16:59:19 2009
@@ -60,6 +60,9 @@
    * @return does the string contain any of the active html characters?
    */
   public static boolean needsQuoting(String str) {
+    if (str == null) {
+      return false;
+    }
     byte[] bytes = str.getBytes();
     return needsQuoting(bytes, 0 , bytes.length);
   }
@@ -92,6 +95,9 @@
    * @return the quoted string
    */
   public static String quoteHtmlChars(String item) {
+    if (item == null) {
+      return null;
+    }
     byte[] bytes = item.getBytes();
     if (needsQuoting(bytes, 0, bytes.length)) {
       ByteArrayOutputStream buffer = new ByteArrayOutputStream();
@@ -145,6 +151,9 @@
    * @return the unquoted string
    */
   public static String unquoteHtmlChars(String item) {
+    if (item == null) {
+      return null;
+    }
     int next = item.indexOf('&');
     // nothing was quoted
     if (next == -1) {

Propchange: hadoop/common/branches/branch-0.21/src/test/core/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Sep 24 16:59:19 2009
@@ -1,2 +1,3 @@
+/hadoop/common/trunk/src/test/core:818543
 /hadoop/core/branches/branch-0.19/core/src/test/core:713112
 /hadoop/core/trunk/src/test/core:776175-785643,785929-786278

Modified: hadoop/common/branches/branch-0.21/src/test/core/org/apache/hadoop/http/TestHtmlQuoting.java
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-0.21/src/test/core/org/apache/hadoop/http/TestHtmlQuoting.java?rev=818546&r1=818545&r2=818546&view=diff
==============================================================================
--- hadoop/common/branches/branch-0.21/src/test/core/org/apache/hadoop/http/TestHtmlQuoting.java
(original)
+++ hadoop/common/branches/branch-0.21/src/test/core/org/apache/hadoop/http/TestHtmlQuoting.java
Thu Sep 24 16:59:19 2009
@@ -33,6 +33,7 @@
     assertTrue(HtmlQuoting.needsQuoting("&"));
     assertFalse(HtmlQuoting.needsQuoting(""));
     assertFalse(HtmlQuoting.needsQuoting("ab\ncdef"));
+    assertFalse(HtmlQuoting.needsQuoting(null));
   }
 
   @Test public void testQuoting() throws Exception {
@@ -41,6 +42,7 @@
     assertEquals("&&&", HtmlQuoting.quoteHtmlChars("&&&"));
     assertEquals(" '\n", HtmlQuoting.quoteHtmlChars(" '\n"));
     assertEquals(""", HtmlQuoting.quoteHtmlChars("\""));
+    assertEquals(null, HtmlQuoting.quoteHtmlChars(null));
   }
 
   private void runRoundTrip(String str) throws Exception {
@@ -53,6 +55,7 @@
     runRoundTrip("<>&'\"");
     runRoundTrip("ab>cd<ef&ghi'\"");
     runRoundTrip("A string\n with no quotable chars in it!");
+    runRoundTrip(null);
     StringBuilder buffer = new StringBuilder();
     for(char ch=0; ch < 127; ++ch) {
       buffer.append(ch);



Mime
View raw message