aboutsummaryrefslogtreecommitdiffstats
path: root/vl-android-ui.c
diff options
context:
space:
mode:
authorVladimir Chtchetkine <vchtchetkine@google.com>2010-12-06 10:55:11 -0800
committerVladimir Chtchetkine <vchtchetkine@google.com>2010-12-06 10:56:24 -0800
commitd87b080495e71ada650b165a1f06616b433e6073 (patch)
treeb33edad3c18c7e962539d8c94250cd9ee8baedf1 /vl-android-ui.c
parentfced4df82222b898580557de7313d86b5d6934f3 (diff)
downloadexternal_qemu-d87b080495e71ada650b165a1f06616b433e6073.zip
external_qemu-d87b080495e71ada650b165a1f06616b433e6073.tar.gz
external_qemu-d87b080495e71ada650b165a1f06616b433e6073.tar.bz2
Submit merged
Squashed commit of the following: commit aeefab810c6331e2f96e81f20e4408b39dd3a2ca Author: Vladimir Chtchetkine <vchtchetkine@google.com> Date: Thu Dec 2 07:40:34 2010 -0800 Implement -attach-core UI option Change-Id: I4168e2d707cab1b4873ee16d86d5126c1a316abf Change-Id: I2da1ef5d53641f3c60d83d8d5ddf3aff34b0c6c7
Diffstat (limited to 'vl-android-ui.c')
-rw-r--r--vl-android-ui.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/vl-android-ui.c b/vl-android-ui.c
index d693d83..316902c 100644
--- a/vl-android-ui.c
+++ b/vl-android-ui.c
@@ -33,6 +33,7 @@
#include "qemu-timer.h"
#include "qemu-char.h"
#include "block.h"
+#include "sockets.h"
#include "audio/audio.h"
#include "android/android.h"
@@ -40,6 +41,7 @@
#include "android/globals.h"
#include "android/utils/bufprint.h"
#include "android/utils/system.h"
+#include "android/core-connection.h"
#ifdef CONFIG_MEMCHECK
#include "memcheck/memcheck.h"
@@ -201,6 +203,9 @@ extern int android_display_bpp;
extern void dprint( const char* format, ... );
+/* Instance of the "attach UI" Emulator's core console client. */
+extern CoreConnection* attach_client;
+
#define TFR(expr) do { if ((expr) != -1) break; } while (errno == EINTR)
/* compute with 96 bit intermediate result: (a*b)/c */
@@ -588,6 +593,13 @@ int main(int argc, char **argv, char **envp)
//qemu_chr_initial_reset();
main_loop();
+
+ if (attach_client != NULL) {
+ core_connection_detach(attach_client);
+ core_connection_close(attach_client);
+ core_connection_free(attach_client);
+ }
+
quit_timers();
return 0;
}