summaryrefslogtreecommitdiff
path: root/main/http.c
diff options
context:
space:
mode:
authorLuigi Rizzo <rizzo@icir.org>2006-10-06 15:59:57 +0000
committerLuigi Rizzo <rizzo@icir.org>2006-10-06 15:59:57 +0000
commit3f641c604883553c41dd61595bcf6e051c08be9c (patch)
treeae8887bc4336f2bf677fa32ea2a19c4486f5abeb /main/http.c
parentccca5843fde0d2b27fb2da684e87786cdee6af4c (diff)
make sure sockets are blocking when they should be blocking.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@44568 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'main/http.c')
-rw-r--r--main/http.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/main/http.c b/main/http.c
index 0a7844696..d56f098c9 100644
--- a/main/http.c
+++ b/main/http.c
@@ -504,6 +504,8 @@ static void *http_root(void *data)
}
ser = ast_calloc(1, sizeof(*ser));
if (ser) {
+ int flags = fcntl(fd, F_GETFL);
+ fcntl(fd, F_SETFL, flags & ~O_NONBLOCK);
ser->fd = fd;
memcpy(&ser->requestor, &sin, sizeof(ser->requestor));
if ((ser->f = fdopen(ser->fd, "w+"))) {