Beta2 is out! Total timeout works on Windows.

This commit is contained in:
Diego Nehab
2004-07-26 05:17:37 +00:00
parent d914007507
commit 911e8d7e7f
9 changed files with 77 additions and 123 deletions

View File

@ -81,10 +81,10 @@ int buf_meth_send(lua_State *L, p_buf buf) {
const char *data = luaL_checklstring(L, 2, &size);
long start = (long) luaL_optnumber(L, 3, 1);
long end = (long) luaL_optnumber(L, 4, -1);
if (start < 0) start = size+start+1;
if (end < 0) end = size+end+1;
if (start < 1) start = 1;
if (end > (long) size) end = size;
if (start < 0) start = (long) (size+start+1);
if (end < 0) end = (long) (size+end+1);
if (start < 1) start = (long) 1;
if (end > (long) size) end = (long) size;
if (start <= end) err = sendraw(buf, data+start-1, end-start+1, &sent);
/* check if there was an error */
if (err != IO_DONE) {