commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nia...@apache.org
Subject svn commit: r609633 - /commons/proper/io/trunk/src/java/org/apache/commons/io/FileUtils.java
Date Mon, 07 Jan 2008 15:14:51 GMT
Author: niallp
Date: Mon Jan  7 07:14:48 2008
New Revision: 609633

URL: http://svn.apache.org/viewvc?rev=609633&view=rev
Log:
IO-77 improve error message

Modified:
    commons/proper/io/trunk/src/java/org/apache/commons/io/FileUtils.java

Modified: commons/proper/io/trunk/src/java/org/apache/commons/io/FileUtils.java
URL: http://svn.apache.org/viewvc/commons/proper/io/trunk/src/java/org/apache/commons/io/FileUtils.java?rev=609633&r1=609632&r2=609633&view=diff
==============================================================================
--- commons/proper/io/trunk/src/java/org/apache/commons/io/FileUtils.java (original)
+++ commons/proper/io/trunk/src/java/org/apache/commons/io/FileUtils.java Mon Jan  7 07:14:48
2008
@@ -1772,7 +1772,8 @@
             destDir.mkdirs();
         }
         if (!destDir.exists()) {
-            throw new IOException("Destination directory does not exist");
+            throw new FileNotFoundException("Destination directory '" + destDir +
+                    "' does not exist [createDestDir=" + createDestDir +"]");
         }
         if (!destDir.isDirectory()) {
             throw new IOException("Destination '" + destDir + "' is not a directory");
@@ -1846,7 +1847,8 @@
             destDir.mkdirs();
         }
         if (!destDir.exists()) {
-            throw new IOException("Destination directory does not exist");
+            throw new FileNotFoundException("Destination directory '" + destDir +
+                    "' does not exist [createDestDir=" + createDestDir +"]");
         }
         if (!destDir.isDirectory()) {
             throw new IOException("Destination '" + destDir + "' is not a directory");



Mime
View raw message