Patchwork fix chardev_init for win32

login
register
mail settings
Submitter TeLeMan
Date April 15, 2010, 4:37 a.m.
Message ID <w2la38b25541004142137nc2cb191dsc6d1aff9e3dd740f@mail.gmail.com>
Download mbox | patch
Permalink /patch/50215/
State New
Headers show

Comments

TeLeMan - April 15, 2010, 4:37 a.m.
chardev_init functions use socket,so socket_init() shoud be placed at
the front of chardev_init on win32.

Signed-off-by: TeLeMan <geleman@gmail.com>
---
 vl.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
Aurelien Jarno - May 18, 2010, 5:57 p.m.
On Thu, Apr 15, 2010 at 12:37:55PM +0800, TeLeMan wrote:
> chardev_init functions use socket,so socket_init() shoud be placed at
> the front of chardev_init on win32.
> 
> Signed-off-by: TeLeMan <geleman@gmail.com>
> ---
>  vl.c |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)

Thanks, applied.

> diff --git a/vl.c b/vl.c
> index 460e050..96835e2 100644
> --- a/vl.c
> +++ b/vl.c
> @@ -3468,6 +3468,8 @@ int main(int argc, char **argv, char **envp)
>      if (default_vga)
>          vga_interface_type = VGA_CIRRUS;
> 
> +    socket_init();
> +
>      if (qemu_opts_foreach(&qemu_chardev_opts, chardev_init_func, NULL, 1) != 0)
>          exit(1);
> 
> @@ -3569,8 +3571,6 @@ int main(int argc, char **argv, char **envp)
>      }
>      configure_icount(icount_option);
> 
> -    socket_init();
> -
>      if (net_init_clients() < 0) {
>          exit(1);
>      }
> -- 
> 1.6.5.1.1367.gcd48
> --
> SUN OF A BEACH
> 
> 
>

Patch

diff --git a/vl.c b/vl.c
index 460e050..96835e2 100644
--- a/vl.c
+++ b/vl.c
@@ -3468,6 +3468,8 @@  int main(int argc, char **argv, char **envp)
     if (default_vga)
         vga_interface_type = VGA_CIRRUS;

+    socket_init();
+
     if (qemu_opts_foreach(&qemu_chardev_opts, chardev_init_func, NULL, 1) != 0)
         exit(1);

@@ -3569,8 +3571,6 @@  int main(int argc, char **argv, char **envp)
     }
     configure_icount(icount_option);

-    socket_init();
-
     if (net_init_clients() < 0) {
         exit(1);
     }