File: nr.lua

package info (click to toggle)
lua-ljsyscall 0.12-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,732 kB
  • sloc: ansic: 434; sh: 59; makefile: 3
file content (37 lines) | stat: -rw-r--r-- 806 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
local require, error, assert, tonumber, tostring,
setmetatable, pairs, ipairs, unpack, rawget, rawset,
pcall, type, table, string = 
require, error, assert, tonumber, tostring,
setmetatable, pairs, ipairs, unpack, rawget, rawset,
pcall, type, table, string

local abi = require "syscall.abi"

local nr = require("syscall.linux." .. abi.arch .. ".nr")

if nr.SYS.socketcall then nr.socketcalls = {
  SOCKET      = 1,
  BIND        = 2,
  CONNECT     = 3,
  LISTEN      = 4,
  ACCEPT      = 5,
  GETSOCKNAME = 6,
  GETPEERNAME = 7,
  SOCKETPAIR  = 8,
  SEND        = 9,
  RECV        = 10,
  SENDTO      = 11,
  RECVFROM    = 12,
  SHUTDOWN    = 13,
  SETSOCKOPT  = 14,
  GETSOCKOPT  = 15,
  SENDMSG     = 16,
  RECVMSG     = 17,
  ACCEPT4     = 18,
  RECVMMSG    = 19,
  SENDMMSG    = 20,
}
end

return nr