aboutsummaryrefslogtreecommitdiff
path: root/src/microspdy/io_raw.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/microspdy/io_raw.c')
-rw-r--r--src/microspdy/io_raw.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/microspdy/io_raw.c b/src/microspdy/io_raw.c
index 58127e84..357e7d84 100644
--- a/src/microspdy/io_raw.c
+++ b/src/microspdy/io_raw.c
@@ -159,6 +159,7 @@ SPDYF_raw_is_pending(struct SPDY_Session *session)
159int 159int
160SPDYF_raw_before_write(struct SPDY_Session *session) 160SPDYF_raw_before_write(struct SPDY_Session *session)
161{ 161{
162#if HAVE_DECL_TCP_CORK
162 if(0 == (SPDY_DAEMON_FLAG_NO_DELAY & session->daemon->flags)) 163 if(0 == (SPDY_DAEMON_FLAG_NO_DELAY & session->daemon->flags))
163 { 164 {
164 int val = 1; 165 int val = 1;
@@ -168,6 +169,7 @@ SPDYF_raw_before_write(struct SPDY_Session *session)
168 if(-1 == ret) 169 if(-1 == ret)
169 SPDYF_DEBUG("WARNING: Couldn't set the new connection to TCP_CORK"); 170 SPDYF_DEBUG("WARNING: Couldn't set the new connection to TCP_CORK");
170 } 171 }
172#endif
171 173
172 return SPDY_YES; 174 return SPDY_YES;
173} 175}
@@ -176,6 +178,7 @@ SPDYF_raw_before_write(struct SPDY_Session *session)
176int 178int
177SPDYF_raw_after_write(struct SPDY_Session *session, int was_written) 179SPDYF_raw_after_write(struct SPDY_Session *session, int was_written)
178{ 180{
181#if HAVE_DECL_TCP_CORK
179 if(SPDY_YES == was_written && 0 == (SPDY_DAEMON_FLAG_NO_DELAY & session->daemon->flags)) 182 if(SPDY_YES == was_written && 0 == (SPDY_DAEMON_FLAG_NO_DELAY & session->daemon->flags))
180 { 183 {
181 int val = 0; 184 int val = 0;
@@ -186,5 +189,6 @@ SPDYF_raw_after_write(struct SPDY_Session *session, int was_written)
186 SPDYF_DEBUG("WARNING: Couldn't unset the new connection to TCP_CORK"); 189 SPDYF_DEBUG("WARNING: Couldn't unset the new connection to TCP_CORK");
187 } 190 }
188 191
192#endif
189 return was_written; 193 return was_written;
190} 194}