b1f7c349b5Add support for serial devices as socket streams on unix.
Sam Roberts
2012-02-23 17:12:37 -08:00
3b19f2a7edtestsrvr asserts when test finishes successfully. When the test client finishes, the test server asserts with a "closed" message. After looking carefully at this, I think the tests are running successfully and passing. Since it appears to be a test failure, I modified the server to allow the client to close the control connection.
Sam Roberts
2011-08-08 16:23:06 -07:00
dace50628cUtility to find how many TCP connections can be made.
Sam Roberts
2011-06-28 17:48:21 -07:00
f63d616bc0Use poll by default for socket.connect(), instead of select(). Connect timeouts are implemented by waiting on the new socket descriptor. When select() is used for this, it imposes an arbitrary limit on the number of connections that can be made, usually 1024-3. Using poll() removes this limit on the number of simultaneous TCP connections can be made using luasocket. The previous default implementation using select() is available by defining SOCKET_SELECT. Note that using socket.select() always uses select(), so it isn't possible to wait on an arbitrary number of connections at once.
Sam Roberts
2011-06-27 17:04:32 -07:00
21698c7665Receive of zero for UDP is now possible. Previously, receive of zero was considered to be "closed", but that is only true for stream-based protocols, like TCP.
Sam Roberts
2011-08-08 16:11:47 -07:00
c37f71d062Test showing failure to receive a zero-length packet.
Sam Roberts
2011-08-08 16:49:20 -07:00
51acb54760Stop returning an error after successful send of zero length UDP packets A zero-length send is invalid with TCP, but well defined with UDP. udp:send"" was returning (nil,"refused"), indicating that it failed when the packet was actually sent. The test script reproduces the bug, and includes a tcpdump of the zero length packet being sent.
Sam Roberts
2011-06-17 13:51:34 -07:00
a8b19e5367OS X CFLAGS definition caused silent failure to build debug version of luasocket. The luasocket tests require LUASOCKET_DEBUG to be defined at build time, but for OS X if COMPAT was undefined, the command line looked like ... -I -DLUASOCKET_DEBUG ... so that the the macro definition was silently being treated as the argument to -I. Result is the macro was never set, and tests would never run. Fixed by moving -I to the (optional) definition of the location of compat headers.
Sam Roberts
2011-09-27 12:26:38 -07:00
1f704cfb89Add all-unix and install-unix targets which include all modules supported on unix. Besides standard socket and mime modules, this includes unix domain socket support.
Sam Roberts
2011-09-27 12:54:51 -07:00
826589afcdAdd location of Ubuntu's lua5.1 headers to config.
Sam Roberts
2011-08-08 17:12:34 -07:00
e81a6ff623Conditional creation of p_timeout instance 'tm'
Liam Devine
2011-07-07 01:14:16 +01:00
9a58252528change localhost to loopback ip to prevent error on my mac box????
Liam Devine
2011-07-05 13:40:22 +01:00
51187ecc90Updated readme version and os tested
Liam Devine
2011-07-04 23:42:14 +01:00
c8eed36788This is a replacement for luaL_typerror , removed from Lua 5.2, which corrects the spelling. NOTE: There is one failing test in.the /test/testsrvr.lua and /test/testclnt.lua combination which was present in the repo I cloned from.
Liam Devine
2011-07-04 23:35:16 +01:00
e15ed19db6Compiles with Lua 5.1.4 and Lua 5.2.0-beta, although the makefile needs sorting out to take maybe a version number and also the local paths need removing.
Liam Devine
2011-07-04 23:31:14 +01:00
a984607f28inet: return more useful errors
Paul Aurich
2011-07-03 14:28:22 -07:00
7893d9ece2inet: refactor getpeername to allocate the struct on the stack
Paul Aurich
2011-07-03 14:28:12 -07:00
8393c76180Fix getpeername to work with IPv6 addresses
Florian Zeitz
2011-06-30 21:49:39 +02:00
594f826aa1Add support for connecting to IPv6 hosts
Florian Zeitz
2011-06-15 00:51:02 +02:00
f871a29f27Add support for the IPV6_V6ONLY socket option defaulting to on.
Florian Zeitz
2011-06-14 02:47:43 +02:00
4df1618aabAdapt socket.bind() to create a IPv4 or IPv6 depending on the address given
Florian Zeitz
2011-06-14 02:04:37 +02:00
5065a2585cdns: Rename toip6() to getaddrinfo() since the old name is misleading
Florian Zeitz
2011-06-14 01:40:11 +02:00
923eef1929Rework binding IPv6 sockets by harmonizing it with the IPv4 variant
Florian Zeitz
2011-06-14 01:17:07 +02:00
5c33ef9997url.escape/url.unescape: Fix to return *only* the encoded/decoded string (thanks moodydeath)
Matthew Wild
2011-05-12 13:44:16 +01:00
908ee2cce1Fix two crashes and add -Wshadow so that this can't happen again.
Paul Aurich
2011-04-27 10:42:20 -07:00
dd83e0a849#ifdef EAI_BADHINTS and EAI_PROTOCOL which don't seem available on my system (Linux/glibc 2.11)
Matthew Wild
2011-04-08 14:11:37 +01:00
2778766d67Preliminary IPv6 support for v2.1
Diego Nehab
2012-04-11 13:21:25 -07:00
3a8ba90dfbSaving before big changes to support IPv6.
Diego Nehab
2011-05-25 20:57:22 +00:00
bce60be30fDecent makefiles!
Diego Nehab
2009-05-27 09:31:38 +00:00
d1a72435d5New release.
Diego Nehab
2007-10-13 23:55:20 +00:00
81ebe649f0This commit was manufactured by cvs2svn to create tag 'luasocket-2-0-2'.
cvs2git convertor
2007-10-11 21:16:29 +00:00
52ac60af81Tested each sample.
Diego Nehab
2007-10-11 21:16:28 +00:00
e394956cdeGlobal variable references.
Diego Nehab
2007-07-11 19:25:47 +00:00
185b6d806cTypo.
Diego Nehab
2007-06-15 06:38:29 +00:00
6d23f14aebWaiting for Roberto's remarks.
Diego Nehab
2007-06-15 06:29:07 +00:00
1c487e4be8Almost ready to release.
Diego Nehab
2007-06-15 06:28:56 +00:00
e381bde1eaModified and tested on Linux.
Diego Nehab
2007-06-12 00:06:29 +00:00
c893c7abfbRemoved os.exit from test.
Diego Nehab
2007-06-11 23:52:48 +00:00
3cd10f5ab6Crashy bug fixed in recvraw. Also fixed returns on closed socket.
Diego Nehab
2007-06-11 23:44:54 +00:00
3074a8f56bBefore sending to Roberto.
Diego Nehab
2007-05-31 22:27:40 +00:00
7b195164b0Lua Gem.
Diego Nehab
2007-05-31 21:23:42 +00:00
37f266ceeaAdded simple unix tests.
Diego Nehab
2007-04-09 22:04:13 +00:00
be2e467929Couple bug fixes.
Diego Nehab
2007-03-12 04:08:40 +00:00
8bf9fb51ddThread safety...
Diego Nehab
2006-04-28 07:06:42 +00:00
9d218a9379Tested on Windows and it works.
Diego Nehab
2006-04-26 21:39:27 +00:00
3dd6a16bcbAdjusted projects for compat-5.1r5
Diego Nehab
2006-04-20 04:43:12 +00:00
d86af2f680Tidy.
Diego Nehab
2006-04-20 04:32:06 +00:00
575113fe77Spell checked and updated modification date.
Diego Nehab
2006-04-20 04:27:13 +00:00
c72632dca5Reverted back to Linux.
Diego Nehab
2006-04-20 04:27:01 +00:00
75f51d5bc7Almost ready to release 2.0.1
Diego Nehab
2006-04-20 04:16:23 +00:00
316e205cd4Reverted to Linux default.
Diego Nehab
2006-04-18 20:12:27 +00:00
61cbb67a27Adding wishes for 5.2
Diego Nehab
2006-04-14 08:00:23 +00:00
44c7f0f47bMentions that closed sockets are ignored by select.
Diego Nehab
2006-04-14 02:04:38 +00:00
e8650bbf16http.request was using old host header during redirects.
Diego Nehab
2006-04-13 07:00:24 +00:00
be57b387d2Stupid bug was reusing the nreqt.headers.host during redirect.
Diego Nehab
2006-04-12 08:04:09 +00:00
11282d17c8Almost done 2.0.1.
Diego Nehab
2006-04-03 04:45:42 +00:00
e9d477aba3Final patches...
Diego Nehab
2006-04-03 03:10:56 +00:00
7121359526Better image to test mail.
Diego Nehab
2006-04-02 23:24:37 +00:00
93806208c7Updates for 2.0.1 on the way.
Diego Nehab
2006-03-19 21:22:21 +00:00
09ad4b299cChose option 1) for http.lua. Need to fix everything to make sure it works with the new compat-5.1
Diego Nehab
2006-03-14 09:04:15 +00:00
6248b915cbFixing bugs...
Diego Nehab
2006-03-13 07:16:39 +00:00
00e74c304cBug in footer.
Diego Nehab
2005-12-01 21:56:12 +00:00
96da86a81fSimplified documentation of send().
Diego Nehab
2005-11-24 20:29:28 +00:00
7dace4af7eChanged LIB/SHARE to CDIR/LDIR.
Diego Nehab
2005-11-22 20:51:28 +00:00
d55a5826e8Few tweaks in installation, some missing files, etc.
Diego Nehab
2005-11-22 08:33:29 +00:00
a2b780bf7aSpell checking on the manuals. David's changes to lp.lua.
Diego Nehab
2005-11-21 07:04:44 +00:00
71f483496dWorks in Finnish now! Who would say...
Diego Nehab
2005-11-21 07:04:18 +00:00
5e09779c7fIn pre release mode!
Diego Nehab
2005-11-20 08:56:19 +00:00
f20f4889bfChanged prefix of function names to match module names. Removed some warnings and useless code.
Diego Nehab
2005-11-20 07:20:26 +00:00
087b4f865dLua Workshop presentation.
Diego Nehab
2005-11-02 02:53:16 +00:00
f4dadea763Before compiling on Windows.
Diego Nehab
2005-10-07 04:40:59 +00:00
562d8cceb7Default config is for Linux.
Diego Nehab
2005-10-05 03:20:22 +00:00
64d7b02490Returning a function.
Diego Nehab
2005-10-05 03:17:29 +00:00
72eceedc62Bugs sent by David.
Diego Nehab
2005-10-05 03:16:17 +00:00
a65c599fc5Test back to localhost.
Diego Nehab
2005-09-29 22:32:33 +00:00
8420541720Tested on Windows.
Diego Nehab
2005-09-29 22:26:35 +00:00
a32c6d9140Almost ready to release.
Diego Nehab
2005-09-29 06:11:42 +00:00
773e35ced3Compiled on Windows. Fixed a bunch of stuff. Almost ready to release. Implemented a nice dispatcher! Non-blocking check-links and forward server use the dispatcher.
Diego Nehab
2005-08-23 05:53:14 +00:00
5e8ae76248Dispatcher working for check-links. Need to get it working with forwarder.
Diego Nehab
2005-08-19 01:35:26 +00:00
0c3cdd5ef2Final push for release...
Diego Nehab
2005-08-12 05:56:32 +00:00
37f7af4b9fAdded check-links-nb.lua that check links in a non-blocking way.
Diego Nehab
2005-06-20 04:51:55 +00:00
ae4ba2aa98Before tidying up directory structure.
Diego Nehab
2005-06-18 21:10:33 +00:00
4d455c6206Using core.so instead of csocket.so and cmime.so.
Diego Nehab
2005-06-17 04:04:55 +00:00
65c35845c5Working on the manual.
Diego Nehab
2005-06-14 04:29:23 +00:00
8b114f3bf4Stupid bug in http.lua.
Diego Nehab
2005-06-12 22:02:21 +00:00
b22f6f3830Starting work on final version.
Diego Nehab
2005-05-17 22:10:46 +00:00
9596c7f95dBug in forward.lua. Wasn't breaking from the loop.
Diego Nehab
2005-04-21 05:38:07 +00:00
434e8e014cBetter connection handling.
Diego Nehab
2005-04-21 03:15:34 +00:00
4e3cf63c95Removed debuging prints.
Diego Nehab
2005-04-20 19:04:47 +00:00
2a00a5ad50Trying to get non-blocking connect to work.
Diego Nehab
2005-04-20 18:57:47 +00:00
693a201db6Wrong namespace.
Diego Nehab
2005-04-13 22:18:28 +00:00
5e75dc0857Wrong class...
Diego Nehab
2005-04-13 22:18:21 +00:00
e7b7c36aeaTiny bug in forward.lua
Diego Nehab
2005-03-11 02:27:59 +00:00
6dc9c1096aSeems to be working on windows.
Diego Nehab
2005-03-11 02:21:27 +00:00
e57f9e9964Apparently, non-blocking connect doesn't work on windows if you use 0 timeout in the select call...
Diego Nehab
2005-03-11 00:20:21 +00:00
63e3d7c5b0Forward server works for multiple tunnels. Http.lua has been patched to support non-blocking everything. Makefile for linux has been updated with new names.
Diego Nehab
2005-03-10 02:15:04 +00:00