From d2f28ea3ae063d44d8ec219a544fd0f70d344747 Mon Sep 17 00:00:00 2001 From: Daan Hoogland Date: Tue, 11 Nov 2014 09:32:09 +0100 Subject: [PATCH] CID-1251369: not null check changed to null check --- server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java b/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java index 10449e3e91e..bcb22421b90 100755 --- a/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java +++ b/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java @@ -314,7 +314,7 @@ public class SnapshotManagerImpl extends ManagerBase implements SnapshotManager, _accountMgr.checkAccess(CallContext.current().getCallingAccount(), null, true, volume); SnapshotInfo snapshot = snapshotFactory.getSnapshot(snapshotId, DataStoreRole.Primary); - if(snapshot != null) + if(snapshot == null) { s_logger.debug("Failed to create snapshot"); throw new CloudRuntimeException("Failed to create snapshot");