# HG changeset patch # User jbe # Date 1428449706 -7200 # Node ID 0561abcc68ee95c29167b2926f3a651e8a5b7371 # Parent fdc1bb7105446d6fccd53b4d66545fc128d2253a Bugfix regarding TCP PSH diff -r fdc1bb710544 -r 0561abcc68ee moonbridge_io.c --- a/moonbridge_io.c Wed Apr 08 01:22:20 2015 +0200 +++ b/moonbridge_io.c Wed Apr 08 01:35:06 2015 +0200 @@ -248,7 +248,7 @@ handle->writebufcnt += strlen - handle->writeqoff; break; } else { - moonbr_io_handle_set_nopush(L, handle, flush ? 0 : 1); + moonbr_io_handle_set_nopush(L, handle, 1); written = 0; memcpy(handle->writebuf + handle->writebufcnt, str + handle->writeqoff, MOONBR_IO_WRITEBUFLEN - handle->writebufcnt); handle->writeqoff += MOONBR_IO_WRITEBUFLEN - handle->writebufcnt; @@ -283,6 +283,7 @@ lua_rawseti(L, -2, handle->writeqout++); } if (flush) { + moonbr_io_handle_set_nopush(L, handle, 0); written = 0; while (written < handle->writebufcnt) { result = write(handle->fd, handle->writebuf + written, handle->writebufcnt - written);