Skip to content

Commit 1c756b3

Browse files
lukegothibaultcha
authored andcommitted
doc: fixed a mistake in tcpsock:receiveany() example in README.md.
1 parent 30678fd commit 1c756b3

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

README.markdown

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7310,7 +7310,7 @@ Timeout for the reading operation is controlled by the [lua_socket_read_timeout]
73107310
```lua
73117311

73127312
sock:settimeouts(1000, 1000, 1000) -- one second timeout for connect/read/write
7313-
local data, err = sock:receiveany(10 * 1024 * 1024) -- read any data, at most 10K
7313+
local data, err = sock:receiveany(10 * 1024) -- read any data, at most 10K
73147314
if not data then
73157315
ngx.say("failed to read any data: ", err)
73167316
return

doc/HttpLuaModule.wiki

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6178,7 +6178,7 @@ Timeout for the reading operation is controlled by the [[#lua_socket_read_timeou
61786178
61796179
<geshi lang="lua">
61806180
sock:settimeouts(1000, 1000, 1000) -- one second timeout for connect/read/write
6181-
local data, err = sock:receiveany(10 * 1024 * 1024) -- read any data, at most 10K
6181+
local data, err = sock:receiveany(10 * 1024) -- read any data, at most 10K
61826182
if not data then
61836183
ngx.say("failed to read any data: ", err)
61846184
return

0 commit comments

Comments
 (0)