Avoid checking choked pipe if no extension has more data to write. 53/2853/1
authorDavid Galeano <davidgaleano@turbulenz.biz>
Thu, 10 Jan 2013 02:06:38 +0000 (10:06 +0800)
committerKevron Rees <kevron_m_rees@linux.intel.com>
Thu, 7 Mar 2013 21:01:22 +0000 (13:01 -0800)
lib/parsers.c

index 0f4c2c7..a61c0e2 100644 (file)
@@ -1560,6 +1560,11 @@ lws_issue_raw_ext_access(struct libwebsocket *wsi,
 
                debug("written %d bytes to client\n", eff_buf.token_len);
 
+               /* no extension has more to spill */
+
+               if (!ret)
+                       break;
+
                /* we used up what we had */
 
                eff_buf.token = NULL;