[Title] removed sdb connect/disconnect protocol
authorgiwoong.kim <giwoong.kim@samsung.com>
Thu, 29 Mar 2012 05:28:55 +0000 (14:28 +0900)
committergiwoong.kim <giwoong.kim@samsung.com>
Thu, 29 Mar 2012 05:28:55 +0000 (14:28 +0900)
[Type]
[Module] Emulator
[Priority]
[Jira#]
[Redmine#]
[Problem]
[Cause]
[Solution]
[TestCase]

tizen/src/skin/client/src/org/tizen/emulator/skin/EmulatorSkin.java

index 50e9224..48962e4 100644 (file)
@@ -904,21 +904,20 @@ public class EmulatorSkin {
                                String portNumber = StringUtil.nvl( config.getArg( ArgsConstants.NET_BASE_PORT ) );
 
                                if ( !StringUtil.isEmpty( portNumber ) && !StringUtil.isEmpty( portNumber ) ) {
-                                       int portSdb = Integer.parseInt( portNumber ) + 1;
+                                       int portSdb = Integer.parseInt( portNumber );
 
-                                       ProcessBuilder procConnect = new ProcessBuilder( sdbPath, "connect", "localhost:" + portSdb );
                                        ProcessBuilder procSdb = new ProcessBuilder();
 
                                        if ( SkinUtil.isLinuxPlatform() ) {
                                                procSdb.command( "/usr/bin/gnome-terminal", "--disable-factory",
-                                                               "--title=" + SkinUtil.makeEmulatorName( config ), "-x", sdbPath, "-s", "localhost:"
+                                                               "--title=" + SkinUtil.makeEmulatorName( config ), "-x", sdbPath, "-s", "emulator-"
                                                                                + portSdb, "shell" );
                                        } else if ( SkinUtil.isWindowsPlatform() ) {
-                                               procSdb.command( "cmd.exe", "/c", "start", sdbPath, "-s", "localhost:" + portSdb, "shell" );
+                                               procSdb.command( "cmd.exe", "/c", "start", sdbPath, "-s", "emulator-" + portSdb, "shell" );
                                        }
+                                       logger.log( Level.INFO, procSdb.command().toString() );
 
                                        try {
-                                               procConnect.start(); // connect with sdb
                                                procSdb.start(); // open sdb shell
                                        } catch ( Exception ee ) {
                                                logger.log( Level.SEVERE, ee.getMessage(), ee );
@@ -1183,21 +1182,6 @@ public class EmulatorSkin {
 
                isShutdownRequested = true;
 
-               /* disconnect with sdb */
-               String sdbPath = SkinUtil.getSdbPath();
-               String portNumber = StringUtil.nvl( config.getArg( ArgsConstants.NET_BASE_PORT ) );
-
-               if ( !StringUtil.isEmpty( portNumber ) && !StringUtil.isEmpty( portNumber ) ) {
-                       int portSdb = Integer.parseInt( portNumber ) + 1;
-
-                       ProcessBuilder procDisconnect = new ProcessBuilder( sdbPath, "connect", "localhost:" + portSdb );
-                       try {
-                               procDisconnect.start();
-                       } catch ( IOException e ) {
-                               logger.log( Level.SEVERE, e.getMessage(), e );
-                       }
-               }
-
                if ( !this.shell.isDisposed() ) {
                        this.shell.getDisplay().asyncExec( new Runnable() {
                                @Override