ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From agoncha...@apache.org
Subject [44/50] incubator-ignite git commit: minor
Date Mon, 06 Apr 2015 18:00:14 GMT
minor


Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/369a36d7
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/369a36d7
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/369a36d7

Branch: refs/heads/ignite-674
Commit: 369a36d70f27571cd084b3b1b4990440cd4a510c
Parents: 15cebfc
Author: Yakov Zhdanov <yzhdanov@gridgain.com>
Authored: Mon Apr 6 18:57:34 2015 +0300
Committer: Yakov Zhdanov <yzhdanov@gridgain.com>
Committed: Mon Apr 6 18:57:34 2015 +0300

----------------------------------------------------------------------
 .../main/java/org/apache/ignite/internal/util/IgniteUtils.java  | 5 +++--
 .../internal/processors/hadoop/HadoopCommandLineTest.java       | 3 +--
 2 files changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/369a36d7/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java b/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
index 8a982bc..1aac985 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
@@ -3012,8 +3012,9 @@ public abstract class IgniteUtils {
      * @return {@code true} if and only if the file or directory is successfully deleted,
      *      {@code false} otherwise
      */
-    public static boolean delete(File file) {
-        assert file != null;
+    public static boolean delete(@Nullable File file) {
+        if (file == null)
+            return false;
 
         boolean res = true;
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/369a36d7/modules/hadoop/src/test/java/org/apache/ignite/internal/processors/hadoop/HadoopCommandLineTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/internal/processors/hadoop/HadoopCommandLineTest.java
b/modules/hadoop/src/test/java/org/apache/ignite/internal/processors/hadoop/HadoopCommandLineTest.java
index f6f7a01..d10ee5c 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/internal/processors/hadoop/HadoopCommandLineTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/internal/processors/hadoop/HadoopCommandLineTest.java
@@ -200,8 +200,7 @@ public class HadoopCommandLineTest extends GridCommonAbstractTest {
     @Override protected void afterTestsStopped() throws Exception {
         super.afterTestsStopped();
 
-        if (testWorkDir != null)
-            U.delete(testWorkDir);
+        U.delete(testWorkDir);
     }
 
     /** {@inheritDoc} */


Mime
View raw message