From fb447028bc9153b9e9730aa16a34521732b2980c Mon Sep 17 00:00:00 2001 From: Michael Jerris Date: Thu, 30 Nov 2006 23:47:30 +0000 Subject: [PATCH] mod_enum doesn't crash windows now, still a bit to get it to work right. git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3500 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/mod/applications/mod_enum/mod_enum.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/mod/applications/mod_enum/mod_enum.c b/src/mod/applications/mod_enum/mod_enum.c index 863f6ce768..078b963f93 100644 --- a/src/mod/applications/mod_enum/mod_enum.c +++ b/src/mod/applications/mod_enum/mod_enum.c @@ -32,6 +32,10 @@ #include #include +#ifndef WIN32 +#define closesocket close +#endif + static const char modname[] = "mod_enum"; struct enum_record { @@ -495,7 +499,7 @@ static switch_status_t enum_lookup(char *root, char *in, enum_record_t **results done: if (fd > -1) { - close(fd); + closesocket(fd); fd = -1; }