For lua 5.3
I make a change to tools.lua and frame.lua
local struct = string.pack and string or require'struct'
and when I use a websocket client connect to the server ,
the server throws errors , like :
./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2F5AC tcp{client}: 23E6C860
./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2DB2C tcp{client}: 11A68DA8
./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2DB2C tcp{client}: 11A55D30
./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2E32C tcp{client}: 11A43CB8
./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2DB2C tcp{client}: 11A68DA8
./pc/lualib/websocket\tools.lua:114: bad argument #3 to 'pack' (integer overflow) thread: 00A2E32C tcp{client}: 11A7FF18
./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2E2AC tcp{client}: 23E6C860
./pc/lualib/websocket\tools.lua:114: bad argument #4 to 'pack' (integer overflow) thread: 00A2DB2C tcp{client}: 11A43CB8
./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2E32C tcp{client}: 11A55D30
./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2E2AC tcp{client}: 11A360C8
./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2DB2C tcp{client}: 26DDD060
./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2E32C tcp{client}: 23E6C860
./pc/lualib/websocket\tools.lua:114: bad argument #3 to 'pack' (integer overflow) thread: 00A2E2AC tcp{client}: 11A68DA8
./pc/lualib/websocket\tools.lua:114: bad argument #4 to 'pack' (integer overflow) thread: 00A2E4AC tcp{client}: 11A7FF18
For lua 5.3 I make a change to tools.lua and frame.lua local struct = string.pack and string or require'struct'
and when I use a websocket client connect to the server , the server throws errors , like : ./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2F5AC tcp{client}: 23E6C860 ./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2DB2C tcp{client}: 11A68DA8 ./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2DB2C tcp{client}: 11A55D30 ./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2E32C tcp{client}: 11A43CB8 ./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2DB2C tcp{client}: 11A68DA8 ./pc/lualib/websocket\tools.lua:114: bad argument #3 to 'pack' (integer overflow) thread: 00A2E32C tcp{client}: 11A7FF18 ./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2E2AC tcp{client}: 23E6C860 ./pc/lualib/websocket\tools.lua:114: bad argument #4 to 'pack' (integer overflow) thread: 00A2DB2C tcp{client}: 11A43CB8 ./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2E32C tcp{client}: 11A55D30 ./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2E2AC tcp{client}: 11A360C8 ./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2DB2C tcp{client}: 26DDD060 ./pc/lualib/websocket\tools.lua:114: bad argument #2 to 'pack' (integer overflow) thread: 00A2E32C tcp{client}: 23E6C860 ./pc/lualib/websocket\tools.lua:114: bad argument #3 to 'pack' (integer overflow) thread: 00A2E2AC tcp{client}: 11A68DA8 ./pc/lualib/websocket\tools.lua:114: bad argument #4 to 'pack' (integer overflow) thread: 00A2E4AC tcp{client}: 11A7FF18
what's the mistake I took ??