hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From omal...@apache.org
Subject svn commit: r1077049 - /hadoop/common/branches/branch-0.20-security-patches/src/hdfs/org/apache/hadoop/hdfs/server/namenode/ListPathsServlet.java
Date Fri, 04 Mar 2011 03:35:36 GMT
Author: omalley
Date: Fri Mar  4 03:35:36 2011
New Revision: 1077049

URL: http://svn.apache.org/viewvc?rev=1077049&view=rev
Log:
commit 83a1fe07d0f8588371c9d86b50dc0e93de3ea4c1
Author: Jitendra Nath Pandey <jitendra@yahoo-inc.com>
Date:   Thu Nov 5 17:35:50 2009 -0800

    HDFS-625 from https://issues.apache.org/jira/secure/attachment/12424176/hdfs-625.0-20.patch

Modified:
    hadoop/common/branches/branch-0.20-security-patches/src/hdfs/org/apache/hadoop/hdfs/server/namenode/ListPathsServlet.java

Modified: hadoop/common/branches/branch-0.20-security-patches/src/hdfs/org/apache/hadoop/hdfs/server/namenode/ListPathsServlet.java
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-0.20-security-patches/src/hdfs/org/apache/hadoop/hdfs/server/namenode/ListPathsServlet.java?rev=1077049&r1=1077048&r2=1077049&view=diff
==============================================================================
--- hadoop/common/branches/branch-0.20-security-patches/src/hdfs/org/apache/hadoop/hdfs/server/namenode/ListPathsServlet.java
(original)
+++ hadoop/common/branches/branch-0.20-security-patches/src/hdfs/org/apache/hadoop/hdfs/server/namenode/ListPathsServlet.java
Fri Mar  4 03:35:36 2011
@@ -152,7 +152,12 @@ public class ListPathsServlet extends Df
       while (!pathstack.empty()) {
         String p = pathstack.pop();
         try {
-          for (FileStatus i : nnproxy.getListing(p)) {
+          FileStatus[] listing = nnproxy.getListing(p);
+          if (listing == null) {
+            LOG.warn("ListPathsServlet - Path " + p + " does not exist");
+            continue;
+          }
+          for (FileStatus i : listing) {
             if (exclude.matcher(i.getPath().getName()).matches()
                 || !filter.matcher(i.getPath().getName()).matches()) {
               continue;



Mime
View raw message