aboutsummaryrefslogtreecommitdiff
path: root/vl.c
diff options
context:
space:
mode:
authorIsaku Yamahata <yamahata@valinux.co.jp>2010-05-27 14:38:47 +0900
committerBlue Swirl <blauwirbel@gmail.com>2010-06-10 16:48:06 +0000
commit0f2ad63fcb75c9679ff7d47f6b2235dfc646de35 (patch)
tree37dc4f4a4bb4bb209c31ef0936ba6554091b8a64 /vl.c
parent60a3992e759d92b9111871b0881e65519c750b01 (diff)
downloadqemu-0f2ad63fcb75c9679ff7d47f6b2235dfc646de35.zip
qemu-0f2ad63fcb75c9679ff7d47f6b2235dfc646de35.tar.gz
qemu-0f2ad63fcb75c9679ff7d47f6b2235dfc646de35.tar.bz2
main: allocate gui_timer only once.
fix memory leak. there is no need to allocate more than one gui_timer. Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Diffstat (limited to 'vl.c')
-rw-r--r--vl.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/vl.c b/vl.c
index 6d08ec8..3d7ce52 100644
--- a/vl.c
+++ b/vl.c
@@ -3794,6 +3794,7 @@ int main(int argc, char **argv, char **envp)
if (dcl->dpy_refresh != NULL) {
ds->gui_timer = qemu_new_timer(rt_clock, gui_update, ds);
qemu_mod_timer(ds->gui_timer, qemu_get_clock(rt_clock));
+ break;
}
dcl = dcl->next;
}