[Title] emulator-manager : modify checking emulator start routine.
authorjihye kim <jihye1128.kim@samsung.com>
Wed, 12 Dec 2012 03:54:55 +0000 (12:54 +0900)
committerjihye kim <jihye1128.kim@samsung.com>
Wed, 12 Dec 2012 03:54:55 +0000 (12:54 +0900)
[Desc.] modify checking emulator start routine.
[Issue] N/A

src/org/tizen/emulator/manager/vms/Launcher.java

index 1e22f1e..89a1a45 100644 (file)
@@ -443,20 +443,26 @@ class MonitoringEmulator extends Thread {
        }
 
        public void run() {
-               while (true) {
+               boolean isChecking = false;
+               for (int i = 0; i < 8 ; i++) {
                        if (VMsWorker.checking(property)) {
+                               isChecking = true;
                                CheckingRunningEmulator.removeEmulator(property.getName());
                                break;
                        }
 
                        synchronized(this) {
                                try {
-                                       this.wait(500);
+                                       this.wait(1000);
                                } catch (InterruptedException e) {
                                        EMLogger.getLogger().warning(e.getMessage());
                                        break;
                                }
                        }
                }
+
+               if (!isChecking) {
+                       CheckingRunningEmulator.removeEmulator(property.getName());
+               }
        }
 }
\ No newline at end of file