You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by wi...@apache.org on 2012/07/02 14:17:34 UTC

[2/15] git commit: rbd: Fix nullPointerException

rbd: Fix nullPointerException

When no authorization is set for the pool we can't check if the String is empty()

So we check if it's not null


Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/9371a5fd
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/9371a5fd
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/9371a5fd

Branch: refs/heads/rbd
Commit: 9371a5fd1e07b91f2bb1e6be6786c7ab51a58d7d
Parents: ba71643
Author: Wido den Hollander <wi...@widodh.nl>
Authored: Mon Jul 2 14:13:02 2012 +0200
Committer: Wido den Hollander <wi...@widodh.nl>
Committed: Mon Jul 2 14:13:02 2012 +0200

----------------------------------------------------------------------
 .../com/cloud/agent/storage/KVMPhysicalDisk.java   |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/9371a5fd/agent/src/com/cloud/agent/storage/KVMPhysicalDisk.java
----------------------------------------------------------------------
diff --git a/agent/src/com/cloud/agent/storage/KVMPhysicalDisk.java b/agent/src/com/cloud/agent/storage/KVMPhysicalDisk.java
index bb5834c..cb790d9 100644
--- a/agent/src/com/cloud/agent/storage/KVMPhysicalDisk.java
+++ b/agent/src/com/cloud/agent/storage/KVMPhysicalDisk.java
@@ -40,7 +40,7 @@ public class KVMPhysicalDisk {
 
         rbdOpts = "rbd:" + image;
         rbdOpts += ":mon_host=" + monHost + "\\\\:" + monPort;
-        if (authUserName.isEmpty()) {
+        if (authUserName == null) {
             rbdOpts += ":auth_supported=none";
         } else {
             rbdOpts += ":auth_supported=cephx";