aboutsummaryrefslogtreecommitdiffstats
path: root/telephony
diff options
context:
space:
mode:
authorDavid 'Digit' Turner <digit@google.com>2009-05-14 11:25:52 +0200
committerDavid 'Digit' Turner <digit@google.com>2009-05-14 11:25:52 +0200
commit3e7a92854dbf66902da5522ca3dfb2011c0ce8be (patch)
tree9d789cdf76045d2f72a03527e4f24f3cf30f069c /telephony
parent3d2300cb2f8f575d9e0c553c88790b5d79dda1b6 (diff)
downloadexternal_qemu-3e7a92854dbf66902da5522ca3dfb2011c0ce8be.zip
external_qemu-3e7a92854dbf66902da5522ca3dfb2011c0ce8be.tar.gz
external_qemu-3e7a92854dbf66902da5522ca3dfb2011c0ce8be.tar.bz2
This fixes sock_address_init_resolv() to properly parse the linked-list returned by getaddrinfo().
The previous implementation simply took the first entry, which could be an IPv6 address instead of an IPv4 one in certain OS setups. This created problems when "localhost" resolved to :::1 instead of 127.0.0.1. For example, when implementing inter-emulator telephony or SMS, since the caller would try to connect to localhost:5556, which was resolved to :::1:5556 while the received is listening on 127.0.0.1:5556 Also disable debugging traces that should not be activated. And make the error messages in sockets.c only dumped to the terminal when -debug-socket is active.
Diffstat (limited to 'telephony')
-rw-r--r--telephony/sysdeps_qemu.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/telephony/sysdeps_qemu.c b/telephony/sysdeps_qemu.c
index ec0b3f5..a88f2fb 100644
--- a/telephony/sysdeps_qemu.c
+++ b/telephony/sysdeps_qemu.c
@@ -12,6 +12,7 @@
#include "sockets.h"
#include "sysdeps.h"
#include "qemu-timer.h"
+#include "qemu-char.h"
#ifdef _WIN32
#include <winsock2.h>
#else
@@ -23,7 +24,7 @@
#include <netdb.h>
#endif
-#define DEBUG 1
+#define DEBUG 0
#define D_ACTIVE DEBUG