*
* @author Milan Bouchet-Valat
*/
+#include "platform.h"
+#include "gnunet_common.h"
+
#include <stdlib.h>
#include <assert.h>
#include <errno.h>
#include <string.h>
-#include "platform.h"
-#include "gnunet_common.h"
#include "gnunet_nat_lib.h"
#include "nat.h"
#include "upnp-discover.h"
}
/* Try IPv4 and IPv6 as we don't know what's the format */
+#ifndef MINGW
if (inet_aton (ext_addr, &addr) != 0)
+#else
+ addr.S_un.S_addr = inet_addr(ext_addr);
+ if (addr.S_un.S_addr == INADDR_NONE)
+#endif
{
handle->ext_addr = GNUNET_malloc (sizeof (struct sockaddr_in));
handle->ext_addr->sa_family = AF_INET;