diff options
| author | Shireesh Anjal <anjalshireesh@gmail.com> | 2011-08-11 08:27:26 -0700 |
|---|---|---|
| committer | Shireesh Anjal <anjalshireesh@gmail.com> | 2011-08-11 08:27:26 -0700 |
| commit | d6af18cc4a6c046a0416dadc1f697b19fb113c54 (patch) | |
| tree | 3d09c186746267ac71e3060e28c04d1aa3201948 /src/com.gluster.storage.management.console | |
| parent | 15222c97d166a1899d73b298e228a6c8e4447c8d (diff) | |
| parent | 16d926ab7bc04225032febb9c6f98c9f4f15c01d (diff) | |
Merge pull request #229 from Selvasundaram/master
Gluster online server parsing issue fix
Diffstat (limited to 'src/com.gluster.storage.management.console')
3 files changed, 4 insertions, 4 deletions
diff --git a/src/com.gluster.storage.management.console/src/com/gluster/storage/management/console/actions/StartVolumeAction.java b/src/com.gluster.storage.management.console/src/com/gluster/storage/management/console/actions/StartVolumeAction.java index 2c254e59..c86b66cf 100644 --- a/src/com.gluster.storage.management.console/src/com/gluster/storage/management/console/actions/StartVolumeAction.java +++ b/src/com.gluster.storage.management.console/src/com/gluster/storage/management/console/actions/StartVolumeAction.java @@ -55,7 +55,7 @@ public class StartVolumeAction extends AbstractActionDelegate { List<String> failedVolumes = new ArrayList<String>(); String errorMessage = ""; - for (Volume volume : selectedVolumes) { + for (Volume volume : selectedVolumes.toArray(new Volume[0])) { if (volume.getStatus() == VOLUME_STATUS.ONLINE) { continue; // skip if already started } diff --git a/src/com.gluster.storage.management.console/src/com/gluster/storage/management/console/actions/StopVolumeAction.java b/src/com.gluster.storage.management.console/src/com/gluster/storage/management/console/actions/StopVolumeAction.java index f02d090e..6e5b4d30 100644 --- a/src/com.gluster.storage.management.console/src/com/gluster/storage/management/console/actions/StopVolumeAction.java +++ b/src/com.gluster.storage.management.console/src/com/gluster/storage/management/console/actions/StopVolumeAction.java @@ -65,7 +65,7 @@ public class StopVolumeAction extends AbstractActionDelegate { List<String> failedVolumes = new ArrayList<String>(); String errorMessage = ""; - for (Volume volume : volumes) { + for (Volume volume : volumes.toArray(new Volume[0])) { if (volume.getStatus() == VOLUME_STATUS.OFFLINE) { continue; // skip if already stopped } @@ -138,7 +138,7 @@ public class StopVolumeAction extends AbstractActionDelegate { for (Volume volume : volumes) { if (volume.getStatus() == VOLUME_STATUS.ONLINE) { action.setEnabled(true); - break;// If find an online volume, enable the action + break; // If find an online volume, enable the action } } } diff --git a/src/com.gluster.storage.management.console/src/com/gluster/storage/management/console/dialogs/CreateVolumeWizard.java b/src/com.gluster.storage.management.console/src/com/gluster/storage/management/console/dialogs/CreateVolumeWizard.java index a7b7d251..bfb29ee1 100644 --- a/src/com.gluster.storage.management.console/src/com/gluster/storage/management/console/dialogs/CreateVolumeWizard.java +++ b/src/com.gluster.storage.management.console/src/com/gluster/storage/management/console/dialogs/CreateVolumeWizard.java @@ -111,7 +111,7 @@ public class CreateVolumeWizard extends Wizard { if (error) { MessageDialog.openWarning(getShell(), title, message1); - } else { + } else if (message1.trim().length() > 0) { MessageDialog.openInformation(getShell(), title, message1); } } else { // Start volume is not checked |
