mirror of
https://github.com/glebarez/go-sqlite.git
synced 2025-10-05 07:46:50 +08:00
12471 lines
573 KiB
Go
12471 lines
573 KiB
Go
// Code generated by 'ccgo -export-defines "" -o internal/mptest/main_darwin_arm64.go -trace-translation-units testdata/sqlite-src-3350500/mptest/mptest.c -Itestdata/sqlite-amalgamation-3350500 -l modernc.org/sqlite/lib -DNDEBUG -DHAVE_USLEEP -DLONGDOUBLE_TYPE=double -DSQLITE_CORE -DSQLITE_ENABLE_COLUMN_METADATA -DSQLITE_ENABLE_FTS5 -DSQLITE_ENABLE_GEOPOLY -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_MEMORY_MANAGEMENT -DSQLITE_ENABLE_OFFSET_SQL_FUNC -DSQLITE_ENABLE_PREUPDATE_HOOK -DSQLITE_ENABLE_RBU -DSQLITE_ENABLE_RTREE -DSQLITE_ENABLE_SNAPSHOT -DSQLITE_ENABLE_STAT4 -DSQLITE_ENABLE_UNLOCK_NOTIFY -DSQLITE_LIKE_DOESNT_MATCH_BLOBS -DSQLITE_MUTEX_APPDEF=1 -DSQLITE_SOUNDEX -DSQLITE_THREADSAFE=1 -DSQLITE_MUTEX_NOOP -DSQLITE_OS_UNIX=1 -DSQLITE_WITHOUT_ZONEMALLOC', DO NOT EDIT.
|
|
|
|
package main
|
|
|
|
import (
|
|
"math"
|
|
"reflect"
|
|
"sync/atomic"
|
|
"unsafe"
|
|
|
|
"modernc.org/libc"
|
|
"modernc.org/libc/sys/types"
|
|
"modernc.org/sqlite/lib"
|
|
)
|
|
|
|
var _ = math.Pi
|
|
var _ reflect.Kind
|
|
var _ atomic.Value
|
|
var _ unsafe.Pointer
|
|
var _ types.Size_t
|
|
|
|
func main() { libc.Start(main1) }
|
|
|
|
const (
|
|
ACCESSX_MAX_DESCRIPTORS = 100
|
|
ACCESSX_MAX_TABLESIZE = 16384
|
|
BIG_ENDIAN = 4321
|
|
BUFSIZ = 1024
|
|
BUS_ADRALN = 1
|
|
BUS_ADRERR = 2
|
|
BUS_NOOP = 0
|
|
BUS_OBJERR = 3
|
|
BYTE_ORDER = 1234
|
|
CLD_CONTINUED = 6
|
|
CLD_DUMPED = 3
|
|
CLD_EXITED = 1
|
|
CLD_KILLED = 2
|
|
CLD_NOOP = 0
|
|
CLD_STOPPED = 5
|
|
CLD_TRAPPED = 4
|
|
CPUMON_MAKE_FATAL = 0x1000
|
|
DEFAULT_TIMEOUT = 10000
|
|
E2BIG = 7
|
|
EACCES = 13
|
|
EADDRINUSE = 48
|
|
EADDRNOTAVAIL = 49
|
|
EAFNOSUPPORT = 47
|
|
EAGAIN = 35
|
|
EALREADY = 37
|
|
EAUTH = 80
|
|
EBADARCH = 86
|
|
EBADEXEC = 85
|
|
EBADF = 9
|
|
EBADMACHO = 88
|
|
EBADMSG = 94
|
|
EBADRPC = 72
|
|
EBUSY = 16
|
|
ECANCELED = 89
|
|
ECHILD = 10
|
|
ECONNABORTED = 53
|
|
ECONNREFUSED = 61
|
|
ECONNRESET = 54
|
|
EDEADLK = 11
|
|
EDESTADDRREQ = 39
|
|
EDEVERR = 83
|
|
EDOM = 33
|
|
EDQUOT = 69
|
|
EEXIST = 17
|
|
EFAULT = 14
|
|
EFBIG = 27
|
|
EFTYPE = 79
|
|
EHOSTDOWN = 64
|
|
EHOSTUNREACH = 65
|
|
EIDRM = 90
|
|
EILSEQ = 92
|
|
EINPROGRESS = 36
|
|
EINTR = 4
|
|
EINVAL = 22
|
|
EIO = 5
|
|
EISCONN = 56
|
|
EISDIR = 21
|
|
ELAST = 106
|
|
ELOOP = 62
|
|
EMFILE = 24
|
|
EMLINK = 31
|
|
EMSGSIZE = 40
|
|
EMULTIHOP = 95
|
|
ENAMETOOLONG = 63
|
|
ENEEDAUTH = 81
|
|
ENETDOWN = 50
|
|
ENETRESET = 52
|
|
ENETUNREACH = 51
|
|
ENFILE = 23
|
|
ENOATTR = 93
|
|
ENOBUFS = 55
|
|
ENODATA = 96
|
|
ENODEV = 19
|
|
ENOENT = 2
|
|
ENOEXEC = 8
|
|
ENOLCK = 77
|
|
ENOLINK = 97
|
|
ENOMEM = 12
|
|
ENOMSG = 91
|
|
ENOPOLICY = 103
|
|
ENOPROTOOPT = 42
|
|
ENOSPC = 28
|
|
ENOSR = 98
|
|
ENOSTR = 99
|
|
ENOSYS = 78
|
|
ENOTBLK = 15
|
|
ENOTCONN = 57
|
|
ENOTDIR = 20
|
|
ENOTEMPTY = 66
|
|
ENOTRECOVERABLE = 104
|
|
ENOTSOCK = 38
|
|
ENOTSUP = 45
|
|
ENOTTY = 25
|
|
ENXIO = 6
|
|
EOF = -1
|
|
EOPNOTSUPP = 102
|
|
EOVERFLOW = 84
|
|
EOWNERDEAD = 105
|
|
EPERM = 1
|
|
EPFNOSUPPORT = 46
|
|
EPIPE = 32
|
|
EPROCLIM = 67
|
|
EPROCUNAVAIL = 76
|
|
EPROGMISMATCH = 75
|
|
EPROGUNAVAIL = 74
|
|
EPROTO = 100
|
|
EPROTONOSUPPORT = 43
|
|
EPROTOTYPE = 41
|
|
EPWROFF = 82
|
|
EQFULL = 106
|
|
ERANGE = 34
|
|
EREMOTE = 71
|
|
EROFS = 30
|
|
ERPCMISMATCH = 73
|
|
ESHLIBVERS = 87
|
|
ESHUTDOWN = 58
|
|
ESOCKTNOSUPPORT = 44
|
|
ESPIPE = 29
|
|
ESRCH = 3
|
|
ESTALE = 70
|
|
ETIME = 101
|
|
ETIMEDOUT = 60
|
|
ETOOMANYREFS = 59
|
|
ETXTBSY = 26
|
|
EUSERS = 68
|
|
EWOULDBLOCK = 35
|
|
EXDEV = 18
|
|
EXIT_FAILURE = 1
|
|
EXIT_SUCCESS = 0
|
|
FD_SETSIZE = 1024
|
|
FILENAME_MAX = 1024
|
|
FIXINC_WRAP_STDIO_H_STDIO_STDARG_H = 1
|
|
FOOTPRINT_INTERVAL_RESET = 0x1
|
|
FOPEN_MAX = 20
|
|
FPE_FLTDIV = 1
|
|
FPE_FLTINV = 5
|
|
FPE_FLTOVF = 2
|
|
FPE_FLTRES = 4
|
|
FPE_FLTSUB = 6
|
|
FPE_FLTUND = 3
|
|
FPE_INTDIV = 7
|
|
FPE_INTOVF = 8
|
|
FPE_NOOP = 0
|
|
FTS5_TOKENIZE_AUX = 0x0008
|
|
FTS5_TOKENIZE_DOCUMENT = 0x0004
|
|
FTS5_TOKENIZE_PREFIX = 0x0002
|
|
FTS5_TOKENIZE_QUERY = 0x0001
|
|
FTS5_TOKEN_COLOCATED = 0x0001
|
|
FULLY_WITHIN = 2
|
|
F_LOCK = 1
|
|
F_OK = 0
|
|
F_TEST = 3
|
|
F_TLOCK = 2
|
|
F_ULOCK = 0
|
|
HAVE_USLEEP = 1
|
|
ILL_BADSTK = 8
|
|
ILL_COPROC = 7
|
|
ILL_ILLADR = 5
|
|
ILL_ILLOPC = 1
|
|
ILL_ILLOPN = 4
|
|
ILL_ILLTRP = 2
|
|
ILL_NOOP = 0
|
|
ILL_PRVOPC = 3
|
|
ILL_PRVREG = 6
|
|
INT16_MAX = 32767
|
|
INT16_MIN = -32768
|
|
INT32_MAX = 2147483647
|
|
INT32_MIN = -2147483648
|
|
INT64_MAX = 9223372036854775807
|
|
INT64_MIN = -9223372036854775808
|
|
INT8_MAX = 127
|
|
INT8_MIN = -128
|
|
INTMAX_MAX = 9223372036854775807
|
|
INTMAX_MIN = -9223372036854775808
|
|
INTPTR_MAX = 9223372036854775807
|
|
INTPTR_MIN = -9223372036854775808
|
|
INT_FAST16_MAX = 32767
|
|
INT_FAST16_MIN = -32768
|
|
INT_FAST32_MAX = 2147483647
|
|
INT_FAST32_MIN = -2147483648
|
|
INT_FAST64_MAX = 9223372036854775807
|
|
INT_FAST64_MIN = -9223372036854775808
|
|
INT_FAST8_MAX = 127
|
|
INT_FAST8_MIN = -128
|
|
INT_LEAST16_MAX = 32767
|
|
INT_LEAST16_MIN = -32768
|
|
INT_LEAST32_MAX = 2147483647
|
|
INT_LEAST32_MIN = -2147483648
|
|
INT_LEAST64_MAX = 9223372036854775807
|
|
INT_LEAST64_MIN = -9223372036854775808
|
|
INT_LEAST8_MAX = 127
|
|
INT_LEAST8_MIN = -128
|
|
IOPOL_APPLICATION = 5
|
|
IOPOL_ATIME_UPDATES_DEFAULT = 0
|
|
IOPOL_ATIME_UPDATES_OFF = 1
|
|
IOPOL_DEFAULT = 0
|
|
IOPOL_IMPORTANT = 1
|
|
IOPOL_MATERIALIZE_DATALESS_FILES_DEFAULT = 0
|
|
IOPOL_MATERIALIZE_DATALESS_FILES_OFF = 1
|
|
IOPOL_MATERIALIZE_DATALESS_FILES_ON = 2
|
|
IOPOL_NORMAL = 1
|
|
IOPOL_PASSIVE = 2
|
|
IOPOL_SCOPE_DARWIN_BG = 2
|
|
IOPOL_SCOPE_PROCESS = 0
|
|
IOPOL_SCOPE_THREAD = 1
|
|
IOPOL_STANDARD = 5
|
|
IOPOL_THROTTLE = 3
|
|
IOPOL_TYPE_DISK = 0
|
|
IOPOL_TYPE_VFS_ATIME_UPDATES = 2
|
|
IOPOL_TYPE_VFS_IGNORE_CONTENT_PROTECTION = 6
|
|
IOPOL_TYPE_VFS_IGNORE_PERMISSIONS = 7
|
|
IOPOL_TYPE_VFS_MATERIALIZE_DATALESS_FILES = 3
|
|
IOPOL_TYPE_VFS_SKIP_MTIME_UPDATE = 8
|
|
IOPOL_TYPE_VFS_STATFS_NO_DATA_VOLUME = 4
|
|
IOPOL_TYPE_VFS_TRIGGER_RESOLVE = 5
|
|
IOPOL_UTILITY = 4
|
|
IOPOL_VFS_CONTENT_PROTECTION_DEFAULT = 0
|
|
IOPOL_VFS_CONTENT_PROTECTION_IGNORE = 1
|
|
IOPOL_VFS_IGNORE_PERMISSIONS_OFF = 0
|
|
IOPOL_VFS_IGNORE_PERMISSIONS_ON = 1
|
|
IOPOL_VFS_SKIP_MTIME_UPDATE_OFF = 0
|
|
IOPOL_VFS_SKIP_MTIME_UPDATE_ON = 1
|
|
IOPOL_VFS_STATFS_FORCE_NO_DATA_VOLUME = 1
|
|
IOPOL_VFS_STATFS_NO_DATA_VOLUME_DEFAULT = 0
|
|
IOPOL_VFS_TRIGGER_RESOLVE_DEFAULT = 0
|
|
IOPOL_VFS_TRIGGER_RESOLVE_OFF = 1
|
|
LITTLE_ENDIAN = 1234
|
|
L_INCR = 1
|
|
L_SET = 0
|
|
L_XTND = 2
|
|
L_ctermid = 1024
|
|
L_tmpnam = 1024
|
|
MAC_OS_VERSION_11_0 = 110000
|
|
MAC_OS_X_VERSION_10_0 = 1000
|
|
MAC_OS_X_VERSION_10_1 = 1010
|
|
MAC_OS_X_VERSION_10_10 = 101000
|
|
MAC_OS_X_VERSION_10_10_2 = 101002
|
|
MAC_OS_X_VERSION_10_10_3 = 101003
|
|
MAC_OS_X_VERSION_10_11 = 101100
|
|
MAC_OS_X_VERSION_10_11_2 = 101102
|
|
MAC_OS_X_VERSION_10_11_3 = 101103
|
|
MAC_OS_X_VERSION_10_11_4 = 101104
|
|
MAC_OS_X_VERSION_10_12 = 101200
|
|
MAC_OS_X_VERSION_10_12_1 = 101201
|
|
MAC_OS_X_VERSION_10_12_2 = 101202
|
|
MAC_OS_X_VERSION_10_12_4 = 101204
|
|
MAC_OS_X_VERSION_10_13 = 101300
|
|
MAC_OS_X_VERSION_10_13_1 = 101301
|
|
MAC_OS_X_VERSION_10_13_2 = 101302
|
|
MAC_OS_X_VERSION_10_13_4 = 101304
|
|
MAC_OS_X_VERSION_10_14 = 101400
|
|
MAC_OS_X_VERSION_10_14_1 = 101401
|
|
MAC_OS_X_VERSION_10_14_4 = 101404
|
|
MAC_OS_X_VERSION_10_14_6 = 101406
|
|
MAC_OS_X_VERSION_10_15 = 101500
|
|
MAC_OS_X_VERSION_10_15_1 = 101501
|
|
MAC_OS_X_VERSION_10_16 = 101600
|
|
MAC_OS_X_VERSION_10_2 = 1020
|
|
MAC_OS_X_VERSION_10_3 = 1030
|
|
MAC_OS_X_VERSION_10_4 = 1040
|
|
MAC_OS_X_VERSION_10_5 = 1050
|
|
MAC_OS_X_VERSION_10_6 = 1060
|
|
MAC_OS_X_VERSION_10_7 = 1070
|
|
MAC_OS_X_VERSION_10_8 = 1080
|
|
MAC_OS_X_VERSION_10_9 = 1090
|
|
MINSIGSTKSZ = 32768
|
|
MX_ARG = 2
|
|
NDEBUG = 1
|
|
NOT_WITHIN = 0
|
|
NSIG = 32
|
|
PARTLY_WITHIN = 1
|
|
PDP_ENDIAN = 3412
|
|
POLL_ERR = 4
|
|
POLL_HUP = 6
|
|
POLL_IN = 1
|
|
POLL_MSG = 3
|
|
POLL_OUT = 2
|
|
POLL_PRI = 5
|
|
PRIO_DARWIN_BG = 0x1000
|
|
PRIO_DARWIN_NONUI = 0x1001
|
|
PRIO_DARWIN_PROCESS = 4
|
|
PRIO_DARWIN_THREAD = 3
|
|
PRIO_MAX = 20
|
|
PRIO_MIN = -20
|
|
PRIO_PGRP = 1
|
|
PRIO_PROCESS = 0
|
|
PRIO_USER = 2
|
|
PTRDIFF_MAX = 9223372036854775807
|
|
PTRDIFF_MIN = -9223372036854775808
|
|
P_tmpdir = "/var/tmp/"
|
|
RAND_MAX = 0x7fffffff
|
|
RENAME_EXCL = 0x00000004
|
|
RENAME_SECLUDE = 0x00000001
|
|
RENAME_SWAP = 0x00000002
|
|
RLIMIT_AS = 5
|
|
RLIMIT_CORE = 4
|
|
RLIMIT_CPU = 0
|
|
RLIMIT_CPU_USAGE_MONITOR = 0x2
|
|
RLIMIT_DATA = 2
|
|
RLIMIT_FOOTPRINT_INTERVAL = 0x4
|
|
RLIMIT_FSIZE = 1
|
|
RLIMIT_MEMLOCK = 6
|
|
RLIMIT_NOFILE = 8
|
|
RLIMIT_NPROC = 7
|
|
RLIMIT_RSS = 5
|
|
RLIMIT_STACK = 3
|
|
RLIMIT_THREAD_CPULIMITS = 0x3
|
|
RLIMIT_WAKEUPS_MONITOR = 0x1
|
|
RLIM_NLIMITS = 9
|
|
RSIZE_MAX = 9223372036854775807
|
|
RUSAGE_CHILDREN = -1
|
|
RUSAGE_INFO_CURRENT = 5
|
|
RUSAGE_INFO_V0 = 0
|
|
RUSAGE_INFO_V1 = 1
|
|
RUSAGE_INFO_V2 = 2
|
|
RUSAGE_INFO_V3 = 3
|
|
RUSAGE_INFO_V4 = 4
|
|
RUSAGE_INFO_V5 = 5
|
|
RUSAGE_SELF = 0
|
|
RU_PROC_RUNS_RESLIDE = 0x00000001
|
|
R_OK = 4
|
|
SA_64REGSET = 0x0200
|
|
SA_NOCLDSTOP = 0x0008
|
|
SA_NOCLDWAIT = 0x0020
|
|
SA_NODEFER = 0x0010
|
|
SA_ONSTACK = 0x0001
|
|
SA_RESETHAND = 0x0004
|
|
SA_RESTART = 0x0002
|
|
SA_SIGINFO = 0x0040
|
|
SA_USERSPACE_MASK = 127
|
|
SA_USERTRAMP = 0x0100
|
|
SEEK_CUR = 1
|
|
SEEK_DATA = 4
|
|
SEEK_END = 2
|
|
SEEK_HOLE = 3
|
|
SEEK_SET = 0
|
|
SEGV_ACCERR = 2
|
|
SEGV_MAPERR = 1
|
|
SEGV_NOOP = 0
|
|
SIGABRT = 6
|
|
SIGALRM = 14
|
|
SIGBUS = 10
|
|
SIGCHLD = 20
|
|
SIGCONT = 19
|
|
SIGEMT = 7
|
|
SIGEV_NONE = 0
|
|
SIGEV_SIGNAL = 1
|
|
SIGEV_THREAD = 3
|
|
SIGFPE = 8
|
|
SIGHUP = 1
|
|
SIGILL = 4
|
|
SIGINFO = 29
|
|
SIGINT = 2
|
|
SIGIO = 23
|
|
SIGIOT = 6
|
|
SIGKILL = 9
|
|
SIGPIPE = 13
|
|
SIGPROF = 27
|
|
SIGQUIT = 3
|
|
SIGSEGV = 11
|
|
SIGSTKSZ = 131072
|
|
SIGSTOP = 17
|
|
SIGSYS = 12
|
|
SIGTERM = 15
|
|
SIGTRAP = 5
|
|
SIGTSTP = 18
|
|
SIGTTIN = 21
|
|
SIGTTOU = 22
|
|
SIGURG = 16
|
|
SIGUSR1 = 30
|
|
SIGUSR2 = 31
|
|
SIGVTALRM = 26
|
|
SIGWINCH = 28
|
|
SIGXCPU = 24
|
|
SIGXFSZ = 25
|
|
SIG_ATOMIC_MAX = 2147483647
|
|
SIG_ATOMIC_MIN = -2147483648
|
|
SIG_BLOCK = 1
|
|
SIG_SETMASK = 3
|
|
SIG_UNBLOCK = 2
|
|
SIZE_MAX = 18446744073709551615
|
|
SI_ASYNCIO = 0x10004
|
|
SI_MESGQ = 0x10005
|
|
SI_QUEUE = 0x10002
|
|
SI_TIMER = 0x10003
|
|
SI_USER = 0x10001
|
|
SQLITE3_H = 0
|
|
SQLITE3_TEXT = 3
|
|
SQLITE_ABORT = 4
|
|
SQLITE_ABORT_ROLLBACK = 516
|
|
SQLITE_ACCESS_EXISTS = 0
|
|
SQLITE_ACCESS_READ = 2
|
|
SQLITE_ACCESS_READWRITE = 1
|
|
SQLITE_ALTER_TABLE = 26
|
|
SQLITE_ANALYZE = 28
|
|
SQLITE_ANY = 5
|
|
SQLITE_API = 0
|
|
SQLITE_APICALL = 0
|
|
SQLITE_ATTACH = 24
|
|
SQLITE_AUTH = 23
|
|
SQLITE_AUTH_USER = 279
|
|
SQLITE_BLOB = 4
|
|
SQLITE_BUSY = 5
|
|
SQLITE_BUSY_RECOVERY = 261
|
|
SQLITE_BUSY_SNAPSHOT = 517
|
|
SQLITE_BUSY_TIMEOUT = 773
|
|
SQLITE_CALLBACK = 0
|
|
SQLITE_CANTOPEN = 14
|
|
SQLITE_CANTOPEN_CONVPATH = 1038
|
|
SQLITE_CANTOPEN_DIRTYWAL = 1294
|
|
SQLITE_CANTOPEN_FULLPATH = 782
|
|
SQLITE_CANTOPEN_ISDIR = 526
|
|
SQLITE_CANTOPEN_NOTEMPDIR = 270
|
|
SQLITE_CANTOPEN_SYMLINK = 1550
|
|
SQLITE_CDECL = 0
|
|
SQLITE_CHECKPOINT_FULL = 1
|
|
SQLITE_CHECKPOINT_PASSIVE = 0
|
|
SQLITE_CHECKPOINT_RESTART = 2
|
|
SQLITE_CHECKPOINT_TRUNCATE = 3
|
|
SQLITE_CONFIG_COVERING_INDEX_SCAN = 20
|
|
SQLITE_CONFIG_GETMALLOC = 5
|
|
SQLITE_CONFIG_GETMUTEX = 11
|
|
SQLITE_CONFIG_GETPCACHE = 15
|
|
SQLITE_CONFIG_GETPCACHE2 = 19
|
|
SQLITE_CONFIG_HEAP = 8
|
|
SQLITE_CONFIG_LOG = 16
|
|
SQLITE_CONFIG_LOOKASIDE = 13
|
|
SQLITE_CONFIG_MALLOC = 4
|
|
SQLITE_CONFIG_MEMDB_MAXSIZE = 29
|
|
SQLITE_CONFIG_MEMSTATUS = 9
|
|
SQLITE_CONFIG_MMAP_SIZE = 22
|
|
SQLITE_CONFIG_MULTITHREAD = 2
|
|
SQLITE_CONFIG_MUTEX = 10
|
|
SQLITE_CONFIG_PAGECACHE = 7
|
|
SQLITE_CONFIG_PCACHE = 14
|
|
SQLITE_CONFIG_PCACHE2 = 18
|
|
SQLITE_CONFIG_PCACHE_HDRSZ = 24
|
|
SQLITE_CONFIG_PMASZ = 25
|
|
SQLITE_CONFIG_SCRATCH = 6
|
|
SQLITE_CONFIG_SERIALIZED = 3
|
|
SQLITE_CONFIG_SINGLETHREAD = 1
|
|
SQLITE_CONFIG_SMALL_MALLOC = 27
|
|
SQLITE_CONFIG_SORTERREF_SIZE = 28
|
|
SQLITE_CONFIG_SQLLOG = 21
|
|
SQLITE_CONFIG_STMTJRNL_SPILL = 26
|
|
SQLITE_CONFIG_URI = 17
|
|
SQLITE_CONFIG_WIN32_HEAPSIZE = 23
|
|
SQLITE_CONSTRAINT = 19
|
|
SQLITE_CONSTRAINT_CHECK = 275
|
|
SQLITE_CONSTRAINT_COMMITHOOK = 531
|
|
SQLITE_CONSTRAINT_FOREIGNKEY = 787
|
|
SQLITE_CONSTRAINT_FUNCTION = 1043
|
|
SQLITE_CONSTRAINT_NOTNULL = 1299
|
|
SQLITE_CONSTRAINT_PINNED = 2835
|
|
SQLITE_CONSTRAINT_PRIMARYKEY = 1555
|
|
SQLITE_CONSTRAINT_ROWID = 2579
|
|
SQLITE_CONSTRAINT_TRIGGER = 1811
|
|
SQLITE_CONSTRAINT_UNIQUE = 2067
|
|
SQLITE_CONSTRAINT_VTAB = 2323
|
|
SQLITE_COPY = 0
|
|
SQLITE_CORE = 1
|
|
SQLITE_CORRUPT = 11
|
|
SQLITE_CORRUPT_INDEX = 779
|
|
SQLITE_CORRUPT_SEQUENCE = 523
|
|
SQLITE_CORRUPT_VTAB = 267
|
|
SQLITE_CREATE_INDEX = 1
|
|
SQLITE_CREATE_TABLE = 2
|
|
SQLITE_CREATE_TEMP_INDEX = 3
|
|
SQLITE_CREATE_TEMP_TABLE = 4
|
|
SQLITE_CREATE_TEMP_TRIGGER = 5
|
|
SQLITE_CREATE_TEMP_VIEW = 6
|
|
SQLITE_CREATE_TRIGGER = 7
|
|
SQLITE_CREATE_VIEW = 8
|
|
SQLITE_CREATE_VTABLE = 29
|
|
SQLITE_DBCONFIG_DEFENSIVE = 1010
|
|
SQLITE_DBCONFIG_DQS_DDL = 1014
|
|
SQLITE_DBCONFIG_DQS_DML = 1013
|
|
SQLITE_DBCONFIG_ENABLE_FKEY = 1002
|
|
SQLITE_DBCONFIG_ENABLE_FTS3_TOKENIZER = 1004
|
|
SQLITE_DBCONFIG_ENABLE_LOAD_EXTENSION = 1005
|
|
SQLITE_DBCONFIG_ENABLE_QPSG = 1007
|
|
SQLITE_DBCONFIG_ENABLE_TRIGGER = 1003
|
|
SQLITE_DBCONFIG_ENABLE_VIEW = 1015
|
|
SQLITE_DBCONFIG_LEGACY_ALTER_TABLE = 1012
|
|
SQLITE_DBCONFIG_LEGACY_FILE_FORMAT = 1016
|
|
SQLITE_DBCONFIG_LOOKASIDE = 1001
|
|
SQLITE_DBCONFIG_MAINDBNAME = 1000
|
|
SQLITE_DBCONFIG_MAX = 1017
|
|
SQLITE_DBCONFIG_NO_CKPT_ON_CLOSE = 1006
|
|
SQLITE_DBCONFIG_RESET_DATABASE = 1009
|
|
SQLITE_DBCONFIG_TRIGGER_EQP = 1008
|
|
SQLITE_DBCONFIG_TRUSTED_SCHEMA = 1017
|
|
SQLITE_DBCONFIG_WRITABLE_SCHEMA = 1011
|
|
SQLITE_DBSTATUS_CACHE_HIT = 7
|
|
SQLITE_DBSTATUS_CACHE_MISS = 8
|
|
SQLITE_DBSTATUS_CACHE_SPILL = 12
|
|
SQLITE_DBSTATUS_CACHE_USED = 1
|
|
SQLITE_DBSTATUS_CACHE_USED_SHARED = 11
|
|
SQLITE_DBSTATUS_CACHE_WRITE = 9
|
|
SQLITE_DBSTATUS_DEFERRED_FKS = 10
|
|
SQLITE_DBSTATUS_LOOKASIDE_HIT = 4
|
|
SQLITE_DBSTATUS_LOOKASIDE_MISS_FULL = 6
|
|
SQLITE_DBSTATUS_LOOKASIDE_MISS_SIZE = 5
|
|
SQLITE_DBSTATUS_LOOKASIDE_USED = 0
|
|
SQLITE_DBSTATUS_MAX = 12
|
|
SQLITE_DBSTATUS_SCHEMA_USED = 2
|
|
SQLITE_DBSTATUS_STMT_USED = 3
|
|
SQLITE_DELETE = 9
|
|
SQLITE_DENY = 1
|
|
SQLITE_DEPRECATED = 0
|
|
SQLITE_DESERIALIZE_FREEONCLOSE = 1
|
|
SQLITE_DESERIALIZE_READONLY = 4
|
|
SQLITE_DESERIALIZE_RESIZEABLE = 2
|
|
SQLITE_DETACH = 25
|
|
SQLITE_DETERMINISTIC = 0x000000800
|
|
SQLITE_DIRECTONLY = 0x000080000
|
|
SQLITE_DONE = 101
|
|
SQLITE_DROP_INDEX = 10
|
|
SQLITE_DROP_TABLE = 11
|
|
SQLITE_DROP_TEMP_INDEX = 12
|
|
SQLITE_DROP_TEMP_TABLE = 13
|
|
SQLITE_DROP_TEMP_TRIGGER = 14
|
|
SQLITE_DROP_TEMP_VIEW = 15
|
|
SQLITE_DROP_TRIGGER = 16
|
|
SQLITE_DROP_VIEW = 17
|
|
SQLITE_DROP_VTABLE = 30
|
|
SQLITE_EMPTY = 16
|
|
SQLITE_ENABLE_COLUMN_METADATA = 1
|
|
SQLITE_ENABLE_FTS5 = 1
|
|
SQLITE_ENABLE_GEOPOLY = 1
|
|
SQLITE_ENABLE_JSON1 = 1
|
|
SQLITE_ENABLE_MEMORY_MANAGEMENT = 1
|
|
SQLITE_ENABLE_OFFSET_SQL_FUNC = 1
|
|
SQLITE_ENABLE_PREUPDATE_HOOK = 1
|
|
SQLITE_ENABLE_RBU = 1
|
|
SQLITE_ENABLE_RTREE = 1
|
|
SQLITE_ENABLE_SNAPSHOT = 1
|
|
SQLITE_ENABLE_STAT4 = 1
|
|
SQLITE_ENABLE_UNLOCK_NOTIFY = 1
|
|
SQLITE_ERROR = 1
|
|
SQLITE_ERROR_MISSING_COLLSEQ = 257
|
|
SQLITE_ERROR_RETRY = 513
|
|
SQLITE_ERROR_SNAPSHOT = 769
|
|
SQLITE_EXPERIMENTAL = 0
|
|
SQLITE_FAIL = 3
|
|
SQLITE_FCNTL_BEGIN_ATOMIC_WRITE = 31
|
|
SQLITE_FCNTL_BUSYHANDLER = 15
|
|
SQLITE_FCNTL_CHUNK_SIZE = 6
|
|
SQLITE_FCNTL_CKPT_DONE = 37
|
|
SQLITE_FCNTL_CKPT_START = 39
|
|
SQLITE_FCNTL_COMMIT_ATOMIC_WRITE = 32
|
|
SQLITE_FCNTL_COMMIT_PHASETWO = 22
|
|
SQLITE_FCNTL_DATA_VERSION = 35
|
|
SQLITE_FCNTL_FILE_POINTER = 7
|
|
SQLITE_FCNTL_GET_LOCKPROXYFILE = 2
|
|
SQLITE_FCNTL_HAS_MOVED = 20
|
|
SQLITE_FCNTL_JOURNAL_POINTER = 28
|
|
SQLITE_FCNTL_LAST_ERRNO = 4
|
|
SQLITE_FCNTL_LOCKSTATE = 1
|
|
SQLITE_FCNTL_LOCK_TIMEOUT = 34
|
|
SQLITE_FCNTL_MMAP_SIZE = 18
|
|
SQLITE_FCNTL_OVERWRITE = 11
|
|
SQLITE_FCNTL_PDB = 30
|
|
SQLITE_FCNTL_PERSIST_WAL = 10
|
|
SQLITE_FCNTL_POWERSAFE_OVERWRITE = 13
|
|
SQLITE_FCNTL_PRAGMA = 14
|
|
SQLITE_FCNTL_RBU = 26
|
|
SQLITE_FCNTL_RESERVE_BYTES = 38
|
|
SQLITE_FCNTL_ROLLBACK_ATOMIC_WRITE = 33
|
|
SQLITE_FCNTL_SET_LOCKPROXYFILE = 3
|
|
SQLITE_FCNTL_SIZE_HINT = 5
|
|
SQLITE_FCNTL_SIZE_LIMIT = 36
|
|
SQLITE_FCNTL_SYNC = 21
|
|
SQLITE_FCNTL_SYNC_OMITTED = 8
|
|
SQLITE_FCNTL_TEMPFILENAME = 16
|
|
SQLITE_FCNTL_TRACE = 19
|
|
SQLITE_FCNTL_VFSNAME = 12
|
|
SQLITE_FCNTL_VFS_POINTER = 27
|
|
SQLITE_FCNTL_WAL_BLOCK = 24
|
|
SQLITE_FCNTL_WIN32_AV_RETRY = 9
|
|
SQLITE_FCNTL_WIN32_GET_HANDLE = 29
|
|
SQLITE_FCNTL_WIN32_SET_HANDLE = 23
|
|
SQLITE_FCNTL_ZIPVFS = 25
|
|
SQLITE_FLOAT = 2
|
|
SQLITE_FORMAT = 24
|
|
SQLITE_FULL = 13
|
|
SQLITE_FUNCTION = 31
|
|
SQLITE_GET_LOCKPROXYFILE = 2
|
|
SQLITE_IGNORE = 2
|
|
SQLITE_INDEX_CONSTRAINT_EQ = 2
|
|
SQLITE_INDEX_CONSTRAINT_FUNCTION = 150
|
|
SQLITE_INDEX_CONSTRAINT_GE = 32
|
|
SQLITE_INDEX_CONSTRAINT_GLOB = 66
|
|
SQLITE_INDEX_CONSTRAINT_GT = 4
|
|
SQLITE_INDEX_CONSTRAINT_IS = 72
|
|
SQLITE_INDEX_CONSTRAINT_ISNOT = 69
|
|
SQLITE_INDEX_CONSTRAINT_ISNOTNULL = 70
|
|
SQLITE_INDEX_CONSTRAINT_ISNULL = 71
|
|
SQLITE_INDEX_CONSTRAINT_LE = 8
|
|
SQLITE_INDEX_CONSTRAINT_LIKE = 65
|
|
SQLITE_INDEX_CONSTRAINT_LT = 16
|
|
SQLITE_INDEX_CONSTRAINT_MATCH = 64
|
|
SQLITE_INDEX_CONSTRAINT_NE = 68
|
|
SQLITE_INDEX_CONSTRAINT_REGEXP = 67
|
|
SQLITE_INDEX_SCAN_UNIQUE = 1
|
|
SQLITE_INNOCUOUS = 0x000200000
|
|
SQLITE_INSERT = 18
|
|
SQLITE_INTEGER = 1
|
|
SQLITE_INTERNAL = 2
|
|
SQLITE_INTERRUPT = 9
|
|
SQLITE_IOCAP_ATOMIC = 0x00000001
|
|
SQLITE_IOCAP_ATOMIC16K = 0x00000040
|
|
SQLITE_IOCAP_ATOMIC1K = 0x00000004
|
|
SQLITE_IOCAP_ATOMIC2K = 0x00000008
|
|
SQLITE_IOCAP_ATOMIC32K = 0x00000080
|
|
SQLITE_IOCAP_ATOMIC4K = 0x00000010
|
|
SQLITE_IOCAP_ATOMIC512 = 0x00000002
|
|
SQLITE_IOCAP_ATOMIC64K = 0x00000100
|
|
SQLITE_IOCAP_ATOMIC8K = 0x00000020
|
|
SQLITE_IOCAP_BATCH_ATOMIC = 0x00004000
|
|
SQLITE_IOCAP_IMMUTABLE = 0x00002000
|
|
SQLITE_IOCAP_POWERSAFE_OVERWRITE = 0x00001000
|
|
SQLITE_IOCAP_SAFE_APPEND = 0x00000200
|
|
SQLITE_IOCAP_SEQUENTIAL = 0x00000400
|
|
SQLITE_IOCAP_UNDELETABLE_WHEN_OPEN = 0x00000800
|
|
SQLITE_IOERR = 10
|
|
SQLITE_IOERR_ACCESS = 3338
|
|
SQLITE_IOERR_AUTH = 7178
|
|
SQLITE_IOERR_BEGIN_ATOMIC = 7434
|
|
SQLITE_IOERR_BLOCKED = 2826
|
|
SQLITE_IOERR_CHECKRESERVEDLOCK = 3594
|
|
SQLITE_IOERR_CLOSE = 4106
|
|
SQLITE_IOERR_COMMIT_ATOMIC = 7690
|
|
SQLITE_IOERR_CONVPATH = 6666
|
|
SQLITE_IOERR_CORRUPTFS = 8458
|
|
SQLITE_IOERR_DATA = 8202
|
|
SQLITE_IOERR_DELETE = 2570
|
|
SQLITE_IOERR_DELETE_NOENT = 5898
|
|
SQLITE_IOERR_DIR_CLOSE = 4362
|
|
SQLITE_IOERR_DIR_FSYNC = 1290
|
|
SQLITE_IOERR_FSTAT = 1802
|
|
SQLITE_IOERR_FSYNC = 1034
|
|
SQLITE_IOERR_GETTEMPPATH = 6410
|
|
SQLITE_IOERR_LOCK = 3850
|
|
SQLITE_IOERR_MMAP = 6154
|
|
SQLITE_IOERR_NOMEM = 3082
|
|
SQLITE_IOERR_RDLOCK = 2314
|
|
SQLITE_IOERR_READ = 266
|
|
SQLITE_IOERR_ROLLBACK_ATOMIC = 7946
|
|
SQLITE_IOERR_SEEK = 5642
|
|
SQLITE_IOERR_SHMLOCK = 5130
|
|
SQLITE_IOERR_SHMMAP = 5386
|
|
SQLITE_IOERR_SHMOPEN = 4618
|
|
SQLITE_IOERR_SHMSIZE = 4874
|
|
SQLITE_IOERR_SHORT_READ = 522
|
|
SQLITE_IOERR_TRUNCATE = 1546
|
|
SQLITE_IOERR_UNLOCK = 2058
|
|
SQLITE_IOERR_VNODE = 6922
|
|
SQLITE_IOERR_WRITE = 778
|
|
SQLITE_LAST_ERRNO = 4
|
|
SQLITE_LIKE_DOESNT_MATCH_BLOBS = 1
|
|
SQLITE_LIMIT_ATTACHED = 7
|
|
SQLITE_LIMIT_COLUMN = 2
|
|
SQLITE_LIMIT_COMPOUND_SELECT = 4
|
|
SQLITE_LIMIT_EXPR_DEPTH = 3
|
|
SQLITE_LIMIT_FUNCTION_ARG = 6
|
|
SQLITE_LIMIT_LENGTH = 0
|
|
SQLITE_LIMIT_LIKE_PATTERN_LENGTH = 8
|
|
SQLITE_LIMIT_SQL_LENGTH = 1
|
|
SQLITE_LIMIT_TRIGGER_DEPTH = 10
|
|
SQLITE_LIMIT_VARIABLE_NUMBER = 9
|
|
SQLITE_LIMIT_VDBE_OP = 5
|
|
SQLITE_LIMIT_WORKER_THREADS = 11
|
|
SQLITE_LOCKED = 6
|
|
SQLITE_LOCKED_SHAREDCACHE = 262
|
|
SQLITE_LOCKED_VTAB = 518
|
|
SQLITE_LOCK_EXCLUSIVE = 4
|
|
SQLITE_LOCK_NONE = 0
|
|
SQLITE_LOCK_PENDING = 3
|
|
SQLITE_LOCK_RESERVED = 2
|
|
SQLITE_LOCK_SHARED = 1
|
|
SQLITE_MISMATCH = 20
|
|
SQLITE_MISUSE = 21
|
|
SQLITE_MUTEX_APPDEF = 1
|
|
SQLITE_MUTEX_FAST = 0
|
|
SQLITE_MUTEX_NOOP = 1
|
|
SQLITE_MUTEX_RECURSIVE = 1
|
|
SQLITE_MUTEX_STATIC_APP1 = 8
|
|
SQLITE_MUTEX_STATIC_APP2 = 9
|
|
SQLITE_MUTEX_STATIC_APP3 = 10
|
|
SQLITE_MUTEX_STATIC_LRU = 6
|
|
SQLITE_MUTEX_STATIC_LRU2 = 7
|
|
SQLITE_MUTEX_STATIC_MAIN = 2
|
|
SQLITE_MUTEX_STATIC_MASTER = 2
|
|
SQLITE_MUTEX_STATIC_MEM = 3
|
|
SQLITE_MUTEX_STATIC_MEM2 = 4
|
|
SQLITE_MUTEX_STATIC_OPEN = 4
|
|
SQLITE_MUTEX_STATIC_PMEM = 7
|
|
SQLITE_MUTEX_STATIC_PRNG = 5
|
|
SQLITE_MUTEX_STATIC_VFS1 = 11
|
|
SQLITE_MUTEX_STATIC_VFS2 = 12
|
|
SQLITE_MUTEX_STATIC_VFS3 = 13
|
|
SQLITE_NOLFS = 22
|
|
SQLITE_NOMEM = 7
|
|
SQLITE_NOTADB = 26
|
|
SQLITE_NOTFOUND = 12
|
|
SQLITE_NOTICE = 27
|
|
SQLITE_NOTICE_RECOVER_ROLLBACK = 539
|
|
SQLITE_NOTICE_RECOVER_WAL = 283
|
|
SQLITE_NULL = 5
|
|
SQLITE_OK = 0
|
|
SQLITE_OK_LOAD_PERMANENTLY = 256
|
|
SQLITE_OK_SYMLINK = 512
|
|
SQLITE_OPEN_AUTOPROXY = 0x00000020
|
|
SQLITE_OPEN_CREATE = 0x00000004
|
|
SQLITE_OPEN_DELETEONCLOSE = 0x00000008
|
|
SQLITE_OPEN_EXCLUSIVE = 0x00000010
|
|
SQLITE_OPEN_FULLMUTEX = 0x00010000
|
|
SQLITE_OPEN_MAIN_DB = 0x00000100
|
|
SQLITE_OPEN_MAIN_JOURNAL = 0x00000800
|
|
SQLITE_OPEN_MASTER_JOURNAL = 0x00004000
|
|
SQLITE_OPEN_MEMORY = 0x00000080
|
|
SQLITE_OPEN_NOFOLLOW = 0x01000000
|
|
SQLITE_OPEN_NOMUTEX = 0x00008000
|
|
SQLITE_OPEN_PRIVATECACHE = 0x00040000
|
|
SQLITE_OPEN_READONLY = 0x00000001
|
|
SQLITE_OPEN_READWRITE = 0x00000002
|
|
SQLITE_OPEN_SHAREDCACHE = 0x00020000
|
|
SQLITE_OPEN_SUBJOURNAL = 0x00002000
|
|
SQLITE_OPEN_SUPER_JOURNAL = 0x00004000
|
|
SQLITE_OPEN_TEMP_DB = 0x00000200
|
|
SQLITE_OPEN_TEMP_JOURNAL = 0x00001000
|
|
SQLITE_OPEN_TRANSIENT_DB = 0x00000400
|
|
SQLITE_OPEN_URI = 0x00000040
|
|
SQLITE_OPEN_WAL = 0x00080000
|
|
SQLITE_OS_UNIX = 1
|
|
SQLITE_PERM = 3
|
|
SQLITE_PRAGMA = 19
|
|
SQLITE_PREPARE_NORMALIZE = 0x02
|
|
SQLITE_PREPARE_NO_VTAB = 0x04
|
|
SQLITE_PREPARE_PERSISTENT = 0x01
|
|
SQLITE_PROTOCOL = 15
|
|
SQLITE_RANGE = 25
|
|
SQLITE_READ = 20
|
|
SQLITE_READONLY = 8
|
|
SQLITE_READONLY_CANTINIT = 1288
|
|
SQLITE_READONLY_CANTLOCK = 520
|
|
SQLITE_READONLY_DBMOVED = 1032
|
|
SQLITE_READONLY_DIRECTORY = 1544
|
|
SQLITE_READONLY_RECOVERY = 264
|
|
SQLITE_READONLY_ROLLBACK = 776
|
|
SQLITE_RECURSIVE = 33
|
|
SQLITE_REINDEX = 27
|
|
SQLITE_REPLACE = 5
|
|
SQLITE_ROLLBACK = 1
|
|
SQLITE_ROW = 100
|
|
SQLITE_SAVEPOINT = 32
|
|
SQLITE_SCANSTAT_EST = 2
|
|
SQLITE_SCANSTAT_EXPLAIN = 4
|
|
SQLITE_SCANSTAT_NAME = 3
|
|
SQLITE_SCANSTAT_NLOOP = 0
|
|
SQLITE_SCANSTAT_NVISIT = 1
|
|
SQLITE_SCANSTAT_SELECTID = 5
|
|
SQLITE_SCHEMA = 17
|
|
SQLITE_SELECT = 21
|
|
SQLITE_SERIALIZE_NOCOPY = 0x001
|
|
SQLITE_SET_LOCKPROXYFILE = 3
|
|
SQLITE_SHM_EXCLUSIVE = 8
|
|
SQLITE_SHM_LOCK = 2
|
|
SQLITE_SHM_NLOCK = 8
|
|
SQLITE_SHM_SHARED = 4
|
|
SQLITE_SHM_UNLOCK = 1
|
|
SQLITE_SOUNDEX = 1
|
|
SQLITE_SOURCE_ID = "2021-04-19 18:32:05 1b256d97b553a9611efca188a3d995a2fff712759044ba480f9a0c9e98fae886"
|
|
SQLITE_STATUS_MALLOC_COUNT = 9
|
|
SQLITE_STATUS_MALLOC_SIZE = 5
|
|
SQLITE_STATUS_MEMORY_USED = 0
|
|
SQLITE_STATUS_PAGECACHE_OVERFLOW = 2
|
|
SQLITE_STATUS_PAGECACHE_SIZE = 7
|
|
SQLITE_STATUS_PAGECACHE_USED = 1
|
|
SQLITE_STATUS_PARSER_STACK = 6
|
|
SQLITE_STATUS_SCRATCH_OVERFLOW = 4
|
|
SQLITE_STATUS_SCRATCH_SIZE = 8
|
|
SQLITE_STATUS_SCRATCH_USED = 3
|
|
SQLITE_STDCALL = 0
|
|
SQLITE_STMTSTATUS_AUTOINDEX = 3
|
|
SQLITE_STMTSTATUS_FULLSCAN_STEP = 1
|
|
SQLITE_STMTSTATUS_MEMUSED = 99
|
|
SQLITE_STMTSTATUS_REPREPARE = 5
|
|
SQLITE_STMTSTATUS_RUN = 6
|
|
SQLITE_STMTSTATUS_SORT = 2
|
|
SQLITE_STMTSTATUS_VM_STEP = 4
|
|
SQLITE_SUBTYPE = 0x000100000
|
|
SQLITE_SYNC_DATAONLY = 0x00010
|
|
SQLITE_SYNC_FULL = 0x00003
|
|
SQLITE_SYNC_NORMAL = 0x00002
|
|
SQLITE_SYSAPI = 0
|
|
SQLITE_TESTCTRL_ALWAYS = 13
|
|
SQLITE_TESTCTRL_ASSERT = 12
|
|
SQLITE_TESTCTRL_BENIGN_MALLOC_HOOKS = 10
|
|
SQLITE_TESTCTRL_BITVEC_TEST = 8
|
|
SQLITE_TESTCTRL_BYTEORDER = 22
|
|
SQLITE_TESTCTRL_EXPLAIN_STMT = 19
|
|
SQLITE_TESTCTRL_EXTRA_SCHEMA_CHECKS = 29
|
|
SQLITE_TESTCTRL_FAULT_INSTALL = 9
|
|
SQLITE_TESTCTRL_FIRST = 5
|
|
SQLITE_TESTCTRL_IMPOSTER = 25
|
|
SQLITE_TESTCTRL_INTERNAL_FUNCTIONS = 17
|
|
SQLITE_TESTCTRL_ISINIT = 23
|
|
SQLITE_TESTCTRL_ISKEYWORD = 16
|
|
SQLITE_TESTCTRL_LAST = 31
|
|
SQLITE_TESTCTRL_LOCALTIME_FAULT = 18
|
|
SQLITE_TESTCTRL_NEVER_CORRUPT = 20
|
|
SQLITE_TESTCTRL_ONCE_RESET_THRESHOLD = 19
|
|
SQLITE_TESTCTRL_OPTIMIZATIONS = 15
|
|
SQLITE_TESTCTRL_PARSER_COVERAGE = 26
|
|
SQLITE_TESTCTRL_PENDING_BYTE = 11
|
|
SQLITE_TESTCTRL_PRNG_RESET = 7
|
|
SQLITE_TESTCTRL_PRNG_RESTORE = 6
|
|
SQLITE_TESTCTRL_PRNG_SAVE = 5
|
|
SQLITE_TESTCTRL_PRNG_SEED = 28
|
|
SQLITE_TESTCTRL_RESERVE = 14
|
|
SQLITE_TESTCTRL_RESULT_INTREAL = 27
|
|
SQLITE_TESTCTRL_SCRATCHMALLOC = 17
|
|
SQLITE_TESTCTRL_SEEK_COUNT = 30
|
|
SQLITE_TESTCTRL_SORTER_MMAP = 24
|
|
SQLITE_TESTCTRL_TRACEFLAGS = 31
|
|
SQLITE_TESTCTRL_VDBE_COVERAGE = 21
|
|
SQLITE_TEXT = 3
|
|
SQLITE_THREADSAFE = 1
|
|
SQLITE_TOOBIG = 18
|
|
SQLITE_TRACE_CLOSE = 0x08
|
|
SQLITE_TRACE_PROFILE = 0x02
|
|
SQLITE_TRACE_ROW = 0x04
|
|
SQLITE_TRACE_STMT = 0x01
|
|
SQLITE_TRANSACTION = 22
|
|
SQLITE_TXN_NONE = 0
|
|
SQLITE_TXN_READ = 1
|
|
SQLITE_TXN_WRITE = 2
|
|
SQLITE_UPDATE = 23
|
|
SQLITE_UTF16 = 4
|
|
SQLITE_UTF16BE = 3
|
|
SQLITE_UTF16LE = 2
|
|
SQLITE_UTF16_ALIGNED = 8
|
|
SQLITE_UTF8 = 1
|
|
SQLITE_VERSION = "3.35.5"
|
|
SQLITE_VERSION_NUMBER = 3035005
|
|
SQLITE_VTAB_CONSTRAINT_SUPPORT = 1
|
|
SQLITE_VTAB_DIRECTONLY = 3
|
|
SQLITE_VTAB_INNOCUOUS = 2
|
|
SQLITE_WARNING = 28
|
|
SQLITE_WARNING_AUTOINDEX = 284
|
|
SQLITE_WIN32_DATA_DIRECTORY_TYPE = 1
|
|
SQLITE_WIN32_TEMP_DIRECTORY_TYPE = 2
|
|
SQLITE_WITHOUT_ZONEMALLOC = 1
|
|
SS_DISABLE = 0x0004
|
|
SS_ONSTACK = 0x0001
|
|
STDERR_FILENO = 2
|
|
STDIN_FILENO = 0
|
|
STDOUT_FILENO = 1
|
|
SV_INTERRUPT = 2
|
|
SV_NOCLDSTOP = 8
|
|
SV_NODEFER = 16
|
|
SV_ONSTACK = 1
|
|
SV_RESETHAND = 4
|
|
SV_SIGINFO = 64
|
|
SYNC_VOLUME_FULLSYNC = 0x01
|
|
SYNC_VOLUME_WAIT = 0x02
|
|
TMP_MAX = 308915776
|
|
TRAP_BRKPT = 1
|
|
TRAP_TRACE = 2
|
|
UINT16_MAX = 65535
|
|
UINT32_MAX = 4294967295
|
|
UINT64_MAX = 18446744073709551615
|
|
UINT8_MAX = 255
|
|
UINTMAX_MAX = 18446744073709551615
|
|
UINTPTR_MAX = 18446744073709551615
|
|
UINT_FAST16_MAX = 65535
|
|
UINT_FAST32_MAX = 4294967295
|
|
UINT_FAST64_MAX = 18446744073709551615
|
|
UINT_FAST8_MAX = 255
|
|
UINT_LEAST16_MAX = 65535
|
|
UINT_LEAST32_MAX = 4294967295
|
|
UINT_LEAST64_MAX = 18446744073709551615
|
|
UINT_LEAST8_MAX = 255
|
|
WAIT_ANY = -1
|
|
WAIT_MYPGRP = 0
|
|
WAKEMON_DISABLE = 0x02
|
|
WAKEMON_ENABLE = 0x01
|
|
WAKEMON_GET_PARAMS = 0x04
|
|
WAKEMON_MAKE_FATAL = 0x10
|
|
WAKEMON_SET_DEFAULTS = 0x08
|
|
WCHAR_MAX = 2147483647
|
|
WCHAR_MIN = -2147483648
|
|
WCONTINUED = 0x00000010
|
|
WCOREFLAG = 0200
|
|
WEXITED = 0x00000004
|
|
WINT_MAX = 2147483647
|
|
WINT_MIN = -2147483648
|
|
WNOHANG = 0x00000001
|
|
WNOWAIT = 0x00000020
|
|
WSTOPPED = 0x00000008
|
|
WUNTRACED = 0x00000002
|
|
W_OK = 2
|
|
X_OK = 1
|
|
X_ACCESS_EXTENDED_MASK = 4193792
|
|
X_ALLOCA_H_ = 0
|
|
X_ANSI_STDARG_H_ = 0
|
|
X_APPEND_OK = 8192
|
|
X_ARM_ARCH_H = 0
|
|
X_ARM_SIGNAL_ = 1
|
|
X_ARM__ENDIAN_H_ = 0
|
|
X_ASSERT_H_ = 0
|
|
X_BSD_ARM__TYPES_H_ = 0
|
|
X_BSD_MACHINE_ENDIAN_H_ = 0
|
|
X_BSD_MACHINE_SIGNAL_H_ = 0
|
|
X_BSD_MACHINE_TYPES_H_ = 0
|
|
X_BSD_MACHINE__TYPES_H_ = 0
|
|
X_CACHED_RUNES = 256
|
|
X_CDEFS_H_ = 0
|
|
X_CHOWN_OK = 2097152
|
|
X_CRMASK = -256
|
|
X_CS_DARWIN_USER_CACHE_DIR = 65538
|
|
X_CS_DARWIN_USER_DIR = 65536
|
|
X_CS_DARWIN_USER_TEMP_DIR = 65537
|
|
X_CS_PATH = 1
|
|
X_CS_POSIX_V6_ILP32_OFF32_CFLAGS = 2
|
|
X_CS_POSIX_V6_ILP32_OFF32_LDFLAGS = 3
|
|
X_CS_POSIX_V6_ILP32_OFF32_LIBS = 4
|
|
X_CS_POSIX_V6_ILP32_OFFBIG_CFLAGS = 5
|
|
X_CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS = 6
|
|
X_CS_POSIX_V6_ILP32_OFFBIG_LIBS = 7
|
|
X_CS_POSIX_V6_LP64_OFF64_CFLAGS = 8
|
|
X_CS_POSIX_V6_LP64_OFF64_LDFLAGS = 9
|
|
X_CS_POSIX_V6_LP64_OFF64_LIBS = 10
|
|
X_CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS = 11
|
|
X_CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS = 12
|
|
X_CS_POSIX_V6_LPBIG_OFFBIG_LIBS = 13
|
|
X_CS_POSIX_V6_WIDTH_RESTRICTED_ENVS = 14
|
|
X_CS_XBS5_ILP32_OFF32_CFLAGS = 20
|
|
X_CS_XBS5_ILP32_OFF32_LDFLAGS = 21
|
|
X_CS_XBS5_ILP32_OFF32_LIBS = 22
|
|
X_CS_XBS5_ILP32_OFF32_LINTFLAGS = 23
|
|
X_CS_XBS5_ILP32_OFFBIG_CFLAGS = 24
|
|
X_CS_XBS5_ILP32_OFFBIG_LDFLAGS = 25
|
|
X_CS_XBS5_ILP32_OFFBIG_LIBS = 26
|
|
X_CS_XBS5_ILP32_OFFBIG_LINTFLAGS = 27
|
|
X_CS_XBS5_LP64_OFF64_CFLAGS = 28
|
|
X_CS_XBS5_LP64_OFF64_LDFLAGS = 29
|
|
X_CS_XBS5_LP64_OFF64_LIBS = 30
|
|
X_CS_XBS5_LP64_OFF64_LINTFLAGS = 31
|
|
X_CS_XBS5_LPBIG_OFFBIG_CFLAGS = 32
|
|
X_CS_XBS5_LPBIG_OFFBIG_LDFLAGS = 33
|
|
X_CS_XBS5_LPBIG_OFFBIG_LIBS = 34
|
|
X_CS_XBS5_LPBIG_OFFBIG_LINTFLAGS = 35
|
|
X_CTERMID_H_ = 0
|
|
X_CTYPE_A = 0x00000100
|
|
X_CTYPE_B = 0x00020000
|
|
X_CTYPE_C = 0x00000200
|
|
X_CTYPE_D = 0x00000400
|
|
X_CTYPE_G = 0x00000800
|
|
X_CTYPE_H_ = 0
|
|
X_CTYPE_I = 0x00080000
|
|
X_CTYPE_L = 0x00001000
|
|
X_CTYPE_P = 0x00002000
|
|
X_CTYPE_Q = 0x00200000
|
|
X_CTYPE_R = 0x00040000
|
|
X_CTYPE_S = 0x00004000
|
|
X_CTYPE_SW0 = 0x20000000
|
|
X_CTYPE_SW1 = 0x40000000
|
|
X_CTYPE_SW2 = 0x80000000
|
|
X_CTYPE_SW3 = 0xc0000000
|
|
X_CTYPE_SWM = 0xe0000000
|
|
X_CTYPE_SWS = 30
|
|
X_CTYPE_T = 0x00100000
|
|
X_CTYPE_U = 0x00008000
|
|
X_CTYPE_X = 0x00010000
|
|
X_CT_RUNE_T = 0
|
|
X_DARWIN_FEATURE_64_BIT_INODE = 1
|
|
X_DARWIN_FEATURE_ONLY_64_BIT_INODE = 1
|
|
X_DARWIN_FEATURE_ONLY_UNIX_CONFORMANCE = 1
|
|
X_DARWIN_FEATURE_ONLY_VERS_1050 = 1
|
|
X_DARWIN_FEATURE_UNIX_CONFORMANCE = 3
|
|
X_DELETE_OK = 4096
|
|
X_DEV_T = 0
|
|
X_ERRNO_T = 0
|
|
X_EXECUTE_OK = 2048
|
|
X_FD_SET = 0
|
|
X_FILE_OFFSET_BITS = 64
|
|
X_FORTIFY_SOURCE = 2
|
|
X_FSTDIO = 0
|
|
X_FTS5_H = 0
|
|
X_GCC_WRAP_STDINT_H = 0
|
|
X_GID_T = 0
|
|
X_ID_T = 0
|
|
X_INT16_T = 0
|
|
X_INT32_T = 0
|
|
X_INT64_T = 0
|
|
X_INT8_T = 0
|
|
X_INTMAX_T = 0
|
|
X_INTPTR_T = 0
|
|
X_IOFBF = 0
|
|
X_IOLBF = 1
|
|
X_IONBF = 2
|
|
X_LP64 = 1
|
|
X_MACHTYPES_H_ = 0
|
|
X_MACH_ARM__STRUCTS_H_ = 0
|
|
X_MACH_MACHINE__STRUCTS_H_ = 0
|
|
X_MALLOC_UNDERSCORE_MALLOC_H_ = 0
|
|
X_MCONTEXT_T = 0
|
|
X_MODE_T = 0
|
|
X_Nonnull = 0
|
|
X_Null_unspecified = 0
|
|
X_Nullable = 0
|
|
X_OFF_T = 0
|
|
X_OS_OSBYTEORDERARM_H = 0
|
|
X_OS__OSBYTEORDER_H = 0
|
|
X_PC_2_SYMLINKS = 15
|
|
X_PC_ALLOC_SIZE_MIN = 16
|
|
X_PC_ASYNC_IO = 17
|
|
X_PC_AUTH_OPAQUE_NP = 14
|
|
X_PC_CASE_PRESERVING = 12
|
|
X_PC_CASE_SENSITIVE = 11
|
|
X_PC_CHOWN_RESTRICTED = 7
|
|
X_PC_EXTENDED_SECURITY_NP = 13
|
|
X_PC_FILESIZEBITS = 18
|
|
X_PC_LINK_MAX = 1
|
|
X_PC_MAX_CANON = 2
|
|
X_PC_MAX_INPUT = 3
|
|
X_PC_MIN_HOLE_SIZE = 27
|
|
X_PC_NAME_CHARS_MAX = 10
|
|
X_PC_NAME_MAX = 4
|
|
X_PC_NO_TRUNC = 8
|
|
X_PC_PATH_MAX = 5
|
|
X_PC_PIPE_BUF = 6
|
|
X_PC_PRIO_IO = 19
|
|
X_PC_REC_INCR_XFER_SIZE = 20
|
|
X_PC_REC_MAX_XFER_SIZE = 21
|
|
X_PC_REC_MIN_XFER_SIZE = 22
|
|
X_PC_REC_XFER_ALIGN = 23
|
|
X_PC_SYMLINK_MAX = 24
|
|
X_PC_SYNC_IO = 25
|
|
X_PC_VDISABLE = 9
|
|
X_PC_XATTR_SIZE_BITS = 26
|
|
X_PID_T = 0
|
|
X_POSIX2_CHAR_TERM = 200112
|
|
X_POSIX2_C_BIND = 200112
|
|
X_POSIX2_C_DEV = 200112
|
|
X_POSIX2_FORT_DEV = -1
|
|
X_POSIX2_FORT_RUN = 200112
|
|
X_POSIX2_LOCALEDEF = 200112
|
|
X_POSIX2_PBS = -1
|
|
X_POSIX2_PBS_ACCOUNTING = -1
|
|
X_POSIX2_PBS_CHECKPOINT = -1
|
|
X_POSIX2_PBS_LOCATE = -1
|
|
X_POSIX2_PBS_MESSAGE = -1
|
|
X_POSIX2_PBS_TRACK = -1
|
|
X_POSIX2_SW_DEV = 200112
|
|
X_POSIX2_UPE = 200112
|
|
X_POSIX2_VERSION = 200112
|
|
X_POSIX_ADVISORY_INFO = -1
|
|
X_POSIX_ASYNCHRONOUS_IO = -1
|
|
X_POSIX_BARRIERS = -1
|
|
X_POSIX_CHOWN_RESTRICTED = 200112
|
|
X_POSIX_CLOCK_SELECTION = -1
|
|
X_POSIX_CPUTIME = -1
|
|
X_POSIX_FSYNC = 200112
|
|
X_POSIX_IPV6 = 200112
|
|
X_POSIX_JOB_CONTROL = 200112
|
|
X_POSIX_MAPPED_FILES = 200112
|
|
X_POSIX_MEMLOCK = -1
|
|
X_POSIX_MEMLOCK_RANGE = -1
|
|
X_POSIX_MEMORY_PROTECTION = 200112
|
|
X_POSIX_MESSAGE_PASSING = -1
|
|
X_POSIX_MONOTONIC_CLOCK = -1
|
|
X_POSIX_NO_TRUNC = 200112
|
|
X_POSIX_PRIORITIZED_IO = -1
|
|
X_POSIX_PRIORITY_SCHEDULING = -1
|
|
X_POSIX_RAW_SOCKETS = -1
|
|
X_POSIX_READER_WRITER_LOCKS = 200112
|
|
X_POSIX_REALTIME_SIGNALS = -1
|
|
X_POSIX_REGEXP = 200112
|
|
X_POSIX_SAVED_IDS = 200112
|
|
X_POSIX_SEMAPHORES = -1
|
|
X_POSIX_SHARED_MEMORY_OBJECTS = -1
|
|
X_POSIX_SHELL = 200112
|
|
X_POSIX_SPAWN = -1
|
|
X_POSIX_SPIN_LOCKS = -1
|
|
X_POSIX_SPORADIC_SERVER = -1
|
|
X_POSIX_SYNCHRONIZED_IO = -1
|
|
X_POSIX_THREADS = 200112
|
|
X_POSIX_THREAD_ATTR_STACKADDR = 200112
|
|
X_POSIX_THREAD_ATTR_STACKSIZE = 200112
|
|
X_POSIX_THREAD_CPUTIME = -1
|
|
X_POSIX_THREAD_KEYS_MAX = 128
|
|
X_POSIX_THREAD_PRIORITY_SCHEDULING = -1
|
|
X_POSIX_THREAD_PRIO_INHERIT = -1
|
|
X_POSIX_THREAD_PRIO_PROTECT = -1
|
|
X_POSIX_THREAD_PROCESS_SHARED = 200112
|
|
X_POSIX_THREAD_SAFE_FUNCTIONS = 200112
|
|
X_POSIX_THREAD_SPORADIC_SERVER = -1
|
|
X_POSIX_TIMEOUTS = -1
|
|
X_POSIX_TIMERS = -1
|
|
X_POSIX_TRACE = -1
|
|
X_POSIX_TRACE_EVENT_FILTER = -1
|
|
X_POSIX_TRACE_INHERIT = -1
|
|
X_POSIX_TRACE_LOG = -1
|
|
X_POSIX_TYPED_MEMORY_OBJECTS = -1
|
|
X_POSIX_V6_ILP32_OFF32 = -1
|
|
X_POSIX_V6_ILP32_OFFBIG = -1
|
|
X_POSIX_V6_LP64_OFF64 = 1
|
|
X_POSIX_V6_LPBIG_OFFBIG = 1
|
|
X_POSIX_V7_ILP32_OFF32 = -1
|
|
X_POSIX_V7_ILP32_OFFBIG = -1
|
|
X_POSIX_V7_LP64_OFF64 = 1
|
|
X_POSIX_V7_LPBIG_OFFBIG = 1
|
|
X_POSIX_VERSION = 200112
|
|
X_PTHREAD_ATTR_T = 0
|
|
X_QUAD_HIGHWORD = 1
|
|
X_QUAD_LOWWORD = 0
|
|
X_RATTR_OK = 32768
|
|
X_READ_OK = 512
|
|
X_REXT_OK = 131072
|
|
X_RLIMIT_POSIX_FLAG = 0x1000
|
|
X_RMFILE_OK = 16384
|
|
X_RPERM_OK = 524288
|
|
X_RSIZE_T = 0
|
|
X_RUNETYPE_H_ = 0
|
|
X_RUNE_MAGIC_A = "RuneMagA"
|
|
X_RUNE_T = 0
|
|
X_SC_2_CHAR_TERM = 20
|
|
X_SC_2_C_BIND = 18
|
|
X_SC_2_C_DEV = 19
|
|
X_SC_2_FORT_DEV = 21
|
|
X_SC_2_FORT_RUN = 22
|
|
X_SC_2_LOCALEDEF = 23
|
|
X_SC_2_PBS = 59
|
|
X_SC_2_PBS_ACCOUNTING = 60
|
|
X_SC_2_PBS_CHECKPOINT = 61
|
|
X_SC_2_PBS_LOCATE = 62
|
|
X_SC_2_PBS_MESSAGE = 63
|
|
X_SC_2_PBS_TRACK = 64
|
|
X_SC_2_SW_DEV = 24
|
|
X_SC_2_UPE = 25
|
|
X_SC_2_VERSION = 17
|
|
X_SC_ADVISORY_INFO = 65
|
|
X_SC_AIO_LISTIO_MAX = 42
|
|
X_SC_AIO_MAX = 43
|
|
X_SC_AIO_PRIO_DELTA_MAX = 44
|
|
X_SC_ARG_MAX = 1
|
|
X_SC_ASYNCHRONOUS_IO = 28
|
|
X_SC_ATEXIT_MAX = 107
|
|
X_SC_BARRIERS = 66
|
|
X_SC_BC_BASE_MAX = 9
|
|
X_SC_BC_DIM_MAX = 10
|
|
X_SC_BC_SCALE_MAX = 11
|
|
X_SC_BC_STRING_MAX = 12
|
|
X_SC_CHILD_MAX = 2
|
|
X_SC_CLK_TCK = 3
|
|
X_SC_CLOCK_SELECTION = 67
|
|
X_SC_COLL_WEIGHTS_MAX = 13
|
|
X_SC_CPUTIME = 68
|
|
X_SC_DELAYTIMER_MAX = 45
|
|
X_SC_EXPR_NEST_MAX = 14
|
|
X_SC_FILE_LOCKING = 69
|
|
X_SC_FSYNC = 38
|
|
X_SC_GETGR_R_SIZE_MAX = 70
|
|
X_SC_GETPW_R_SIZE_MAX = 71
|
|
X_SC_HOST_NAME_MAX = 72
|
|
X_SC_IOV_MAX = 56
|
|
X_SC_IPV6 = 118
|
|
X_SC_JOB_CONTROL = 6
|
|
X_SC_LINE_MAX = 15
|
|
X_SC_LOGIN_NAME_MAX = 73
|
|
X_SC_MAPPED_FILES = 47
|
|
X_SC_MEMLOCK = 30
|
|
X_SC_MEMLOCK_RANGE = 31
|
|
X_SC_MEMORY_PROTECTION = 32
|
|
X_SC_MESSAGE_PASSING = 33
|
|
X_SC_MONOTONIC_CLOCK = 74
|
|
X_SC_MQ_OPEN_MAX = 46
|
|
X_SC_MQ_PRIO_MAX = 75
|
|
X_SC_NGROUPS_MAX = 4
|
|
X_SC_NPROCESSORS_CONF = 57
|
|
X_SC_NPROCESSORS_ONLN = 58
|
|
X_SC_OPEN_MAX = 5
|
|
X_SC_PAGESIZE = 29
|
|
X_SC_PAGE_SIZE = 29
|
|
X_SC_PASS_MAX = 131
|
|
X_SC_PHYS_PAGES = 200
|
|
X_SC_PRIORITIZED_IO = 34
|
|
X_SC_PRIORITY_SCHEDULING = 35
|
|
X_SC_RAW_SOCKETS = 119
|
|
X_SC_READER_WRITER_LOCKS = 76
|
|
X_SC_REALTIME_SIGNALS = 36
|
|
X_SC_REGEXP = 77
|
|
X_SC_RE_DUP_MAX = 16
|
|
X_SC_RTSIG_MAX = 48
|
|
X_SC_SAVED_IDS = 7
|
|
X_SC_SEMAPHORES = 37
|
|
X_SC_SEM_NSEMS_MAX = 49
|
|
X_SC_SEM_VALUE_MAX = 50
|
|
X_SC_SHARED_MEMORY_OBJECTS = 39
|
|
X_SC_SHELL = 78
|
|
X_SC_SIGQUEUE_MAX = 51
|
|
X_SC_SPAWN = 79
|
|
X_SC_SPIN_LOCKS = 80
|
|
X_SC_SPORADIC_SERVER = 81
|
|
X_SC_SS_REPL_MAX = 126
|
|
X_SC_STREAM_MAX = 26
|
|
X_SC_SYMLOOP_MAX = 120
|
|
X_SC_SYNCHRONIZED_IO = 40
|
|
X_SC_THREADS = 96
|
|
X_SC_THREAD_ATTR_STACKADDR = 82
|
|
X_SC_THREAD_ATTR_STACKSIZE = 83
|
|
X_SC_THREAD_CPUTIME = 84
|
|
X_SC_THREAD_DESTRUCTOR_ITERATIONS = 85
|
|
X_SC_THREAD_KEYS_MAX = 86
|
|
X_SC_THREAD_PRIORITY_SCHEDULING = 89
|
|
X_SC_THREAD_PRIO_INHERIT = 87
|
|
X_SC_THREAD_PRIO_PROTECT = 88
|
|
X_SC_THREAD_PROCESS_SHARED = 90
|
|
X_SC_THREAD_SAFE_FUNCTIONS = 91
|
|
X_SC_THREAD_SPORADIC_SERVER = 92
|
|
X_SC_THREAD_STACK_MIN = 93
|
|
X_SC_THREAD_THREADS_MAX = 94
|
|
X_SC_TIMEOUTS = 95
|
|
X_SC_TIMERS = 41
|
|
X_SC_TIMER_MAX = 52
|
|
X_SC_TRACE = 97
|
|
X_SC_TRACE_EVENT_FILTER = 98
|
|
X_SC_TRACE_EVENT_NAME_MAX = 127
|
|
X_SC_TRACE_INHERIT = 99
|
|
X_SC_TRACE_LOG = 100
|
|
X_SC_TRACE_NAME_MAX = 128
|
|
X_SC_TRACE_SYS_MAX = 129
|
|
X_SC_TRACE_USER_EVENT_MAX = 130
|
|
X_SC_TTY_NAME_MAX = 101
|
|
X_SC_TYPED_MEMORY_OBJECTS = 102
|
|
X_SC_TZNAME_MAX = 27
|
|
X_SC_V6_ILP32_OFF32 = 103
|
|
X_SC_V6_ILP32_OFFBIG = 104
|
|
X_SC_V6_LP64_OFF64 = 105
|
|
X_SC_V6_LPBIG_OFFBIG = 106
|
|
X_SC_VERSION = 8
|
|
X_SC_XBS5_ILP32_OFF32 = 122
|
|
X_SC_XBS5_ILP32_OFFBIG = 123
|
|
X_SC_XBS5_LP64_OFF64 = 124
|
|
X_SC_XBS5_LPBIG_OFFBIG = 125
|
|
X_SC_XOPEN_CRYPT = 108
|
|
X_SC_XOPEN_ENH_I18N = 109
|
|
X_SC_XOPEN_LEGACY = 110
|
|
X_SC_XOPEN_REALTIME = 111
|
|
X_SC_XOPEN_REALTIME_THREADS = 112
|
|
X_SC_XOPEN_SHM = 113
|
|
X_SC_XOPEN_STREAMS = 114
|
|
X_SC_XOPEN_UNIX = 115
|
|
X_SC_XOPEN_VERSION = 116
|
|
X_SC_XOPEN_XCU_VERSION = 121
|
|
X_SECURE__COMMON_H_ = 0
|
|
X_SECURE__STDIO_H_ = 0
|
|
X_SECURE__STRINGS_H_ = 0
|
|
X_SECURE__STRING_H_ = 0
|
|
X_SIGSET_T = 0
|
|
X_SIZE_T = 0
|
|
X_SQLITE3RTREE_H_ = 0
|
|
X_SSIZE_T = 0
|
|
X_STDARG_H = 0
|
|
X_STDINT_H_ = 0
|
|
X_STDIO_H_ = 0
|
|
X_STDLIB_H_ = 0
|
|
X_STRINGS_H_ = 0
|
|
X_STRING_H_ = 0
|
|
X_SUSECONDS_T = 0
|
|
X_SYS_ERRNO_H_ = 0
|
|
X_SYS_RESOURCE_H_ = 0
|
|
X_SYS_SELECT_H_ = 0
|
|
X_SYS_SIGNAL_H_ = 0
|
|
X_SYS_STDIO_H_ = 0
|
|
X_SYS_UNISTD_H_ = 0
|
|
X_SYS_WAIT_H_ = 0
|
|
X_SYS__ENDIAN_H_ = 0
|
|
X_SYS__PTHREAD_TYPES_H_ = 0
|
|
X_SYS__SELECT_H_ = 0
|
|
X_SYS__TYPES_H_ = 0
|
|
X_TIME_T = 0
|
|
X_UID_T = 0
|
|
X_UINT16_T = 0
|
|
X_UINT32_T = 0
|
|
X_UINT64_T = 0
|
|
X_UINT8_T = 0
|
|
X_UINTMAX_T = 0
|
|
X_UINTPTR_T = 0
|
|
X_UNISTD_H_ = 0
|
|
X_USECONDS_T = 0
|
|
X_USE_FORTIFY_LEVEL = 2
|
|
X_UUID_T = 0
|
|
X_U_INT16_T = 0
|
|
X_U_INT32_T = 0
|
|
X_U_INT64_T = 0
|
|
X_U_INT8_T = 0
|
|
X_V6_ILP32_OFF32 = -1
|
|
X_V6_ILP32_OFFBIG = -1
|
|
X_V6_LP64_OFF64 = 1
|
|
X_V6_LPBIG_OFFBIG = 1
|
|
X_VA_LIST = 0
|
|
X_VA_LIST_ = 0
|
|
X_VA_LIST_DEFINED = 0
|
|
X_VA_LIST_T = 0
|
|
X_VA_LIST_T_H = 0
|
|
X_WATTR_OK = 65536
|
|
X_WCHAR_T = 0
|
|
X_WEXT_OK = 262144
|
|
X_WINT_T = 0
|
|
X_WPERM_OK = 1048576
|
|
X_WRITE_OK = 1024
|
|
X_WSTOPPED = 0177
|
|
X_XBS5_ILP32_OFF32 = -1
|
|
X_XBS5_ILP32_OFFBIG = -1
|
|
X_XBS5_LP64_OFF64 = 1
|
|
X_XBS5_LPBIG_OFFBIG = 1
|
|
X_XOPEN_CRYPT = 1
|
|
X_XOPEN_ENH_I18N = 1
|
|
X_XOPEN_LEGACY = -1
|
|
X_XOPEN_REALTIME = -1
|
|
X_XOPEN_REALTIME_THREADS = -1
|
|
X_XOPEN_SHM = 1
|
|
X_XOPEN_STREAMS = -1
|
|
X_XOPEN_UNIX = 1
|
|
X_XOPEN_VERSION = 600
|
|
X_XOPEN_XCU_VERSION = 4
|
|
)
|
|
|
|
// Error codes
|
|
|
|
// 11 was EAGAIN
|
|
|
|
// math software
|
|
|
|
// non-blocking and interrupt i/o
|
|
|
|
// ipc/network software -- argument errors
|
|
|
|
// ipc/network software -- operational errors
|
|
|
|
// should be rearranged
|
|
|
|
// quotas & mush
|
|
|
|
// Network File System
|
|
|
|
// Intelligent device errors
|
|
|
|
// Program loading errors
|
|
|
|
// This value is only discrete when compiling __DARWIN_UNIX03, or KERNEL
|
|
|
|
// Copyright (c) 2000, 2002 - 2008 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
// -
|
|
// Copyright (c) 1990, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)stdlib.h 8.5 (Berkeley) 5/19/95
|
|
|
|
// Copyright (c) 2007-2016 by Apple Inc.. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2004, 2008, 2009 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 1995 NeXT Computer, Inc. All Rights Reserved
|
|
// Copyright (c) 1982, 1986, 1989, 1993, 1994
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)wait.h 8.2 (Berkeley) 7/10/94
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// This file holds definitions relevent to the wait4 system call
|
|
// and the alternate interfaces that use it (wait, wait3, waitpid).
|
|
|
|
// [XSI] The type idtype_t shall be defined as an enumeration type whose
|
|
// possible values shall include at least P_ALL, P_PID, and P_PGID.
|
|
const ( /* wait.h:79:1: */
|
|
P_ALL = 0
|
|
P_PID = 1
|
|
P_PGID = 2
|
|
)
|
|
|
|
type ptrdiff_t = int64 /* <builtin>:3:26 */
|
|
|
|
type size_t = uint64 /* <builtin>:9:23 */
|
|
|
|
type wchar_t = int32 /* <builtin>:15:24 */
|
|
|
|
// Define the standard macros for the user,
|
|
// if this invocation was from the user program.
|
|
|
|
// Define va_list, if desired, from __gnuc_va_list.
|
|
// We deliberately do not define va_list when called from
|
|
// stdio.h, because ANSI C says that stdio.h is not supposed to define
|
|
// va_list. stdio.h needs to have access to that data type,
|
|
// but must not use that name. It should use the name __gnuc_va_list,
|
|
// which is safe because it is reserved for the implementation.
|
|
|
|
// The macro _VA_LIST_ is the same thing used by this file in Ultrix.
|
|
// But on BSD NET2 we must not test or define or undef it.
|
|
// (Note that the comments in NET 2's ansi.h
|
|
// are incorrect for _VA_LIST_--see stdio.h!)
|
|
// The macro _VA_LIST_DEFINED is used in Windows NT 3.5
|
|
// The macro _VA_LIST is used in SCO Unix 3.2.
|
|
// The macro _VA_LIST_T_H is used in the Bull dpx2
|
|
// The macro __va_list__ is used by BeOS.
|
|
type va_list = uintptr /* stdarg.h:99:24 */
|
|
|
|
// CAPI3REF: 64-Bit Integer Types
|
|
// KEYWORDS: sqlite_int64 sqlite_uint64
|
|
//
|
|
// Because there is no cross-platform way to specify 64-bit integer types
|
|
// SQLite includes typedefs for 64-bit signed and unsigned integers.
|
|
//
|
|
// The sqlite3_int64 and sqlite3_uint64 are the preferred type definitions.
|
|
// The sqlite_int64 and sqlite_uint64 types are supported for backwards
|
|
// compatibility only.
|
|
//
|
|
// ^The sqlite3_int64 and sqlite_int64 types can store integer values
|
|
// between -9223372036854775808 and +9223372036854775807 inclusive. ^The
|
|
// sqlite3_uint64 and sqlite_uint64 types can store integer values
|
|
// between 0 and +18446744073709551615 inclusive.
|
|
type sqlite_int64 = int64 /* sqlite3.h:278:25 */
|
|
type sqlite_uint64 = uint64 /* sqlite3.h:279:34 */
|
|
type sqlite3_int64 = sqlite_int64 /* sqlite3.h:281:22 */
|
|
type sqlite3_uint64 = sqlite_uint64 /* sqlite3.h:282:23 */
|
|
|
|
// The type for a callback function.
|
|
// This is legacy and deprecated. It is included for historical
|
|
// compatibility and is not documented.
|
|
type sqlite3_callback = uintptr /* sqlite3.h:338:13 */
|
|
|
|
// CAPI3REF: Result Codes
|
|
// KEYWORDS: {result code definitions}
|
|
//
|
|
// Many SQLite functions return an integer result code from the set shown
|
|
// here in order to indicate success or failure.
|
|
//
|
|
// New error codes may be added in future versions of SQLite.
|
|
//
|
|
// See also: [extended result code definitions]
|
|
// beginning-of-error-codes
|
|
// end-of-error-codes
|
|
|
|
// CAPI3REF: Extended Result Codes
|
|
// KEYWORDS: {extended result code definitions}
|
|
//
|
|
// In its default configuration, SQLite API routines return one of 30 integer
|
|
// [result codes]. However, experience has shown that many of
|
|
// these result codes are too coarse-grained. They do not provide as
|
|
// much information about problems as programmers might like. In an effort to
|
|
// address this, newer versions of SQLite (version 3.3.8 [dateof:3.3.8]
|
|
// and later) include
|
|
// support for additional result codes that provide more detailed information
|
|
// about errors. These [extended result codes] are enabled or disabled
|
|
// on a per database connection basis using the
|
|
// [sqlite3_extended_result_codes()] API. Or, the extended code for
|
|
// the most recent error can be obtained using
|
|
// [sqlite3_extended_errcode()].
|
|
|
|
// CAPI3REF: Flags For File Open Operations
|
|
//
|
|
// These bit values are intended for use in the
|
|
// 3rd parameter to the [sqlite3_open_v2()] interface and
|
|
// in the 4th parameter to the [sqlite3_vfs.xOpen] method.
|
|
|
|
// Reserved: 0x00F00000
|
|
// Legacy compatibility:
|
|
|
|
// CAPI3REF: Device Characteristics
|
|
//
|
|
// The xDeviceCharacteristics method of the [sqlite3_io_methods]
|
|
// object returns an integer which is a vector of these
|
|
// bit values expressing I/O characteristics of the mass storage
|
|
// device that holds the file that the [sqlite3_io_methods]
|
|
// refers to.
|
|
//
|
|
// The SQLITE_IOCAP_ATOMIC property means that all writes of
|
|
// any size are atomic. The SQLITE_IOCAP_ATOMICnnn values
|
|
// mean that writes of blocks that are nnn bytes in size and
|
|
// are aligned to an address which is an integer multiple of
|
|
// nnn are atomic. The SQLITE_IOCAP_SAFE_APPEND value means
|
|
// that when data is appended to a file, the data is appended
|
|
// first then the size of the file is extended, never the other
|
|
// way around. The SQLITE_IOCAP_SEQUENTIAL property means that
|
|
// information is written to disk in the same order as calls
|
|
// to xWrite(). The SQLITE_IOCAP_POWERSAFE_OVERWRITE property means that
|
|
// after reboot following a crash or power loss, the only bytes in a
|
|
// file that were written at the application level might have changed
|
|
// and that adjacent bytes, even bytes within the same sector are
|
|
// guaranteed to be unchanged. The SQLITE_IOCAP_UNDELETABLE_WHEN_OPEN
|
|
// flag indicates that a file cannot be deleted when open. The
|
|
// SQLITE_IOCAP_IMMUTABLE flag indicates that the file is on
|
|
// read-only media and cannot be changed even by processes with
|
|
// elevated privileges.
|
|
//
|
|
// The SQLITE_IOCAP_BATCH_ATOMIC property means that the underlying
|
|
// filesystem supports doing multiple write operations atomically when those
|
|
// write operations are bracketed by [SQLITE_FCNTL_BEGIN_ATOMIC_WRITE] and
|
|
// [SQLITE_FCNTL_COMMIT_ATOMIC_WRITE].
|
|
|
|
// CAPI3REF: File Locking Levels
|
|
//
|
|
// SQLite uses one of these integer values as the second
|
|
// argument to calls it makes to the xLock() and xUnlock() methods
|
|
// of an [sqlite3_io_methods] object.
|
|
|
|
// CAPI3REF: Synchronization Type Flags
|
|
//
|
|
// When SQLite invokes the xSync() method of an
|
|
// [sqlite3_io_methods] object it uses a combination of
|
|
// these integer values as the second argument.
|
|
//
|
|
// When the SQLITE_SYNC_DATAONLY flag is used, it means that the
|
|
// sync operation only needs to flush data to mass storage. Inode
|
|
// information need not be flushed. If the lower four bits of the flag
|
|
// equal SQLITE_SYNC_NORMAL, that means to use normal fsync() semantics.
|
|
// If the lower four bits equal SQLITE_SYNC_FULL, that means
|
|
// to use Mac OS X style fullsync instead of fsync().
|
|
//
|
|
// Do not confuse the SQLITE_SYNC_NORMAL and SQLITE_SYNC_FULL flags
|
|
// with the [PRAGMA synchronous]=NORMAL and [PRAGMA synchronous]=FULL
|
|
// settings. The [synchronous pragma] determines when calls to the
|
|
// xSync VFS method occur and applies uniformly across all platforms.
|
|
// The SQLITE_SYNC_NORMAL and SQLITE_SYNC_FULL flags determine how
|
|
// energetic or rigorous or forceful the sync operations are and
|
|
// only make a difference on Mac OSX for the default SQLite code.
|
|
// (Third-party VFS implementations might also make the distinction
|
|
// between SQLITE_SYNC_NORMAL and SQLITE_SYNC_FULL, but among the
|
|
// operating systems natively supported by SQLite, only Mac OSX
|
|
// cares about the difference.)
|
|
|
|
// CAPI3REF: OS Interface Open File Handle
|
|
//
|
|
// An [sqlite3_file] object represents an open file in the
|
|
// [sqlite3_vfs | OS interface layer]. Individual OS interface
|
|
// implementations will
|
|
// want to subclass this object by appending additional fields
|
|
// for their own use. The pMethods entry is a pointer to an
|
|
// [sqlite3_io_methods] object that defines methods for performing
|
|
// I/O operations on the open file.
|
|
type sqlite3_file1 = struct{ pMethods uintptr } /* sqlite3.h:684:9 */
|
|
|
|
// CAPI3REF: Result Codes
|
|
// KEYWORDS: {result code definitions}
|
|
//
|
|
// Many SQLite functions return an integer result code from the set shown
|
|
// here in order to indicate success or failure.
|
|
//
|
|
// New error codes may be added in future versions of SQLite.
|
|
//
|
|
// See also: [extended result code definitions]
|
|
// beginning-of-error-codes
|
|
// end-of-error-codes
|
|
|
|
// CAPI3REF: Extended Result Codes
|
|
// KEYWORDS: {extended result code definitions}
|
|
//
|
|
// In its default configuration, SQLite API routines return one of 30 integer
|
|
// [result codes]. However, experience has shown that many of
|
|
// these result codes are too coarse-grained. They do not provide as
|
|
// much information about problems as programmers might like. In an effort to
|
|
// address this, newer versions of SQLite (version 3.3.8 [dateof:3.3.8]
|
|
// and later) include
|
|
// support for additional result codes that provide more detailed information
|
|
// about errors. These [extended result codes] are enabled or disabled
|
|
// on a per database connection basis using the
|
|
// [sqlite3_extended_result_codes()] API. Or, the extended code for
|
|
// the most recent error can be obtained using
|
|
// [sqlite3_extended_errcode()].
|
|
|
|
// CAPI3REF: Flags For File Open Operations
|
|
//
|
|
// These bit values are intended for use in the
|
|
// 3rd parameter to the [sqlite3_open_v2()] interface and
|
|
// in the 4th parameter to the [sqlite3_vfs.xOpen] method.
|
|
|
|
// Reserved: 0x00F00000
|
|
// Legacy compatibility:
|
|
|
|
// CAPI3REF: Device Characteristics
|
|
//
|
|
// The xDeviceCharacteristics method of the [sqlite3_io_methods]
|
|
// object returns an integer which is a vector of these
|
|
// bit values expressing I/O characteristics of the mass storage
|
|
// device that holds the file that the [sqlite3_io_methods]
|
|
// refers to.
|
|
//
|
|
// The SQLITE_IOCAP_ATOMIC property means that all writes of
|
|
// any size are atomic. The SQLITE_IOCAP_ATOMICnnn values
|
|
// mean that writes of blocks that are nnn bytes in size and
|
|
// are aligned to an address which is an integer multiple of
|
|
// nnn are atomic. The SQLITE_IOCAP_SAFE_APPEND value means
|
|
// that when data is appended to a file, the data is appended
|
|
// first then the size of the file is extended, never the other
|
|
// way around. The SQLITE_IOCAP_SEQUENTIAL property means that
|
|
// information is written to disk in the same order as calls
|
|
// to xWrite(). The SQLITE_IOCAP_POWERSAFE_OVERWRITE property means that
|
|
// after reboot following a crash or power loss, the only bytes in a
|
|
// file that were written at the application level might have changed
|
|
// and that adjacent bytes, even bytes within the same sector are
|
|
// guaranteed to be unchanged. The SQLITE_IOCAP_UNDELETABLE_WHEN_OPEN
|
|
// flag indicates that a file cannot be deleted when open. The
|
|
// SQLITE_IOCAP_IMMUTABLE flag indicates that the file is on
|
|
// read-only media and cannot be changed even by processes with
|
|
// elevated privileges.
|
|
//
|
|
// The SQLITE_IOCAP_BATCH_ATOMIC property means that the underlying
|
|
// filesystem supports doing multiple write operations atomically when those
|
|
// write operations are bracketed by [SQLITE_FCNTL_BEGIN_ATOMIC_WRITE] and
|
|
// [SQLITE_FCNTL_COMMIT_ATOMIC_WRITE].
|
|
|
|
// CAPI3REF: File Locking Levels
|
|
//
|
|
// SQLite uses one of these integer values as the second
|
|
// argument to calls it makes to the xLock() and xUnlock() methods
|
|
// of an [sqlite3_io_methods] object.
|
|
|
|
// CAPI3REF: Synchronization Type Flags
|
|
//
|
|
// When SQLite invokes the xSync() method of an
|
|
// [sqlite3_io_methods] object it uses a combination of
|
|
// these integer values as the second argument.
|
|
//
|
|
// When the SQLITE_SYNC_DATAONLY flag is used, it means that the
|
|
// sync operation only needs to flush data to mass storage. Inode
|
|
// information need not be flushed. If the lower four bits of the flag
|
|
// equal SQLITE_SYNC_NORMAL, that means to use normal fsync() semantics.
|
|
// If the lower four bits equal SQLITE_SYNC_FULL, that means
|
|
// to use Mac OS X style fullsync instead of fsync().
|
|
//
|
|
// Do not confuse the SQLITE_SYNC_NORMAL and SQLITE_SYNC_FULL flags
|
|
// with the [PRAGMA synchronous]=NORMAL and [PRAGMA synchronous]=FULL
|
|
// settings. The [synchronous pragma] determines when calls to the
|
|
// xSync VFS method occur and applies uniformly across all platforms.
|
|
// The SQLITE_SYNC_NORMAL and SQLITE_SYNC_FULL flags determine how
|
|
// energetic or rigorous or forceful the sync operations are and
|
|
// only make a difference on Mac OSX for the default SQLite code.
|
|
// (Third-party VFS implementations might also make the distinction
|
|
// between SQLITE_SYNC_NORMAL and SQLITE_SYNC_FULL, but among the
|
|
// operating systems natively supported by SQLite, only Mac OSX
|
|
// cares about the difference.)
|
|
|
|
// CAPI3REF: OS Interface Open File Handle
|
|
//
|
|
// An [sqlite3_file] object represents an open file in the
|
|
// [sqlite3_vfs | OS interface layer]. Individual OS interface
|
|
// implementations will
|
|
// want to subclass this object by appending additional fields
|
|
// for their own use. The pMethods entry is a pointer to an
|
|
// [sqlite3_io_methods] object that defines methods for performing
|
|
// I/O operations on the open file.
|
|
type sqlite3_file = sqlite3_file1 /* sqlite3.h:684:29 */
|
|
type sqlite3_io_methods1 = struct {
|
|
iVersion int32
|
|
_ [4]byte
|
|
xClose uintptr
|
|
xRead uintptr
|
|
xWrite uintptr
|
|
xTruncate uintptr
|
|
xSync uintptr
|
|
xFileSize uintptr
|
|
xLock uintptr
|
|
xUnlock uintptr
|
|
xCheckReservedLock uintptr
|
|
xFileControl uintptr
|
|
xSectorSize uintptr
|
|
xDeviceCharacteristics uintptr
|
|
xShmMap uintptr
|
|
xShmLock uintptr
|
|
xShmBarrier uintptr
|
|
xShmUnmap uintptr
|
|
xFetch uintptr
|
|
xUnfetch uintptr
|
|
} /* sqlite3.h:684:9 */
|
|
|
|
// CAPI3REF: OS Interface File Virtual Methods Object
|
|
//
|
|
// Every file opened by the [sqlite3_vfs.xOpen] method populates an
|
|
// [sqlite3_file] object (or, more commonly, a subclass of the
|
|
// [sqlite3_file] object) with a pointer to an instance of this object.
|
|
// This object defines the methods used to perform various operations
|
|
// against the open file represented by the [sqlite3_file] object.
|
|
//
|
|
// If the [sqlite3_vfs.xOpen] method sets the sqlite3_file.pMethods element
|
|
// to a non-NULL pointer, then the sqlite3_io_methods.xClose method
|
|
// may be invoked even if the [sqlite3_vfs.xOpen] reported that it failed. The
|
|
// only way to prevent a call to xClose following a failed [sqlite3_vfs.xOpen]
|
|
// is for the [sqlite3_vfs.xOpen] to set the sqlite3_file.pMethods element
|
|
// to NULL.
|
|
//
|
|
// The flags argument to xSync may be one of [SQLITE_SYNC_NORMAL] or
|
|
// [SQLITE_SYNC_FULL]. The first choice is the normal fsync().
|
|
// The second choice is a Mac OS X style fullsync. The [SQLITE_SYNC_DATAONLY]
|
|
// flag may be ORed in to indicate that only the data of the file
|
|
// and not its inode needs to be synced.
|
|
//
|
|
// The integer values to xLock() and xUnlock() are one of
|
|
// <ul>
|
|
// <li> [SQLITE_LOCK_NONE],
|
|
// <li> [SQLITE_LOCK_SHARED],
|
|
// <li> [SQLITE_LOCK_RESERVED],
|
|
// <li> [SQLITE_LOCK_PENDING], or
|
|
// <li> [SQLITE_LOCK_EXCLUSIVE].
|
|
// </ul>
|
|
// xLock() increases the lock. xUnlock() decreases the lock.
|
|
// The xCheckReservedLock() method checks whether any database connection,
|
|
// either in this process or in some other process, is holding a RESERVED,
|
|
// PENDING, or EXCLUSIVE lock on the file. It returns true
|
|
// if such a lock exists and false otherwise.
|
|
//
|
|
// The xFileControl() method is a generic interface that allows custom
|
|
// VFS implementations to directly control an open file using the
|
|
// [sqlite3_file_control()] interface. The second "op" argument is an
|
|
// integer opcode. The third argument is a generic pointer intended to
|
|
// point to a structure that may contain arguments or space in which to
|
|
// write return values. Potential uses for xFileControl() might be
|
|
// functions to enable blocking locks with timeouts, to change the
|
|
// locking strategy (for example to use dot-file locks), to inquire
|
|
// about the status of a lock, or to break stale locks. The SQLite
|
|
// core reserves all opcodes less than 100 for its own use.
|
|
// A [file control opcodes | list of opcodes] less than 100 is available.
|
|
// Applications that define a custom xFileControl method should use opcodes
|
|
// greater than 100 to avoid conflicts. VFS implementations should
|
|
// return [SQLITE_NOTFOUND] for file control opcodes that they do not
|
|
// recognize.
|
|
//
|
|
// The xSectorSize() method returns the sector size of the
|
|
// device that underlies the file. The sector size is the
|
|
// minimum write that can be performed without disturbing
|
|
// other bytes in the file. The xDeviceCharacteristics()
|
|
// method returns a bit vector describing behaviors of the
|
|
// underlying device:
|
|
//
|
|
// <ul>
|
|
// <li> [SQLITE_IOCAP_ATOMIC]
|
|
// <li> [SQLITE_IOCAP_ATOMIC512]
|
|
// <li> [SQLITE_IOCAP_ATOMIC1K]
|
|
// <li> [SQLITE_IOCAP_ATOMIC2K]
|
|
// <li> [SQLITE_IOCAP_ATOMIC4K]
|
|
// <li> [SQLITE_IOCAP_ATOMIC8K]
|
|
// <li> [SQLITE_IOCAP_ATOMIC16K]
|
|
// <li> [SQLITE_IOCAP_ATOMIC32K]
|
|
// <li> [SQLITE_IOCAP_ATOMIC64K]
|
|
// <li> [SQLITE_IOCAP_SAFE_APPEND]
|
|
// <li> [SQLITE_IOCAP_SEQUENTIAL]
|
|
// <li> [SQLITE_IOCAP_UNDELETABLE_WHEN_OPEN]
|
|
// <li> [SQLITE_IOCAP_POWERSAFE_OVERWRITE]
|
|
// <li> [SQLITE_IOCAP_IMMUTABLE]
|
|
// <li> [SQLITE_IOCAP_BATCH_ATOMIC]
|
|
// </ul>
|
|
//
|
|
// The SQLITE_IOCAP_ATOMIC property means that all writes of
|
|
// any size are atomic. The SQLITE_IOCAP_ATOMICnnn values
|
|
// mean that writes of blocks that are nnn bytes in size and
|
|
// are aligned to an address which is an integer multiple of
|
|
// nnn are atomic. The SQLITE_IOCAP_SAFE_APPEND value means
|
|
// that when data is appended to a file, the data is appended
|
|
// first then the size of the file is extended, never the other
|
|
// way around. The SQLITE_IOCAP_SEQUENTIAL property means that
|
|
// information is written to disk in the same order as calls
|
|
// to xWrite().
|
|
//
|
|
// If xRead() returns SQLITE_IOERR_SHORT_READ it must also fill
|
|
// in the unread portions of the buffer with zeros. A VFS that
|
|
// fails to zero-fill short reads might seem to work. However,
|
|
// failure to zero-fill short reads will eventually lead to
|
|
// database corruption.
|
|
type sqlite3_io_methods = sqlite3_io_methods1 /* sqlite3.h:783:35 */
|
|
|
|
// CAPI3REF: OS Interface Object
|
|
//
|
|
// An instance of the sqlite3_vfs object defines the interface between
|
|
// the SQLite core and the underlying operating system. The "vfs"
|
|
// in the name of the object stands for "virtual file system". See
|
|
// the [VFS | VFS documentation] for further information.
|
|
//
|
|
// The VFS interface is sometimes extended by adding new methods onto
|
|
// the end. Each time such an extension occurs, the iVersion field
|
|
// is incremented. The iVersion value started out as 1 in
|
|
// SQLite [version 3.5.0] on [dateof:3.5.0], then increased to 2
|
|
// with SQLite [version 3.7.0] on [dateof:3.7.0], and then increased
|
|
// to 3 with SQLite [version 3.7.6] on [dateof:3.7.6]. Additional fields
|
|
// may be appended to the sqlite3_vfs object and the iVersion value
|
|
// may increase again in future versions of SQLite.
|
|
// Note that due to an oversight, the structure
|
|
// of the sqlite3_vfs object changed in the transition from
|
|
// SQLite [version 3.5.9] to [version 3.6.0] on [dateof:3.6.0]
|
|
// and yet the iVersion field was not increased.
|
|
//
|
|
// The szOsFile field is the size of the subclassed [sqlite3_file]
|
|
// structure used by this VFS. mxPathname is the maximum length of
|
|
// a pathname in this VFS.
|
|
//
|
|
// Registered sqlite3_vfs objects are kept on a linked list formed by
|
|
// the pNext pointer. The [sqlite3_vfs_register()]
|
|
// and [sqlite3_vfs_unregister()] interfaces manage this list
|
|
// in a thread-safe way. The [sqlite3_vfs_find()] interface
|
|
// searches the list. Neither the application code nor the VFS
|
|
// implementation should use the pNext pointer.
|
|
//
|
|
// The pNext field is the only field in the sqlite3_vfs
|
|
// structure that SQLite will ever modify. SQLite will only access
|
|
// or modify this field while holding a particular static mutex.
|
|
// The application should never modify anything within the sqlite3_vfs
|
|
// object once the object has been registered.
|
|
//
|
|
// The zName field holds the name of the VFS module. The name must
|
|
// be unique across all VFS modules.
|
|
//
|
|
// [[sqlite3_vfs.xOpen]]
|
|
// ^SQLite guarantees that the zFilename parameter to xOpen
|
|
// is either a NULL pointer or string obtained
|
|
// from xFullPathname() with an optional suffix added.
|
|
// ^If a suffix is added to the zFilename parameter, it will
|
|
// consist of a single "-" character followed by no more than
|
|
// 11 alphanumeric and/or "-" characters.
|
|
// ^SQLite further guarantees that
|
|
// the string will be valid and unchanged until xClose() is
|
|
// called. Because of the previous sentence,
|
|
// the [sqlite3_file] can safely store a pointer to the
|
|
// filename if it needs to remember the filename for some reason.
|
|
// If the zFilename parameter to xOpen is a NULL pointer then xOpen
|
|
// must invent its own temporary name for the file. ^Whenever the
|
|
// xFilename parameter is NULL it will also be the case that the
|
|
// flags parameter will include [SQLITE_OPEN_DELETEONCLOSE].
|
|
//
|
|
// The flags argument to xOpen() includes all bits set in
|
|
// the flags argument to [sqlite3_open_v2()]. Or if [sqlite3_open()]
|
|
// or [sqlite3_open16()] is used, then flags includes at least
|
|
// [SQLITE_OPEN_READWRITE] | [SQLITE_OPEN_CREATE].
|
|
// If xOpen() opens a file read-only then it sets *pOutFlags to
|
|
// include [SQLITE_OPEN_READONLY]. Other bits in *pOutFlags may be set.
|
|
//
|
|
// ^(SQLite will also add one of the following flags to the xOpen()
|
|
// call, depending on the object being opened:
|
|
//
|
|
// <ul>
|
|
// <li> [SQLITE_OPEN_MAIN_DB]
|
|
// <li> [SQLITE_OPEN_MAIN_JOURNAL]
|
|
// <li> [SQLITE_OPEN_TEMP_DB]
|
|
// <li> [SQLITE_OPEN_TEMP_JOURNAL]
|
|
// <li> [SQLITE_OPEN_TRANSIENT_DB]
|
|
// <li> [SQLITE_OPEN_SUBJOURNAL]
|
|
// <li> [SQLITE_OPEN_SUPER_JOURNAL]
|
|
// <li> [SQLITE_OPEN_WAL]
|
|
// </ul>)^
|
|
//
|
|
// The file I/O implementation can use the object type flags to
|
|
// change the way it deals with files. For example, an application
|
|
// that does not care about crash recovery or rollback might make
|
|
// the open of a journal file a no-op. Writes to this journal would
|
|
// also be no-ops, and any attempt to read the journal would return
|
|
// SQLITE_IOERR. Or the implementation might recognize that a database
|
|
// file will be doing page-aligned sector reads and writes in a random
|
|
// order and set up its I/O subsystem accordingly.
|
|
//
|
|
// SQLite might also add one of the following flags to the xOpen method:
|
|
//
|
|
// <ul>
|
|
// <li> [SQLITE_OPEN_DELETEONCLOSE]
|
|
// <li> [SQLITE_OPEN_EXCLUSIVE]
|
|
// </ul>
|
|
//
|
|
// The [SQLITE_OPEN_DELETEONCLOSE] flag means the file should be
|
|
// deleted when it is closed. ^The [SQLITE_OPEN_DELETEONCLOSE]
|
|
// will be set for TEMP databases and their journals, transient
|
|
// databases, and subjournals.
|
|
//
|
|
// ^The [SQLITE_OPEN_EXCLUSIVE] flag is always used in conjunction
|
|
// with the [SQLITE_OPEN_CREATE] flag, which are both directly
|
|
// analogous to the O_EXCL and O_CREAT flags of the POSIX open()
|
|
// API. The SQLITE_OPEN_EXCLUSIVE flag, when paired with the
|
|
// SQLITE_OPEN_CREATE, is used to indicate that file should always
|
|
// be created, and that it is an error if it already exists.
|
|
// It is <i>not</i> used to indicate the file should be opened
|
|
// for exclusive access.
|
|
//
|
|
// ^At least szOsFile bytes of memory are allocated by SQLite
|
|
// to hold the [sqlite3_file] structure passed as the third
|
|
// argument to xOpen. The xOpen method does not have to
|
|
// allocate the structure; it should just fill it in. Note that
|
|
// the xOpen method must set the sqlite3_file.pMethods to either
|
|
// a valid [sqlite3_io_methods] object or to NULL. xOpen must do
|
|
// this even if the open fails. SQLite expects that the sqlite3_file.pMethods
|
|
// element will be valid after xOpen returns regardless of the success
|
|
// or failure of the xOpen call.
|
|
//
|
|
// [[sqlite3_vfs.xAccess]]
|
|
// ^The flags argument to xAccess() may be [SQLITE_ACCESS_EXISTS]
|
|
// to test for the existence of a file, or [SQLITE_ACCESS_READWRITE] to
|
|
// test whether a file is readable and writable, or [SQLITE_ACCESS_READ]
|
|
// to test whether a file is at least readable. The SQLITE_ACCESS_READ
|
|
// flag is never actually used and is not implemented in the built-in
|
|
// VFSes of SQLite. The file is named by the second argument and can be a
|
|
// directory. The xAccess method returns [SQLITE_OK] on success or some
|
|
// non-zero error code if there is an I/O error or if the name of
|
|
// the file given in the second argument is illegal. If SQLITE_OK
|
|
// is returned, then non-zero or zero is written into *pResOut to indicate
|
|
// whether or not the file is accessible.
|
|
//
|
|
// ^SQLite will always allocate at least mxPathname+1 bytes for the
|
|
// output buffer xFullPathname. The exact size of the output buffer
|
|
// is also passed as a parameter to both methods. If the output buffer
|
|
// is not large enough, [SQLITE_CANTOPEN] should be returned. Since this is
|
|
// handled as a fatal error by SQLite, vfs implementations should endeavor
|
|
// to prevent this by setting mxPathname to a sufficiently large value.
|
|
//
|
|
// The xRandomness(), xSleep(), xCurrentTime(), and xCurrentTimeInt64()
|
|
// interfaces are not strictly a part of the filesystem, but they are
|
|
// included in the VFS structure for completeness.
|
|
// The xRandomness() function attempts to return nBytes bytes
|
|
// of good-quality randomness into zOut. The return value is
|
|
// the actual number of bytes of randomness obtained.
|
|
// The xSleep() method causes the calling thread to sleep for at
|
|
// least the number of microseconds given. ^The xCurrentTime()
|
|
// method returns a Julian Day Number for the current date and time as
|
|
// a floating point value.
|
|
// ^The xCurrentTimeInt64() method returns, as an integer, the Julian
|
|
// Day Number multiplied by 86400000 (the number of milliseconds in
|
|
// a 24-hour day).
|
|
// ^SQLite will use the xCurrentTimeInt64() method to get the current
|
|
// date and time if that method is available (if iVersion is 2 or
|
|
// greater and the function pointer is not NULL) and will fall back
|
|
// to xCurrentTime() if xCurrentTimeInt64() is unavailable.
|
|
//
|
|
// ^The xSetSystemCall(), xGetSystemCall(), and xNestSystemCall() interfaces
|
|
// are not used by the SQLite core. These optional interfaces are provided
|
|
// by some VFSes to facilitate testing of the VFS code. By overriding
|
|
// system calls with functions under its control, a test program can
|
|
// simulate faults and error conditions that would otherwise be difficult
|
|
// or impossible to induce. The set of system calls that can be overridden
|
|
// varies from one VFS to another, and from one version of the same VFS to the
|
|
// next. Applications that use these interfaces must be prepared for any
|
|
// or all of these interfaces to be NULL or for their behavior to change
|
|
// from one release to the next. Applications must not attempt to access
|
|
// any of these methods if the iVersion of the VFS is less than 3.
|
|
type sqlite3_vfs1 = struct {
|
|
iVersion int32
|
|
szOsFile int32
|
|
mxPathname int32
|
|
_ [4]byte
|
|
pNext uintptr
|
|
zName uintptr
|
|
pAppData uintptr
|
|
xOpen uintptr
|
|
xDelete uintptr
|
|
xAccess uintptr
|
|
xFullPathname uintptr
|
|
xDlOpen uintptr
|
|
xDlError uintptr
|
|
xDlSym uintptr
|
|
xDlClose uintptr
|
|
xRandomness uintptr
|
|
xSleep uintptr
|
|
xCurrentTime uintptr
|
|
xGetLastError uintptr
|
|
xCurrentTimeInt64 uintptr
|
|
xSetSystemCall uintptr
|
|
xGetSystemCall uintptr
|
|
xNextSystemCall uintptr
|
|
} /* sqlite3.h:1368:9 */
|
|
|
|
// CAPI3REF: OS Interface Object
|
|
//
|
|
// An instance of the sqlite3_vfs object defines the interface between
|
|
// the SQLite core and the underlying operating system. The "vfs"
|
|
// in the name of the object stands for "virtual file system". See
|
|
// the [VFS | VFS documentation] for further information.
|
|
//
|
|
// The VFS interface is sometimes extended by adding new methods onto
|
|
// the end. Each time such an extension occurs, the iVersion field
|
|
// is incremented. The iVersion value started out as 1 in
|
|
// SQLite [version 3.5.0] on [dateof:3.5.0], then increased to 2
|
|
// with SQLite [version 3.7.0] on [dateof:3.7.0], and then increased
|
|
// to 3 with SQLite [version 3.7.6] on [dateof:3.7.6]. Additional fields
|
|
// may be appended to the sqlite3_vfs object and the iVersion value
|
|
// may increase again in future versions of SQLite.
|
|
// Note that due to an oversight, the structure
|
|
// of the sqlite3_vfs object changed in the transition from
|
|
// SQLite [version 3.5.9] to [version 3.6.0] on [dateof:3.6.0]
|
|
// and yet the iVersion field was not increased.
|
|
//
|
|
// The szOsFile field is the size of the subclassed [sqlite3_file]
|
|
// structure used by this VFS. mxPathname is the maximum length of
|
|
// a pathname in this VFS.
|
|
//
|
|
// Registered sqlite3_vfs objects are kept on a linked list formed by
|
|
// the pNext pointer. The [sqlite3_vfs_register()]
|
|
// and [sqlite3_vfs_unregister()] interfaces manage this list
|
|
// in a thread-safe way. The [sqlite3_vfs_find()] interface
|
|
// searches the list. Neither the application code nor the VFS
|
|
// implementation should use the pNext pointer.
|
|
//
|
|
// The pNext field is the only field in the sqlite3_vfs
|
|
// structure that SQLite will ever modify. SQLite will only access
|
|
// or modify this field while holding a particular static mutex.
|
|
// The application should never modify anything within the sqlite3_vfs
|
|
// object once the object has been registered.
|
|
//
|
|
// The zName field holds the name of the VFS module. The name must
|
|
// be unique across all VFS modules.
|
|
//
|
|
// [[sqlite3_vfs.xOpen]]
|
|
// ^SQLite guarantees that the zFilename parameter to xOpen
|
|
// is either a NULL pointer or string obtained
|
|
// from xFullPathname() with an optional suffix added.
|
|
// ^If a suffix is added to the zFilename parameter, it will
|
|
// consist of a single "-" character followed by no more than
|
|
// 11 alphanumeric and/or "-" characters.
|
|
// ^SQLite further guarantees that
|
|
// the string will be valid and unchanged until xClose() is
|
|
// called. Because of the previous sentence,
|
|
// the [sqlite3_file] can safely store a pointer to the
|
|
// filename if it needs to remember the filename for some reason.
|
|
// If the zFilename parameter to xOpen is a NULL pointer then xOpen
|
|
// must invent its own temporary name for the file. ^Whenever the
|
|
// xFilename parameter is NULL it will also be the case that the
|
|
// flags parameter will include [SQLITE_OPEN_DELETEONCLOSE].
|
|
//
|
|
// The flags argument to xOpen() includes all bits set in
|
|
// the flags argument to [sqlite3_open_v2()]. Or if [sqlite3_open()]
|
|
// or [sqlite3_open16()] is used, then flags includes at least
|
|
// [SQLITE_OPEN_READWRITE] | [SQLITE_OPEN_CREATE].
|
|
// If xOpen() opens a file read-only then it sets *pOutFlags to
|
|
// include [SQLITE_OPEN_READONLY]. Other bits in *pOutFlags may be set.
|
|
//
|
|
// ^(SQLite will also add one of the following flags to the xOpen()
|
|
// call, depending on the object being opened:
|
|
//
|
|
// <ul>
|
|
// <li> [SQLITE_OPEN_MAIN_DB]
|
|
// <li> [SQLITE_OPEN_MAIN_JOURNAL]
|
|
// <li> [SQLITE_OPEN_TEMP_DB]
|
|
// <li> [SQLITE_OPEN_TEMP_JOURNAL]
|
|
// <li> [SQLITE_OPEN_TRANSIENT_DB]
|
|
// <li> [SQLITE_OPEN_SUBJOURNAL]
|
|
// <li> [SQLITE_OPEN_SUPER_JOURNAL]
|
|
// <li> [SQLITE_OPEN_WAL]
|
|
// </ul>)^
|
|
//
|
|
// The file I/O implementation can use the object type flags to
|
|
// change the way it deals with files. For example, an application
|
|
// that does not care about crash recovery or rollback might make
|
|
// the open of a journal file a no-op. Writes to this journal would
|
|
// also be no-ops, and any attempt to read the journal would return
|
|
// SQLITE_IOERR. Or the implementation might recognize that a database
|
|
// file will be doing page-aligned sector reads and writes in a random
|
|
// order and set up its I/O subsystem accordingly.
|
|
//
|
|
// SQLite might also add one of the following flags to the xOpen method:
|
|
//
|
|
// <ul>
|
|
// <li> [SQLITE_OPEN_DELETEONCLOSE]
|
|
// <li> [SQLITE_OPEN_EXCLUSIVE]
|
|
// </ul>
|
|
//
|
|
// The [SQLITE_OPEN_DELETEONCLOSE] flag means the file should be
|
|
// deleted when it is closed. ^The [SQLITE_OPEN_DELETEONCLOSE]
|
|
// will be set for TEMP databases and their journals, transient
|
|
// databases, and subjournals.
|
|
//
|
|
// ^The [SQLITE_OPEN_EXCLUSIVE] flag is always used in conjunction
|
|
// with the [SQLITE_OPEN_CREATE] flag, which are both directly
|
|
// analogous to the O_EXCL and O_CREAT flags of the POSIX open()
|
|
// API. The SQLITE_OPEN_EXCLUSIVE flag, when paired with the
|
|
// SQLITE_OPEN_CREATE, is used to indicate that file should always
|
|
// be created, and that it is an error if it already exists.
|
|
// It is <i>not</i> used to indicate the file should be opened
|
|
// for exclusive access.
|
|
//
|
|
// ^At least szOsFile bytes of memory are allocated by SQLite
|
|
// to hold the [sqlite3_file] structure passed as the third
|
|
// argument to xOpen. The xOpen method does not have to
|
|
// allocate the structure; it should just fill it in. Note that
|
|
// the xOpen method must set the sqlite3_file.pMethods to either
|
|
// a valid [sqlite3_io_methods] object or to NULL. xOpen must do
|
|
// this even if the open fails. SQLite expects that the sqlite3_file.pMethods
|
|
// element will be valid after xOpen returns regardless of the success
|
|
// or failure of the xOpen call.
|
|
//
|
|
// [[sqlite3_vfs.xAccess]]
|
|
// ^The flags argument to xAccess() may be [SQLITE_ACCESS_EXISTS]
|
|
// to test for the existence of a file, or [SQLITE_ACCESS_READWRITE] to
|
|
// test whether a file is readable and writable, or [SQLITE_ACCESS_READ]
|
|
// to test whether a file is at least readable. The SQLITE_ACCESS_READ
|
|
// flag is never actually used and is not implemented in the built-in
|
|
// VFSes of SQLite. The file is named by the second argument and can be a
|
|
// directory. The xAccess method returns [SQLITE_OK] on success or some
|
|
// non-zero error code if there is an I/O error or if the name of
|
|
// the file given in the second argument is illegal. If SQLITE_OK
|
|
// is returned, then non-zero or zero is written into *pResOut to indicate
|
|
// whether or not the file is accessible.
|
|
//
|
|
// ^SQLite will always allocate at least mxPathname+1 bytes for the
|
|
// output buffer xFullPathname. The exact size of the output buffer
|
|
// is also passed as a parameter to both methods. If the output buffer
|
|
// is not large enough, [SQLITE_CANTOPEN] should be returned. Since this is
|
|
// handled as a fatal error by SQLite, vfs implementations should endeavor
|
|
// to prevent this by setting mxPathname to a sufficiently large value.
|
|
//
|
|
// The xRandomness(), xSleep(), xCurrentTime(), and xCurrentTimeInt64()
|
|
// interfaces are not strictly a part of the filesystem, but they are
|
|
// included in the VFS structure for completeness.
|
|
// The xRandomness() function attempts to return nBytes bytes
|
|
// of good-quality randomness into zOut. The return value is
|
|
// the actual number of bytes of randomness obtained.
|
|
// The xSleep() method causes the calling thread to sleep for at
|
|
// least the number of microseconds given. ^The xCurrentTime()
|
|
// method returns a Julian Day Number for the current date and time as
|
|
// a floating point value.
|
|
// ^The xCurrentTimeInt64() method returns, as an integer, the Julian
|
|
// Day Number multiplied by 86400000 (the number of milliseconds in
|
|
// a 24-hour day).
|
|
// ^SQLite will use the xCurrentTimeInt64() method to get the current
|
|
// date and time if that method is available (if iVersion is 2 or
|
|
// greater and the function pointer is not NULL) and will fall back
|
|
// to xCurrentTime() if xCurrentTimeInt64() is unavailable.
|
|
//
|
|
// ^The xSetSystemCall(), xGetSystemCall(), and xNestSystemCall() interfaces
|
|
// are not used by the SQLite core. These optional interfaces are provided
|
|
// by some VFSes to facilitate testing of the VFS code. By overriding
|
|
// system calls with functions under its control, a test program can
|
|
// simulate faults and error conditions that would otherwise be difficult
|
|
// or impossible to induce. The set of system calls that can be overridden
|
|
// varies from one VFS to another, and from one version of the same VFS to the
|
|
// next. Applications that use these interfaces must be prepared for any
|
|
// or all of these interfaces to be NULL or for their behavior to change
|
|
// from one release to the next. Applications must not attempt to access
|
|
// any of these methods if the iVersion of the VFS is less than 3.
|
|
type sqlite3_vfs = sqlite3_vfs1 /* sqlite3.h:1368:28 */
|
|
type sqlite3_syscall_ptr = uintptr /* sqlite3.h:1369:14 */
|
|
|
|
// CAPI3REF: Memory Allocation Routines
|
|
//
|
|
// An instance of this object defines the interface between SQLite
|
|
// and low-level memory allocation routines.
|
|
//
|
|
// This object is used in only one place in the SQLite interface.
|
|
// A pointer to an instance of this object is the argument to
|
|
// [sqlite3_config()] when the configuration option is
|
|
// [SQLITE_CONFIG_MALLOC] or [SQLITE_CONFIG_GETMALLOC].
|
|
// By creating an instance of this object
|
|
// and passing it to [sqlite3_config]([SQLITE_CONFIG_MALLOC])
|
|
// during configuration, an application can specify an alternative
|
|
// memory allocation subsystem for SQLite to use for all of its
|
|
// dynamic memory needs.
|
|
//
|
|
// Note that SQLite comes with several [built-in memory allocators]
|
|
// that are perfectly adequate for the overwhelming majority of applications
|
|
// and that this object is only useful to a tiny minority of applications
|
|
// with specialized memory allocation requirements. This object is
|
|
// also used during testing of SQLite in order to specify an alternative
|
|
// memory allocator that simulates memory out-of-memory conditions in
|
|
// order to verify that SQLite recovers gracefully from such
|
|
// conditions.
|
|
//
|
|
// The xMalloc, xRealloc, and xFree methods must work like the
|
|
// malloc(), realloc() and free() functions from the standard C library.
|
|
// ^SQLite guarantees that the second argument to
|
|
// xRealloc is always a value returned by a prior call to xRoundup.
|
|
//
|
|
// xSize should return the allocated size of a memory allocation
|
|
// previously obtained from xMalloc or xRealloc. The allocated size
|
|
// is always at least as big as the requested size but may be larger.
|
|
//
|
|
// The xRoundup method returns what would be the allocated size of
|
|
// a memory allocation given a particular requested size. Most memory
|
|
// allocators round up memory allocations at least to the next multiple
|
|
// of 8. Some allocators round up to a larger multiple or to a power of 2.
|
|
// Every memory allocation request coming in through [sqlite3_malloc()]
|
|
// or [sqlite3_realloc()] first calls xRoundup. If xRoundup returns 0,
|
|
// that causes the corresponding memory allocation to fail.
|
|
//
|
|
// The xInit method initializes the memory allocator. For example,
|
|
// it might allocate any required mutexes or initialize internal data
|
|
// structures. The xShutdown method is invoked (indirectly) by
|
|
// [sqlite3_shutdown()] and should deallocate any resources acquired
|
|
// by xInit. The pAppData pointer is used as the only parameter to
|
|
// xInit and xShutdown.
|
|
//
|
|
// SQLite holds the [SQLITE_MUTEX_STATIC_MAIN] mutex when it invokes
|
|
// the xInit method, so the xInit method need not be threadsafe. The
|
|
// xShutdown method is only called from [sqlite3_shutdown()] so it does
|
|
// not need to be threadsafe either. For all other methods, SQLite
|
|
// holds the [SQLITE_MUTEX_STATIC_MEM] mutex as long as the
|
|
// [SQLITE_CONFIG_MEMSTATUS] configuration option is turned on (which
|
|
// it is by default) and so the methods are automatically serialized.
|
|
// However, if [SQLITE_CONFIG_MEMSTATUS] is disabled, then the other
|
|
// methods must be threadsafe or else make their own arrangements for
|
|
// serialization.
|
|
//
|
|
// SQLite will never invoke xInit() more than once without an intervening
|
|
// call to xShutdown().
|
|
type sqlite3_mem_methods1 = struct {
|
|
xMalloc uintptr
|
|
xFree uintptr
|
|
xRealloc uintptr
|
|
xSize uintptr
|
|
xRoundup uintptr
|
|
xInit uintptr
|
|
xShutdown uintptr
|
|
pAppData uintptr
|
|
} /* sqlite3.h:1666:9 */
|
|
|
|
// CAPI3REF: Memory Allocation Routines
|
|
//
|
|
// An instance of this object defines the interface between SQLite
|
|
// and low-level memory allocation routines.
|
|
//
|
|
// This object is used in only one place in the SQLite interface.
|
|
// A pointer to an instance of this object is the argument to
|
|
// [sqlite3_config()] when the configuration option is
|
|
// [SQLITE_CONFIG_MALLOC] or [SQLITE_CONFIG_GETMALLOC].
|
|
// By creating an instance of this object
|
|
// and passing it to [sqlite3_config]([SQLITE_CONFIG_MALLOC])
|
|
// during configuration, an application can specify an alternative
|
|
// memory allocation subsystem for SQLite to use for all of its
|
|
// dynamic memory needs.
|
|
//
|
|
// Note that SQLite comes with several [built-in memory allocators]
|
|
// that are perfectly adequate for the overwhelming majority of applications
|
|
// and that this object is only useful to a tiny minority of applications
|
|
// with specialized memory allocation requirements. This object is
|
|
// also used during testing of SQLite in order to specify an alternative
|
|
// memory allocator that simulates memory out-of-memory conditions in
|
|
// order to verify that SQLite recovers gracefully from such
|
|
// conditions.
|
|
//
|
|
// The xMalloc, xRealloc, and xFree methods must work like the
|
|
// malloc(), realloc() and free() functions from the standard C library.
|
|
// ^SQLite guarantees that the second argument to
|
|
// xRealloc is always a value returned by a prior call to xRoundup.
|
|
//
|
|
// xSize should return the allocated size of a memory allocation
|
|
// previously obtained from xMalloc or xRealloc. The allocated size
|
|
// is always at least as big as the requested size but may be larger.
|
|
//
|
|
// The xRoundup method returns what would be the allocated size of
|
|
// a memory allocation given a particular requested size. Most memory
|
|
// allocators round up memory allocations at least to the next multiple
|
|
// of 8. Some allocators round up to a larger multiple or to a power of 2.
|
|
// Every memory allocation request coming in through [sqlite3_malloc()]
|
|
// or [sqlite3_realloc()] first calls xRoundup. If xRoundup returns 0,
|
|
// that causes the corresponding memory allocation to fail.
|
|
//
|
|
// The xInit method initializes the memory allocator. For example,
|
|
// it might allocate any required mutexes or initialize internal data
|
|
// structures. The xShutdown method is invoked (indirectly) by
|
|
// [sqlite3_shutdown()] and should deallocate any resources acquired
|
|
// by xInit. The pAppData pointer is used as the only parameter to
|
|
// xInit and xShutdown.
|
|
//
|
|
// SQLite holds the [SQLITE_MUTEX_STATIC_MAIN] mutex when it invokes
|
|
// the xInit method, so the xInit method need not be threadsafe. The
|
|
// xShutdown method is only called from [sqlite3_shutdown()] so it does
|
|
// not need to be threadsafe either. For all other methods, SQLite
|
|
// holds the [SQLITE_MUTEX_STATIC_MEM] mutex as long as the
|
|
// [SQLITE_CONFIG_MEMSTATUS] configuration option is turned on (which
|
|
// it is by default) and so the methods are automatically serialized.
|
|
// However, if [SQLITE_CONFIG_MEMSTATUS] is disabled, then the other
|
|
// methods must be threadsafe or else make their own arrangements for
|
|
// serialization.
|
|
//
|
|
// SQLite will never invoke xInit() more than once without an intervening
|
|
// call to xShutdown().
|
|
type sqlite3_mem_methods = sqlite3_mem_methods1 /* sqlite3.h:1666:36 */
|
|
|
|
// CAPI3REF: Constants Defining Special Destructor Behavior
|
|
//
|
|
// These are special values for the destructor that is passed in as the
|
|
// final argument to routines like [sqlite3_result_blob()]. ^If the destructor
|
|
// argument is SQLITE_STATIC, it means that the content pointer is constant
|
|
// and will never change. It does not need to be destroyed. ^The
|
|
// SQLITE_TRANSIENT value means that the content will likely change in
|
|
// the near future and that SQLite should make its own private copy of
|
|
// the content before returning.
|
|
//
|
|
// The typedef is necessary to work around problems in certain
|
|
// C++ compilers.
|
|
type sqlite3_destructor_type = uintptr /* sqlite3.h:5635:14 */
|
|
|
|
// The interface to the virtual-table mechanism is currently considered
|
|
// to be experimental. The interface might change in incompatible ways.
|
|
// If this is a problem for you, do not use the interface at this time.
|
|
//
|
|
// When the virtual-table mechanism stabilizes, we will declare the
|
|
// interface fixed, support it indefinitely, and remove this comment.
|
|
|
|
// Structures used by the virtual table interface
|
|
type sqlite3_vtab1 = struct {
|
|
pModule uintptr
|
|
nRef int32
|
|
_ [4]byte
|
|
zErrMsg uintptr
|
|
} /* sqlite3.h:6754:9 */
|
|
|
|
// The interface to the virtual-table mechanism is currently considered
|
|
// to be experimental. The interface might change in incompatible ways.
|
|
// If this is a problem for you, do not use the interface at this time.
|
|
//
|
|
// When the virtual-table mechanism stabilizes, we will declare the
|
|
// interface fixed, support it indefinitely, and remove this comment.
|
|
|
|
// Structures used by the virtual table interface
|
|
type sqlite3_vtab = sqlite3_vtab1 /* sqlite3.h:6754:29 */
|
|
type sqlite3_index_info1 = struct {
|
|
nConstraint int32
|
|
_ [4]byte
|
|
aConstraint uintptr
|
|
nOrderBy int32
|
|
_ [4]byte
|
|
aOrderBy uintptr
|
|
aConstraintUsage uintptr
|
|
idxNum int32
|
|
_ [4]byte
|
|
idxStr uintptr
|
|
needToFreeIdxStr int32
|
|
orderByConsumed int32
|
|
estimatedCost float64
|
|
estimatedRows sqlite3_int64
|
|
idxFlags int32
|
|
_ [4]byte
|
|
colUsed sqlite3_uint64
|
|
} /* sqlite3.h:6755:9 */
|
|
|
|
type sqlite3_index_info = sqlite3_index_info1 /* sqlite3.h:6755:35 */
|
|
type sqlite3_vtab_cursor1 = struct{ pVtab uintptr } /* sqlite3.h:6756:9 */
|
|
|
|
type sqlite3_vtab_cursor = sqlite3_vtab_cursor1 /* sqlite3.h:6756:36 */
|
|
type sqlite3_module1 = struct {
|
|
iVersion int32
|
|
_ [4]byte
|
|
xCreate uintptr
|
|
xConnect uintptr
|
|
xBestIndex uintptr
|
|
xDisconnect uintptr
|
|
xDestroy uintptr
|
|
xOpen uintptr
|
|
xClose uintptr
|
|
xFilter uintptr
|
|
xNext uintptr
|
|
xEof uintptr
|
|
xColumn uintptr
|
|
xRowid uintptr
|
|
xUpdate uintptr
|
|
xBegin uintptr
|
|
xSync uintptr
|
|
xCommit uintptr
|
|
xRollback uintptr
|
|
xFindFunction uintptr
|
|
xRename uintptr
|
|
xSavepoint uintptr
|
|
xRelease uintptr
|
|
xRollbackTo uintptr
|
|
xShadowName uintptr
|
|
} /* sqlite3.h:6754:9 */
|
|
|
|
type sqlite3_module = sqlite3_module1 /* sqlite3.h:6757:31 */
|
|
|
|
// CAPI3REF: Virtual Table Indexing Information
|
|
// KEYWORDS: sqlite3_index_info
|
|
//
|
|
// The sqlite3_index_info structure and its substructures is used as part
|
|
// of the [virtual table] interface to
|
|
// pass information into and receive the reply from the [xBestIndex]
|
|
// method of a [virtual table module]. The fields under **Inputs** are the
|
|
// inputs to xBestIndex and are read-only. xBestIndex inserts its
|
|
// results into the **Outputs** fields.
|
|
//
|
|
// ^(The aConstraint[] array records WHERE clause constraints of the form:
|
|
//
|
|
// <blockquote>column OP expr</blockquote>
|
|
//
|
|
// where OP is =, <, <=, >, or >=.)^ ^(The particular operator is
|
|
// stored in aConstraint[].op using one of the
|
|
// [SQLITE_INDEX_CONSTRAINT_EQ | SQLITE_INDEX_CONSTRAINT_ values].)^
|
|
// ^(The index of the column is stored in
|
|
// aConstraint[].iColumn.)^ ^(aConstraint[].usable is TRUE if the
|
|
// expr on the right-hand side can be evaluated (and thus the constraint
|
|
// is usable) and false if it cannot.)^
|
|
//
|
|
// ^The optimizer automatically inverts terms of the form "expr OP column"
|
|
// and makes other simplifications to the WHERE clause in an attempt to
|
|
// get as many WHERE clause terms into the form shown above as possible.
|
|
// ^The aConstraint[] array only reports WHERE clause terms that are
|
|
// relevant to the particular virtual table being queried.
|
|
//
|
|
// ^Information about the ORDER BY clause is stored in aOrderBy[].
|
|
// ^Each term of aOrderBy records a column of the ORDER BY clause.
|
|
//
|
|
// The colUsed field indicates which columns of the virtual table may be
|
|
// required by the current scan. Virtual table columns are numbered from
|
|
// zero in the order in which they appear within the CREATE TABLE statement
|
|
// passed to sqlite3_declare_vtab(). For the first 63 columns (columns 0-62),
|
|
// the corresponding bit is set within the colUsed mask if the column may be
|
|
// required by SQLite. If the table has at least 64 columns and any column
|
|
// to the right of the first 63 is required, then bit 63 of colUsed is also
|
|
// set. In other words, column iCol may be required if the expression
|
|
// (colUsed & ((sqlite3_uint64)1 << (iCol>=63 ? 63 : iCol))) evaluates to
|
|
// non-zero.
|
|
//
|
|
// The [xBestIndex] method must fill aConstraintUsage[] with information
|
|
// about what parameters to pass to xFilter. ^If argvIndex>0 then
|
|
// the right-hand side of the corresponding aConstraint[] is evaluated
|
|
// and becomes the argvIndex-th entry in argv. ^(If aConstraintUsage[].omit
|
|
// is true, then the constraint is assumed to be fully handled by the
|
|
// virtual table and might not be checked again by the byte code.)^ ^(The
|
|
// aConstraintUsage[].omit flag is an optimization hint. When the omit flag
|
|
// is left in its default setting of false, the constraint will always be
|
|
// checked separately in byte code. If the omit flag is change to true, then
|
|
// the constraint may or may not be checked in byte code. In other words,
|
|
// when the omit flag is true there is no guarantee that the constraint will
|
|
// not be checked again using byte code.)^
|
|
//
|
|
// ^The idxNum and idxPtr values are recorded and passed into the
|
|
// [xFilter] method.
|
|
// ^[sqlite3_free()] is used to free idxPtr if and only if
|
|
// needToFreeIdxPtr is true.
|
|
//
|
|
// ^The orderByConsumed means that output from [xFilter]/[xNext] will occur in
|
|
// the correct order to satisfy the ORDER BY clause so that no separate
|
|
// sorting step is required.
|
|
//
|
|
// ^The estimatedCost value is an estimate of the cost of a particular
|
|
// strategy. A cost of N indicates that the cost of the strategy is similar
|
|
// to a linear scan of an SQLite table with N rows. A cost of log(N)
|
|
// indicates that the expense of the operation is similar to that of a
|
|
// binary search on a unique indexed field of an SQLite table with N rows.
|
|
//
|
|
// ^The estimatedRows value is an estimate of the number of rows that
|
|
// will be returned by the strategy.
|
|
//
|
|
// The xBestIndex method may optionally populate the idxFlags field with a
|
|
// mask of SQLITE_INDEX_SCAN_* flags. Currently there is only one such flag -
|
|
// SQLITE_INDEX_SCAN_UNIQUE. If the xBestIndex method sets this flag, SQLite
|
|
// assumes that the strategy may visit at most one row.
|
|
//
|
|
// Additionally, if xBestIndex sets the SQLITE_INDEX_SCAN_UNIQUE flag, then
|
|
// SQLite also assumes that if a call to the xUpdate() method is made as
|
|
// part of the same statement to delete or update a virtual table row and the
|
|
// implementation returns SQLITE_CONSTRAINT, then there is no need to rollback
|
|
// any database changes. In other words, if the xUpdate() returns
|
|
// SQLITE_CONSTRAINT, the database contents must be exactly as they were
|
|
// before xUpdate was called. By contrast, if SQLITE_INDEX_SCAN_UNIQUE is not
|
|
// set and xUpdate returns SQLITE_CONSTRAINT, any database changes made by
|
|
// the xUpdate method are automatically rolled back by SQLite.
|
|
//
|
|
// IMPORTANT: The estimatedRows field was added to the sqlite3_index_info
|
|
// structure for SQLite [version 3.8.2] ([dateof:3.8.2]).
|
|
// If a virtual table extension is
|
|
// used with an SQLite version earlier than 3.8.2, the results of attempting
|
|
// to read or write the estimatedRows field are undefined (but are likely
|
|
// to include crashing the application). The estimatedRows field should
|
|
// therefore only be used if [sqlite3_libversion_number()] returns a
|
|
// value greater than or equal to 3008002. Similarly, the idxFlags field
|
|
// was added for [version 3.9.0] ([dateof:3.9.0]).
|
|
// It may therefore only be used if
|
|
// sqlite3_libversion_number() returns a value greater than or equal to
|
|
// 3009000.
|
|
type sqlite3_index_constraint = struct {
|
|
iColumn int32
|
|
op uint8
|
|
usable uint8
|
|
_ [2]byte
|
|
iTermOffset int32
|
|
} /* sqlite3.h:6755:9 */
|
|
|
|
// CAPI3REF: Virtual Table Indexing Information
|
|
// KEYWORDS: sqlite3_index_info
|
|
//
|
|
// The sqlite3_index_info structure and its substructures is used as part
|
|
// of the [virtual table] interface to
|
|
// pass information into and receive the reply from the [xBestIndex]
|
|
// method of a [virtual table module]. The fields under **Inputs** are the
|
|
// inputs to xBestIndex and are read-only. xBestIndex inserts its
|
|
// results into the **Outputs** fields.
|
|
//
|
|
// ^(The aConstraint[] array records WHERE clause constraints of the form:
|
|
//
|
|
// <blockquote>column OP expr</blockquote>
|
|
//
|
|
// where OP is =, <, <=, >, or >=.)^ ^(The particular operator is
|
|
// stored in aConstraint[].op using one of the
|
|
// [SQLITE_INDEX_CONSTRAINT_EQ | SQLITE_INDEX_CONSTRAINT_ values].)^
|
|
// ^(The index of the column is stored in
|
|
// aConstraint[].iColumn.)^ ^(aConstraint[].usable is TRUE if the
|
|
// expr on the right-hand side can be evaluated (and thus the constraint
|
|
// is usable) and false if it cannot.)^
|
|
//
|
|
// ^The optimizer automatically inverts terms of the form "expr OP column"
|
|
// and makes other simplifications to the WHERE clause in an attempt to
|
|
// get as many WHERE clause terms into the form shown above as possible.
|
|
// ^The aConstraint[] array only reports WHERE clause terms that are
|
|
// relevant to the particular virtual table being queried.
|
|
//
|
|
// ^Information about the ORDER BY clause is stored in aOrderBy[].
|
|
// ^Each term of aOrderBy records a column of the ORDER BY clause.
|
|
//
|
|
// The colUsed field indicates which columns of the virtual table may be
|
|
// required by the current scan. Virtual table columns are numbered from
|
|
// zero in the order in which they appear within the CREATE TABLE statement
|
|
// passed to sqlite3_declare_vtab(). For the first 63 columns (columns 0-62),
|
|
// the corresponding bit is set within the colUsed mask if the column may be
|
|
// required by SQLite. If the table has at least 64 columns and any column
|
|
// to the right of the first 63 is required, then bit 63 of colUsed is also
|
|
// set. In other words, column iCol may be required if the expression
|
|
// (colUsed & ((sqlite3_uint64)1 << (iCol>=63 ? 63 : iCol))) evaluates to
|
|
// non-zero.
|
|
//
|
|
// The [xBestIndex] method must fill aConstraintUsage[] with information
|
|
// about what parameters to pass to xFilter. ^If argvIndex>0 then
|
|
// the right-hand side of the corresponding aConstraint[] is evaluated
|
|
// and becomes the argvIndex-th entry in argv. ^(If aConstraintUsage[].omit
|
|
// is true, then the constraint is assumed to be fully handled by the
|
|
// virtual table and might not be checked again by the byte code.)^ ^(The
|
|
// aConstraintUsage[].omit flag is an optimization hint. When the omit flag
|
|
// is left in its default setting of false, the constraint will always be
|
|
// checked separately in byte code. If the omit flag is change to true, then
|
|
// the constraint may or may not be checked in byte code. In other words,
|
|
// when the omit flag is true there is no guarantee that the constraint will
|
|
// not be checked again using byte code.)^
|
|
//
|
|
// ^The idxNum and idxPtr values are recorded and passed into the
|
|
// [xFilter] method.
|
|
// ^[sqlite3_free()] is used to free idxPtr if and only if
|
|
// needToFreeIdxPtr is true.
|
|
//
|
|
// ^The orderByConsumed means that output from [xFilter]/[xNext] will occur in
|
|
// the correct order to satisfy the ORDER BY clause so that no separate
|
|
// sorting step is required.
|
|
//
|
|
// ^The estimatedCost value is an estimate of the cost of a particular
|
|
// strategy. A cost of N indicates that the cost of the strategy is similar
|
|
// to a linear scan of an SQLite table with N rows. A cost of log(N)
|
|
// indicates that the expense of the operation is similar to that of a
|
|
// binary search on a unique indexed field of an SQLite table with N rows.
|
|
//
|
|
// ^The estimatedRows value is an estimate of the number of rows that
|
|
// will be returned by the strategy.
|
|
//
|
|
// The xBestIndex method may optionally populate the idxFlags field with a
|
|
// mask of SQLITE_INDEX_SCAN_* flags. Currently there is only one such flag -
|
|
// SQLITE_INDEX_SCAN_UNIQUE. If the xBestIndex method sets this flag, SQLite
|
|
// assumes that the strategy may visit at most one row.
|
|
//
|
|
// Additionally, if xBestIndex sets the SQLITE_INDEX_SCAN_UNIQUE flag, then
|
|
// SQLite also assumes that if a call to the xUpdate() method is made as
|
|
// part of the same statement to delete or update a virtual table row and the
|
|
// implementation returns SQLITE_CONSTRAINT, then there is no need to rollback
|
|
// any database changes. In other words, if the xUpdate() returns
|
|
// SQLITE_CONSTRAINT, the database contents must be exactly as they were
|
|
// before xUpdate was called. By contrast, if SQLITE_INDEX_SCAN_UNIQUE is not
|
|
// set and xUpdate returns SQLITE_CONSTRAINT, any database changes made by
|
|
// the xUpdate method are automatically rolled back by SQLite.
|
|
//
|
|
// IMPORTANT: The estimatedRows field was added to the sqlite3_index_info
|
|
// structure for SQLite [version 3.8.2] ([dateof:3.8.2]).
|
|
// If a virtual table extension is
|
|
// used with an SQLite version earlier than 3.8.2, the results of attempting
|
|
// to read or write the estimatedRows field are undefined (but are likely
|
|
// to include crashing the application). The estimatedRows field should
|
|
// therefore only be used if [sqlite3_libversion_number()] returns a
|
|
// value greater than or equal to 3008002. Similarly, the idxFlags field
|
|
// was added for [version 3.9.0] ([dateof:3.9.0]).
|
|
// It may therefore only be used if
|
|
// sqlite3_libversion_number() returns a value greater than or equal to
|
|
// 3009000.
|
|
type sqlite3_index_orderby = struct {
|
|
iColumn int32
|
|
desc uint8
|
|
_ [3]byte
|
|
} /* sqlite3.h:6755:9 */
|
|
|
|
// CAPI3REF: Virtual Table Indexing Information
|
|
// KEYWORDS: sqlite3_index_info
|
|
//
|
|
// The sqlite3_index_info structure and its substructures is used as part
|
|
// of the [virtual table] interface to
|
|
// pass information into and receive the reply from the [xBestIndex]
|
|
// method of a [virtual table module]. The fields under **Inputs** are the
|
|
// inputs to xBestIndex and are read-only. xBestIndex inserts its
|
|
// results into the **Outputs** fields.
|
|
//
|
|
// ^(The aConstraint[] array records WHERE clause constraints of the form:
|
|
//
|
|
// <blockquote>column OP expr</blockquote>
|
|
//
|
|
// where OP is =, <, <=, >, or >=.)^ ^(The particular operator is
|
|
// stored in aConstraint[].op using one of the
|
|
// [SQLITE_INDEX_CONSTRAINT_EQ | SQLITE_INDEX_CONSTRAINT_ values].)^
|
|
// ^(The index of the column is stored in
|
|
// aConstraint[].iColumn.)^ ^(aConstraint[].usable is TRUE if the
|
|
// expr on the right-hand side can be evaluated (and thus the constraint
|
|
// is usable) and false if it cannot.)^
|
|
//
|
|
// ^The optimizer automatically inverts terms of the form "expr OP column"
|
|
// and makes other simplifications to the WHERE clause in an attempt to
|
|
// get as many WHERE clause terms into the form shown above as possible.
|
|
// ^The aConstraint[] array only reports WHERE clause terms that are
|
|
// relevant to the particular virtual table being queried.
|
|
//
|
|
// ^Information about the ORDER BY clause is stored in aOrderBy[].
|
|
// ^Each term of aOrderBy records a column of the ORDER BY clause.
|
|
//
|
|
// The colUsed field indicates which columns of the virtual table may be
|
|
// required by the current scan. Virtual table columns are numbered from
|
|
// zero in the order in which they appear within the CREATE TABLE statement
|
|
// passed to sqlite3_declare_vtab(). For the first 63 columns (columns 0-62),
|
|
// the corresponding bit is set within the colUsed mask if the column may be
|
|
// required by SQLite. If the table has at least 64 columns and any column
|
|
// to the right of the first 63 is required, then bit 63 of colUsed is also
|
|
// set. In other words, column iCol may be required if the expression
|
|
// (colUsed & ((sqlite3_uint64)1 << (iCol>=63 ? 63 : iCol))) evaluates to
|
|
// non-zero.
|
|
//
|
|
// The [xBestIndex] method must fill aConstraintUsage[] with information
|
|
// about what parameters to pass to xFilter. ^If argvIndex>0 then
|
|
// the right-hand side of the corresponding aConstraint[] is evaluated
|
|
// and becomes the argvIndex-th entry in argv. ^(If aConstraintUsage[].omit
|
|
// is true, then the constraint is assumed to be fully handled by the
|
|
// virtual table and might not be checked again by the byte code.)^ ^(The
|
|
// aConstraintUsage[].omit flag is an optimization hint. When the omit flag
|
|
// is left in its default setting of false, the constraint will always be
|
|
// checked separately in byte code. If the omit flag is change to true, then
|
|
// the constraint may or may not be checked in byte code. In other words,
|
|
// when the omit flag is true there is no guarantee that the constraint will
|
|
// not be checked again using byte code.)^
|
|
//
|
|
// ^The idxNum and idxPtr values are recorded and passed into the
|
|
// [xFilter] method.
|
|
// ^[sqlite3_free()] is used to free idxPtr if and only if
|
|
// needToFreeIdxPtr is true.
|
|
//
|
|
// ^The orderByConsumed means that output from [xFilter]/[xNext] will occur in
|
|
// the correct order to satisfy the ORDER BY clause so that no separate
|
|
// sorting step is required.
|
|
//
|
|
// ^The estimatedCost value is an estimate of the cost of a particular
|
|
// strategy. A cost of N indicates that the cost of the strategy is similar
|
|
// to a linear scan of an SQLite table with N rows. A cost of log(N)
|
|
// indicates that the expense of the operation is similar to that of a
|
|
// binary search on a unique indexed field of an SQLite table with N rows.
|
|
//
|
|
// ^The estimatedRows value is an estimate of the number of rows that
|
|
// will be returned by the strategy.
|
|
//
|
|
// The xBestIndex method may optionally populate the idxFlags field with a
|
|
// mask of SQLITE_INDEX_SCAN_* flags. Currently there is only one such flag -
|
|
// SQLITE_INDEX_SCAN_UNIQUE. If the xBestIndex method sets this flag, SQLite
|
|
// assumes that the strategy may visit at most one row.
|
|
//
|
|
// Additionally, if xBestIndex sets the SQLITE_INDEX_SCAN_UNIQUE flag, then
|
|
// SQLite also assumes that if a call to the xUpdate() method is made as
|
|
// part of the same statement to delete or update a virtual table row and the
|
|
// implementation returns SQLITE_CONSTRAINT, then there is no need to rollback
|
|
// any database changes. In other words, if the xUpdate() returns
|
|
// SQLITE_CONSTRAINT, the database contents must be exactly as they were
|
|
// before xUpdate was called. By contrast, if SQLITE_INDEX_SCAN_UNIQUE is not
|
|
// set and xUpdate returns SQLITE_CONSTRAINT, any database changes made by
|
|
// the xUpdate method are automatically rolled back by SQLite.
|
|
//
|
|
// IMPORTANT: The estimatedRows field was added to the sqlite3_index_info
|
|
// structure for SQLite [version 3.8.2] ([dateof:3.8.2]).
|
|
// If a virtual table extension is
|
|
// used with an SQLite version earlier than 3.8.2, the results of attempting
|
|
// to read or write the estimatedRows field are undefined (but are likely
|
|
// to include crashing the application). The estimatedRows field should
|
|
// therefore only be used if [sqlite3_libversion_number()] returns a
|
|
// value greater than or equal to 3008002. Similarly, the idxFlags field
|
|
// was added for [version 3.9.0] ([dateof:3.9.0]).
|
|
// It may therefore only be used if
|
|
// sqlite3_libversion_number() returns a value greater than or equal to
|
|
// 3009000.
|
|
type sqlite3_index_constraint_usage = struct {
|
|
argvIndex int32
|
|
omit uint8
|
|
_ [3]byte
|
|
} /* sqlite3.h:6755:9 */
|
|
|
|
// CAPI3REF: Mutex Methods Object
|
|
//
|
|
// An instance of this structure defines the low-level routines
|
|
// used to allocate and use mutexes.
|
|
//
|
|
// Usually, the default mutex implementations provided by SQLite are
|
|
// sufficient, however the application has the option of substituting a custom
|
|
// implementation for specialized deployments or systems for which SQLite
|
|
// does not provide a suitable implementation. In this case, the application
|
|
// creates and populates an instance of this structure to pass
|
|
// to sqlite3_config() along with the [SQLITE_CONFIG_MUTEX] option.
|
|
// Additionally, an instance of this structure can be used as an
|
|
// output variable when querying the system for the current mutex
|
|
// implementation, using the [SQLITE_CONFIG_GETMUTEX] option.
|
|
//
|
|
// ^The xMutexInit method defined by this structure is invoked as
|
|
// part of system initialization by the sqlite3_initialize() function.
|
|
// ^The xMutexInit routine is called by SQLite exactly once for each
|
|
// effective call to [sqlite3_initialize()].
|
|
//
|
|
// ^The xMutexEnd method defined by this structure is invoked as
|
|
// part of system shutdown by the sqlite3_shutdown() function. The
|
|
// implementation of this method is expected to release all outstanding
|
|
// resources obtained by the mutex methods implementation, especially
|
|
// those obtained by the xMutexInit method. ^The xMutexEnd()
|
|
// interface is invoked exactly once for each call to [sqlite3_shutdown()].
|
|
//
|
|
// ^(The remaining seven methods defined by this structure (xMutexAlloc,
|
|
// xMutexFree, xMutexEnter, xMutexTry, xMutexLeave, xMutexHeld and
|
|
// xMutexNotheld) implement the following interfaces (respectively):
|
|
//
|
|
// <ul>
|
|
// <li> [sqlite3_mutex_alloc()] </li>
|
|
// <li> [sqlite3_mutex_free()] </li>
|
|
// <li> [sqlite3_mutex_enter()] </li>
|
|
// <li> [sqlite3_mutex_try()] </li>
|
|
// <li> [sqlite3_mutex_leave()] </li>
|
|
// <li> [sqlite3_mutex_held()] </li>
|
|
// <li> [sqlite3_mutex_notheld()] </li>
|
|
// </ul>)^
|
|
//
|
|
// The only difference is that the public sqlite3_XXX functions enumerated
|
|
// above silently ignore any invocations that pass a NULL pointer instead
|
|
// of a valid mutex handle. The implementations of the methods defined
|
|
// by this structure are not required to handle this case. The results
|
|
// of passing a NULL pointer instead of a valid mutex handle are undefined
|
|
// (i.e. it is acceptable to provide an implementation that segfaults if
|
|
// it is passed a NULL pointer).
|
|
//
|
|
// The xMutexInit() method must be threadsafe. It must be harmless to
|
|
// invoke xMutexInit() multiple times within the same process and without
|
|
// intervening calls to xMutexEnd(). Second and subsequent calls to
|
|
// xMutexInit() must be no-ops.
|
|
//
|
|
// xMutexInit() must not use SQLite memory allocation ([sqlite3_malloc()]
|
|
// and its associates). Similarly, xMutexAlloc() must not use SQLite memory
|
|
// allocation for a static mutex. ^However xMutexAlloc() may use SQLite
|
|
// memory allocation for a fast or recursive mutex.
|
|
//
|
|
// ^SQLite will invoke the xMutexEnd() method when [sqlite3_shutdown()] is
|
|
// called, but only if the prior call to xMutexInit returned SQLITE_OK.
|
|
// If xMutexInit fails in any way, it is expected to clean up after itself
|
|
// prior to returning.
|
|
type sqlite3_mutex_methods1 = struct {
|
|
xMutexInit uintptr
|
|
xMutexEnd uintptr
|
|
xMutexAlloc uintptr
|
|
xMutexFree uintptr
|
|
xMutexEnter uintptr
|
|
xMutexTry uintptr
|
|
xMutexLeave uintptr
|
|
xMutexHeld uintptr
|
|
xMutexNotheld uintptr
|
|
} /* sqlite3.h:7589:9 */
|
|
|
|
// CAPI3REF: Mutex Methods Object
|
|
//
|
|
// An instance of this structure defines the low-level routines
|
|
// used to allocate and use mutexes.
|
|
//
|
|
// Usually, the default mutex implementations provided by SQLite are
|
|
// sufficient, however the application has the option of substituting a custom
|
|
// implementation for specialized deployments or systems for which SQLite
|
|
// does not provide a suitable implementation. In this case, the application
|
|
// creates and populates an instance of this structure to pass
|
|
// to sqlite3_config() along with the [SQLITE_CONFIG_MUTEX] option.
|
|
// Additionally, an instance of this structure can be used as an
|
|
// output variable when querying the system for the current mutex
|
|
// implementation, using the [SQLITE_CONFIG_GETMUTEX] option.
|
|
//
|
|
// ^The xMutexInit method defined by this structure is invoked as
|
|
// part of system initialization by the sqlite3_initialize() function.
|
|
// ^The xMutexInit routine is called by SQLite exactly once for each
|
|
// effective call to [sqlite3_initialize()].
|
|
//
|
|
// ^The xMutexEnd method defined by this structure is invoked as
|
|
// part of system shutdown by the sqlite3_shutdown() function. The
|
|
// implementation of this method is expected to release all outstanding
|
|
// resources obtained by the mutex methods implementation, especially
|
|
// those obtained by the xMutexInit method. ^The xMutexEnd()
|
|
// interface is invoked exactly once for each call to [sqlite3_shutdown()].
|
|
//
|
|
// ^(The remaining seven methods defined by this structure (xMutexAlloc,
|
|
// xMutexFree, xMutexEnter, xMutexTry, xMutexLeave, xMutexHeld and
|
|
// xMutexNotheld) implement the following interfaces (respectively):
|
|
//
|
|
// <ul>
|
|
// <li> [sqlite3_mutex_alloc()] </li>
|
|
// <li> [sqlite3_mutex_free()] </li>
|
|
// <li> [sqlite3_mutex_enter()] </li>
|
|
// <li> [sqlite3_mutex_try()] </li>
|
|
// <li> [sqlite3_mutex_leave()] </li>
|
|
// <li> [sqlite3_mutex_held()] </li>
|
|
// <li> [sqlite3_mutex_notheld()] </li>
|
|
// </ul>)^
|
|
//
|
|
// The only difference is that the public sqlite3_XXX functions enumerated
|
|
// above silently ignore any invocations that pass a NULL pointer instead
|
|
// of a valid mutex handle. The implementations of the methods defined
|
|
// by this structure are not required to handle this case. The results
|
|
// of passing a NULL pointer instead of a valid mutex handle are undefined
|
|
// (i.e. it is acceptable to provide an implementation that segfaults if
|
|
// it is passed a NULL pointer).
|
|
//
|
|
// The xMutexInit() method must be threadsafe. It must be harmless to
|
|
// invoke xMutexInit() multiple times within the same process and without
|
|
// intervening calls to xMutexEnd(). Second and subsequent calls to
|
|
// xMutexInit() must be no-ops.
|
|
//
|
|
// xMutexInit() must not use SQLite memory allocation ([sqlite3_malloc()]
|
|
// and its associates). Similarly, xMutexAlloc() must not use SQLite memory
|
|
// allocation for a static mutex. ^However xMutexAlloc() may use SQLite
|
|
// memory allocation for a fast or recursive mutex.
|
|
//
|
|
// ^SQLite will invoke the xMutexEnd() method when [sqlite3_shutdown()] is
|
|
// called, but only if the prior call to xMutexInit returned SQLITE_OK.
|
|
// If xMutexInit fails in any way, it is expected to clean up after itself
|
|
// prior to returning.
|
|
type sqlite3_mutex_methods = sqlite3_mutex_methods1 /* sqlite3.h:7589:38 */
|
|
|
|
// CAPI3REF: Custom Page Cache Object
|
|
//
|
|
// The sqlite3_pcache_page object represents a single page in the
|
|
// page cache. The page cache will allocate instances of this
|
|
// object. Various methods of the page cache use pointers to instances
|
|
// of this object as parameters or as their return value.
|
|
//
|
|
// See [sqlite3_pcache_methods2] for additional information.
|
|
type sqlite3_pcache_page1 = struct {
|
|
pBuf uintptr
|
|
pExtra uintptr
|
|
} /* sqlite3.h:8344:9 */
|
|
|
|
// CAPI3REF: Custom Page Cache Object
|
|
//
|
|
// The sqlite3_pcache_page object represents a single page in the
|
|
// page cache. The page cache will allocate instances of this
|
|
// object. Various methods of the page cache use pointers to instances
|
|
// of this object as parameters or as their return value.
|
|
//
|
|
// See [sqlite3_pcache_methods2] for additional information.
|
|
type sqlite3_pcache_page = sqlite3_pcache_page1 /* sqlite3.h:8344:36 */
|
|
|
|
// CAPI3REF: Application Defined Page Cache.
|
|
// KEYWORDS: {page cache}
|
|
//
|
|
// ^(The [sqlite3_config]([SQLITE_CONFIG_PCACHE2], ...) interface can
|
|
// register an alternative page cache implementation by passing in an
|
|
// instance of the sqlite3_pcache_methods2 structure.)^
|
|
// In many applications, most of the heap memory allocated by
|
|
// SQLite is used for the page cache.
|
|
// By implementing a
|
|
// custom page cache using this API, an application can better control
|
|
// the amount of memory consumed by SQLite, the way in which
|
|
// that memory is allocated and released, and the policies used to
|
|
// determine exactly which parts of a database file are cached and for
|
|
// how long.
|
|
//
|
|
// The alternative page cache mechanism is an
|
|
// extreme measure that is only needed by the most demanding applications.
|
|
// The built-in page cache is recommended for most uses.
|
|
//
|
|
// ^(The contents of the sqlite3_pcache_methods2 structure are copied to an
|
|
// internal buffer by SQLite within the call to [sqlite3_config]. Hence
|
|
// the application may discard the parameter after the call to
|
|
// [sqlite3_config()] returns.)^
|
|
//
|
|
// [[the xInit() page cache method]]
|
|
// ^(The xInit() method is called once for each effective
|
|
// call to [sqlite3_initialize()])^
|
|
// (usually only once during the lifetime of the process). ^(The xInit()
|
|
// method is passed a copy of the sqlite3_pcache_methods2.pArg value.)^
|
|
// The intent of the xInit() method is to set up global data structures
|
|
// required by the custom page cache implementation.
|
|
// ^(If the xInit() method is NULL, then the
|
|
// built-in default page cache is used instead of the application defined
|
|
// page cache.)^
|
|
//
|
|
// [[the xShutdown() page cache method]]
|
|
// ^The xShutdown() method is called by [sqlite3_shutdown()].
|
|
// It can be used to clean up
|
|
// any outstanding resources before process shutdown, if required.
|
|
// ^The xShutdown() method may be NULL.
|
|
//
|
|
// ^SQLite automatically serializes calls to the xInit method,
|
|
// so the xInit method need not be threadsafe. ^The
|
|
// xShutdown method is only called from [sqlite3_shutdown()] so it does
|
|
// not need to be threadsafe either. All other methods must be threadsafe
|
|
// in multithreaded applications.
|
|
//
|
|
// ^SQLite will never invoke xInit() more than once without an intervening
|
|
// call to xShutdown().
|
|
//
|
|
// [[the xCreate() page cache methods]]
|
|
// ^SQLite invokes the xCreate() method to construct a new cache instance.
|
|
// SQLite will typically create one cache instance for each open database file,
|
|
// though this is not guaranteed. ^The
|
|
// first parameter, szPage, is the size in bytes of the pages that must
|
|
// be allocated by the cache. ^szPage will always a power of two. ^The
|
|
// second parameter szExtra is a number of bytes of extra storage
|
|
// associated with each page cache entry. ^The szExtra parameter will
|
|
// a number less than 250. SQLite will use the
|
|
// extra szExtra bytes on each page to store metadata about the underlying
|
|
// database page on disk. The value passed into szExtra depends
|
|
// on the SQLite version, the target platform, and how SQLite was compiled.
|
|
// ^The third argument to xCreate(), bPurgeable, is true if the cache being
|
|
// created will be used to cache database pages of a file stored on disk, or
|
|
// false if it is used for an in-memory database. The cache implementation
|
|
// does not have to do anything special based with the value of bPurgeable;
|
|
// it is purely advisory. ^On a cache where bPurgeable is false, SQLite will
|
|
// never invoke xUnpin() except to deliberately delete a page.
|
|
// ^In other words, calls to xUnpin() on a cache with bPurgeable set to
|
|
// false will always have the "discard" flag set to true.
|
|
// ^Hence, a cache created with bPurgeable false will
|
|
// never contain any unpinned pages.
|
|
//
|
|
// [[the xCachesize() page cache method]]
|
|
// ^(The xCachesize() method may be called at any time by SQLite to set the
|
|
// suggested maximum cache-size (number of pages stored by) the cache
|
|
// instance passed as the first argument. This is the value configured using
|
|
// the SQLite "[PRAGMA cache_size]" command.)^ As with the bPurgeable
|
|
// parameter, the implementation is not required to do anything with this
|
|
// value; it is advisory only.
|
|
//
|
|
// [[the xPagecount() page cache methods]]
|
|
// The xPagecount() method must return the number of pages currently
|
|
// stored in the cache, both pinned and unpinned.
|
|
//
|
|
// [[the xFetch() page cache methods]]
|
|
// The xFetch() method locates a page in the cache and returns a pointer to
|
|
// an sqlite3_pcache_page object associated with that page, or a NULL pointer.
|
|
// The pBuf element of the returned sqlite3_pcache_page object will be a
|
|
// pointer to a buffer of szPage bytes used to store the content of a
|
|
// single database page. The pExtra element of sqlite3_pcache_page will be
|
|
// a pointer to the szExtra bytes of extra storage that SQLite has requested
|
|
// for each entry in the page cache.
|
|
//
|
|
// The page to be fetched is determined by the key. ^The minimum key value
|
|
// is 1. After it has been retrieved using xFetch, the page is considered
|
|
// to be "pinned".
|
|
//
|
|
// If the requested page is already in the page cache, then the page cache
|
|
// implementation must return a pointer to the page buffer with its content
|
|
// intact. If the requested page is not already in the cache, then the
|
|
// cache implementation should use the value of the createFlag
|
|
// parameter to help it determined what action to take:
|
|
//
|
|
// <table border=1 width=85% align=center>
|
|
// <tr><th> createFlag <th> Behavior when page is not already in cache
|
|
// <tr><td> 0 <td> Do not allocate a new page. Return NULL.
|
|
// <tr><td> 1 <td> Allocate a new page if it easy and convenient to do so.
|
|
// Otherwise return NULL.
|
|
// <tr><td> 2 <td> Make every effort to allocate a new page. Only return
|
|
// NULL if allocating a new page is effectively impossible.
|
|
// </table>
|
|
//
|
|
// ^(SQLite will normally invoke xFetch() with a createFlag of 0 or 1. SQLite
|
|
// will only use a createFlag of 2 after a prior call with a createFlag of 1
|
|
// failed.)^ In between the xFetch() calls, SQLite may
|
|
// attempt to unpin one or more cache pages by spilling the content of
|
|
// pinned pages to disk and synching the operating system disk cache.
|
|
//
|
|
// [[the xUnpin() page cache method]]
|
|
// ^xUnpin() is called by SQLite with a pointer to a currently pinned page
|
|
// as its second argument. If the third parameter, discard, is non-zero,
|
|
// then the page must be evicted from the cache.
|
|
// ^If the discard parameter is
|
|
// zero, then the page may be discarded or retained at the discretion of
|
|
// page cache implementation. ^The page cache implementation
|
|
// may choose to evict unpinned pages at any time.
|
|
//
|
|
// The cache must not perform any reference counting. A single
|
|
// call to xUnpin() unpins the page regardless of the number of prior calls
|
|
// to xFetch().
|
|
//
|
|
// [[the xRekey() page cache methods]]
|
|
// The xRekey() method is used to change the key value associated with the
|
|
// page passed as the second argument. If the cache
|
|
// previously contains an entry associated with newKey, it must be
|
|
// discarded. ^Any prior cache entry associated with newKey is guaranteed not
|
|
// to be pinned.
|
|
//
|
|
// When SQLite calls the xTruncate() method, the cache must discard all
|
|
// existing cache entries with page numbers (keys) greater than or equal
|
|
// to the value of the iLimit parameter passed to xTruncate(). If any
|
|
// of these pages are pinned, they are implicitly unpinned, meaning that
|
|
// they can be safely discarded.
|
|
//
|
|
// [[the xDestroy() page cache method]]
|
|
// ^The xDestroy() method is used to delete a cache allocated by xCreate().
|
|
// All resources associated with the specified cache should be freed. ^After
|
|
// calling the xDestroy() method, SQLite considers the [sqlite3_pcache*]
|
|
// handle invalid, and will not use it with any other sqlite3_pcache_methods2
|
|
// functions.
|
|
//
|
|
// [[the xShrink() page cache method]]
|
|
// ^SQLite invokes the xShrink() method when it wants the page cache to
|
|
// free up as much of heap memory as possible. The page cache implementation
|
|
// is not obligated to free any memory, but well-behaved implementations should
|
|
// do their best.
|
|
type sqlite3_pcache_methods21 = struct {
|
|
iVersion int32
|
|
_ [4]byte
|
|
pArg uintptr
|
|
xInit uintptr
|
|
xShutdown uintptr
|
|
xCreate uintptr
|
|
xCachesize uintptr
|
|
xPagecount uintptr
|
|
xFetch uintptr
|
|
xUnpin uintptr
|
|
xRekey uintptr
|
|
xTruncate uintptr
|
|
xDestroy uintptr
|
|
xShrink uintptr
|
|
} /* sqlite3.h:8509:9 */
|
|
|
|
// CAPI3REF: Application Defined Page Cache.
|
|
// KEYWORDS: {page cache}
|
|
//
|
|
// ^(The [sqlite3_config]([SQLITE_CONFIG_PCACHE2], ...) interface can
|
|
// register an alternative page cache implementation by passing in an
|
|
// instance of the sqlite3_pcache_methods2 structure.)^
|
|
// In many applications, most of the heap memory allocated by
|
|
// SQLite is used for the page cache.
|
|
// By implementing a
|
|
// custom page cache using this API, an application can better control
|
|
// the amount of memory consumed by SQLite, the way in which
|
|
// that memory is allocated and released, and the policies used to
|
|
// determine exactly which parts of a database file are cached and for
|
|
// how long.
|
|
//
|
|
// The alternative page cache mechanism is an
|
|
// extreme measure that is only needed by the most demanding applications.
|
|
// The built-in page cache is recommended for most uses.
|
|
//
|
|
// ^(The contents of the sqlite3_pcache_methods2 structure are copied to an
|
|
// internal buffer by SQLite within the call to [sqlite3_config]. Hence
|
|
// the application may discard the parameter after the call to
|
|
// [sqlite3_config()] returns.)^
|
|
//
|
|
// [[the xInit() page cache method]]
|
|
// ^(The xInit() method is called once for each effective
|
|
// call to [sqlite3_initialize()])^
|
|
// (usually only once during the lifetime of the process). ^(The xInit()
|
|
// method is passed a copy of the sqlite3_pcache_methods2.pArg value.)^
|
|
// The intent of the xInit() method is to set up global data structures
|
|
// required by the custom page cache implementation.
|
|
// ^(If the xInit() method is NULL, then the
|
|
// built-in default page cache is used instead of the application defined
|
|
// page cache.)^
|
|
//
|
|
// [[the xShutdown() page cache method]]
|
|
// ^The xShutdown() method is called by [sqlite3_shutdown()].
|
|
// It can be used to clean up
|
|
// any outstanding resources before process shutdown, if required.
|
|
// ^The xShutdown() method may be NULL.
|
|
//
|
|
// ^SQLite automatically serializes calls to the xInit method,
|
|
// so the xInit method need not be threadsafe. ^The
|
|
// xShutdown method is only called from [sqlite3_shutdown()] so it does
|
|
// not need to be threadsafe either. All other methods must be threadsafe
|
|
// in multithreaded applications.
|
|
//
|
|
// ^SQLite will never invoke xInit() more than once without an intervening
|
|
// call to xShutdown().
|
|
//
|
|
// [[the xCreate() page cache methods]]
|
|
// ^SQLite invokes the xCreate() method to construct a new cache instance.
|
|
// SQLite will typically create one cache instance for each open database file,
|
|
// though this is not guaranteed. ^The
|
|
// first parameter, szPage, is the size in bytes of the pages that must
|
|
// be allocated by the cache. ^szPage will always a power of two. ^The
|
|
// second parameter szExtra is a number of bytes of extra storage
|
|
// associated with each page cache entry. ^The szExtra parameter will
|
|
// a number less than 250. SQLite will use the
|
|
// extra szExtra bytes on each page to store metadata about the underlying
|
|
// database page on disk. The value passed into szExtra depends
|
|
// on the SQLite version, the target platform, and how SQLite was compiled.
|
|
// ^The third argument to xCreate(), bPurgeable, is true if the cache being
|
|
// created will be used to cache database pages of a file stored on disk, or
|
|
// false if it is used for an in-memory database. The cache implementation
|
|
// does not have to do anything special based with the value of bPurgeable;
|
|
// it is purely advisory. ^On a cache where bPurgeable is false, SQLite will
|
|
// never invoke xUnpin() except to deliberately delete a page.
|
|
// ^In other words, calls to xUnpin() on a cache with bPurgeable set to
|
|
// false will always have the "discard" flag set to true.
|
|
// ^Hence, a cache created with bPurgeable false will
|
|
// never contain any unpinned pages.
|
|
//
|
|
// [[the xCachesize() page cache method]]
|
|
// ^(The xCachesize() method may be called at any time by SQLite to set the
|
|
// suggested maximum cache-size (number of pages stored by) the cache
|
|
// instance passed as the first argument. This is the value configured using
|
|
// the SQLite "[PRAGMA cache_size]" command.)^ As with the bPurgeable
|
|
// parameter, the implementation is not required to do anything with this
|
|
// value; it is advisory only.
|
|
//
|
|
// [[the xPagecount() page cache methods]]
|
|
// The xPagecount() method must return the number of pages currently
|
|
// stored in the cache, both pinned and unpinned.
|
|
//
|
|
// [[the xFetch() page cache methods]]
|
|
// The xFetch() method locates a page in the cache and returns a pointer to
|
|
// an sqlite3_pcache_page object associated with that page, or a NULL pointer.
|
|
// The pBuf element of the returned sqlite3_pcache_page object will be a
|
|
// pointer to a buffer of szPage bytes used to store the content of a
|
|
// single database page. The pExtra element of sqlite3_pcache_page will be
|
|
// a pointer to the szExtra bytes of extra storage that SQLite has requested
|
|
// for each entry in the page cache.
|
|
//
|
|
// The page to be fetched is determined by the key. ^The minimum key value
|
|
// is 1. After it has been retrieved using xFetch, the page is considered
|
|
// to be "pinned".
|
|
//
|
|
// If the requested page is already in the page cache, then the page cache
|
|
// implementation must return a pointer to the page buffer with its content
|
|
// intact. If the requested page is not already in the cache, then the
|
|
// cache implementation should use the value of the createFlag
|
|
// parameter to help it determined what action to take:
|
|
//
|
|
// <table border=1 width=85% align=center>
|
|
// <tr><th> createFlag <th> Behavior when page is not already in cache
|
|
// <tr><td> 0 <td> Do not allocate a new page. Return NULL.
|
|
// <tr><td> 1 <td> Allocate a new page if it easy and convenient to do so.
|
|
// Otherwise return NULL.
|
|
// <tr><td> 2 <td> Make every effort to allocate a new page. Only return
|
|
// NULL if allocating a new page is effectively impossible.
|
|
// </table>
|
|
//
|
|
// ^(SQLite will normally invoke xFetch() with a createFlag of 0 or 1. SQLite
|
|
// will only use a createFlag of 2 after a prior call with a createFlag of 1
|
|
// failed.)^ In between the xFetch() calls, SQLite may
|
|
// attempt to unpin one or more cache pages by spilling the content of
|
|
// pinned pages to disk and synching the operating system disk cache.
|
|
//
|
|
// [[the xUnpin() page cache method]]
|
|
// ^xUnpin() is called by SQLite with a pointer to a currently pinned page
|
|
// as its second argument. If the third parameter, discard, is non-zero,
|
|
// then the page must be evicted from the cache.
|
|
// ^If the discard parameter is
|
|
// zero, then the page may be discarded or retained at the discretion of
|
|
// page cache implementation. ^The page cache implementation
|
|
// may choose to evict unpinned pages at any time.
|
|
//
|
|
// The cache must not perform any reference counting. A single
|
|
// call to xUnpin() unpins the page regardless of the number of prior calls
|
|
// to xFetch().
|
|
//
|
|
// [[the xRekey() page cache methods]]
|
|
// The xRekey() method is used to change the key value associated with the
|
|
// page passed as the second argument. If the cache
|
|
// previously contains an entry associated with newKey, it must be
|
|
// discarded. ^Any prior cache entry associated with newKey is guaranteed not
|
|
// to be pinned.
|
|
//
|
|
// When SQLite calls the xTruncate() method, the cache must discard all
|
|
// existing cache entries with page numbers (keys) greater than or equal
|
|
// to the value of the iLimit parameter passed to xTruncate(). If any
|
|
// of these pages are pinned, they are implicitly unpinned, meaning that
|
|
// they can be safely discarded.
|
|
//
|
|
// [[the xDestroy() page cache method]]
|
|
// ^The xDestroy() method is used to delete a cache allocated by xCreate().
|
|
// All resources associated with the specified cache should be freed. ^After
|
|
// calling the xDestroy() method, SQLite considers the [sqlite3_pcache*]
|
|
// handle invalid, and will not use it with any other sqlite3_pcache_methods2
|
|
// functions.
|
|
//
|
|
// [[the xShrink() page cache method]]
|
|
// ^SQLite invokes the xShrink() method when it wants the page cache to
|
|
// free up as much of heap memory as possible. The page cache implementation
|
|
// is not obligated to free any memory, but well-behaved implementations should
|
|
// do their best.
|
|
type sqlite3_pcache_methods2 = sqlite3_pcache_methods21 /* sqlite3.h:8509:40 */
|
|
|
|
// This is the obsolete pcache_methods object that has now been replaced
|
|
// by sqlite3_pcache_methods2. This object is not used by SQLite. It is
|
|
// retained in the header file for backwards compatibility only.
|
|
type sqlite3_pcache_methods1 = struct {
|
|
pArg uintptr
|
|
xInit uintptr
|
|
xShutdown uintptr
|
|
xCreate uintptr
|
|
xCachesize uintptr
|
|
xPagecount uintptr
|
|
xFetch uintptr
|
|
xUnpin uintptr
|
|
xRekey uintptr
|
|
xTruncate uintptr
|
|
xDestroy uintptr
|
|
} /* sqlite3.h:8532:9 */
|
|
|
|
// This is the obsolete pcache_methods object that has now been replaced
|
|
// by sqlite3_pcache_methods2. This object is not used by SQLite. It is
|
|
// retained in the header file for backwards compatibility only.
|
|
type sqlite3_pcache_methods = sqlite3_pcache_methods1 /* sqlite3.h:8532:39 */
|
|
|
|
// CAPI3REF: Database Snapshot
|
|
// KEYWORDS: {snapshot} {sqlite3_snapshot}
|
|
//
|
|
// An instance of the snapshot object records the state of a [WAL mode]
|
|
// database for some specific point in history.
|
|
//
|
|
// In [WAL mode], multiple [database connections] that are open on the
|
|
// same database file can each be reading a different historical version
|
|
// of the database file. When a [database connection] begins a read
|
|
// transaction, that connection sees an unchanging copy of the database
|
|
// as it existed for the point in time when the transaction first started.
|
|
// Subsequent changes to the database from other connections are not seen
|
|
// by the reader until a new read transaction is started.
|
|
//
|
|
// The sqlite3_snapshot object records state information about an historical
|
|
// version of the database file so that it is possible to later open a new read
|
|
// transaction that sees that historical version of the database rather than
|
|
// the most recent version.
|
|
type sqlite3_snapshot1 = struct{ hidden [48]uint8 } /* sqlite3.h:9589:9 */
|
|
|
|
// CAPI3REF: Database Snapshot
|
|
// KEYWORDS: {snapshot} {sqlite3_snapshot}
|
|
//
|
|
// An instance of the snapshot object records the state of a [WAL mode]
|
|
// database for some specific point in history.
|
|
//
|
|
// In [WAL mode], multiple [database connections] that are open on the
|
|
// same database file can each be reading a different historical version
|
|
// of the database file. When a [database connection] begins a read
|
|
// transaction, that connection sees an unchanging copy of the database
|
|
// as it existed for the point in time when the transaction first started.
|
|
// Subsequent changes to the database from other connections are not seen
|
|
// by the reader until a new read transaction is started.
|
|
//
|
|
// The sqlite3_snapshot object records state information about an historical
|
|
// version of the database file so that it is possible to later open a new read
|
|
// transaction that sees that historical version of the database rather than
|
|
// the most recent version.
|
|
type sqlite3_snapshot = sqlite3_snapshot1 /* sqlite3.h:9591:3 */
|
|
|
|
// CAPI3REF: Flags for sqlite3_deserialize()
|
|
//
|
|
// The following are allowed values for 6th argument (the F argument) to
|
|
// the [sqlite3_deserialize(D,S,P,N,M,F)] interface.
|
|
//
|
|
// The SQLITE_DESERIALIZE_FREEONCLOSE means that the database serialization
|
|
// in the P argument is held in memory obtained from [sqlite3_malloc64()]
|
|
// and that SQLite should take ownership of this memory and automatically
|
|
// free it when it has finished using it. Without this flag, the caller
|
|
// is responsible for freeing any dynamically allocated memory.
|
|
//
|
|
// The SQLITE_DESERIALIZE_RESIZEABLE flag means that SQLite is allowed to
|
|
// grow the size of the database using calls to [sqlite3_realloc64()]. This
|
|
// flag should only be used if SQLITE_DESERIALIZE_FREEONCLOSE is also used.
|
|
// Without this flag, the deserialized database cannot increase in size beyond
|
|
// the number of bytes specified by the M parameter.
|
|
//
|
|
// The SQLITE_DESERIALIZE_READONLY flag means that the deserialized database
|
|
// should be treated as read-only.
|
|
|
|
// Undo the hack that converts floating point types to integer for
|
|
// builds on processors without floating point support.
|
|
|
|
//******* Begin file sqlite3rtree.h ********
|
|
// 2010 August 30
|
|
//
|
|
// The author disclaims copyright to this source code. In place of
|
|
// a legal notice, here is a blessing:
|
|
//
|
|
// May you do good and not evil.
|
|
// May you find forgiveness for yourself and forgive others.
|
|
// May you share freely, never taking more than you give.
|
|
//
|
|
//
|
|
|
|
type sqlite3_rtree_geometry1 = struct {
|
|
pContext uintptr
|
|
nParam int32
|
|
_ [4]byte
|
|
aParam uintptr
|
|
pUser uintptr
|
|
xDelUser uintptr
|
|
} /* sqlite3.h:9916:9 */
|
|
|
|
// CAPI3REF: Flags for sqlite3_deserialize()
|
|
//
|
|
// The following are allowed values for 6th argument (the F argument) to
|
|
// the [sqlite3_deserialize(D,S,P,N,M,F)] interface.
|
|
//
|
|
// The SQLITE_DESERIALIZE_FREEONCLOSE means that the database serialization
|
|
// in the P argument is held in memory obtained from [sqlite3_malloc64()]
|
|
// and that SQLite should take ownership of this memory and automatically
|
|
// free it when it has finished using it. Without this flag, the caller
|
|
// is responsible for freeing any dynamically allocated memory.
|
|
//
|
|
// The SQLITE_DESERIALIZE_RESIZEABLE flag means that SQLite is allowed to
|
|
// grow the size of the database using calls to [sqlite3_realloc64()]. This
|
|
// flag should only be used if SQLITE_DESERIALIZE_FREEONCLOSE is also used.
|
|
// Without this flag, the deserialized database cannot increase in size beyond
|
|
// the number of bytes specified by the M parameter.
|
|
//
|
|
// The SQLITE_DESERIALIZE_READONLY flag means that the deserialized database
|
|
// should be treated as read-only.
|
|
|
|
// Undo the hack that converts floating point types to integer for
|
|
// builds on processors without floating point support.
|
|
|
|
//******* Begin file sqlite3rtree.h ********
|
|
// 2010 August 30
|
|
//
|
|
// The author disclaims copyright to this source code. In place of
|
|
// a legal notice, here is a blessing:
|
|
//
|
|
// May you do good and not evil.
|
|
// May you find forgiveness for yourself and forgive others.
|
|
// May you share freely, never taking more than you give.
|
|
//
|
|
//
|
|
|
|
type sqlite3_rtree_geometry = sqlite3_rtree_geometry1 /* sqlite3.h:9916:39 */
|
|
type sqlite3_rtree_query_info1 = struct {
|
|
pContext uintptr
|
|
nParam int32
|
|
_ [4]byte
|
|
aParam uintptr
|
|
pUser uintptr
|
|
xDelUser uintptr
|
|
aCoord uintptr
|
|
anQueue uintptr
|
|
nCoord int32
|
|
iLevel int32
|
|
mxLevel int32
|
|
_ [4]byte
|
|
iRowid sqlite3_int64
|
|
rParentScore sqlite3_rtree_dbl
|
|
eParentWithin int32
|
|
eWithin int32
|
|
rScore sqlite3_rtree_dbl
|
|
apSqlParam uintptr
|
|
} /* sqlite3.h:9917:9 */
|
|
|
|
type sqlite3_rtree_query_info = sqlite3_rtree_query_info1 /* sqlite3.h:9917:41 */
|
|
|
|
// The double-precision datatype used by RTree depends on the
|
|
// SQLITE_RTREE_INT_ONLY compile-time option.
|
|
type sqlite3_rtree_dbl = float64 /* sqlite3.h:9925:18 */
|
|
|
|
// Allowed values for sqlite3_rtree_query.eWithin and .eParentWithin.
|
|
|
|
//******* End of sqlite3rtree.h ********
|
|
//******* Begin file sqlite3session.h ********
|
|
|
|
//******* End of sqlite3session.h ********
|
|
//******* Begin file fts5.h ********
|
|
// 2014 May 31
|
|
//
|
|
// The author disclaims copyright to this source code. In place of
|
|
// a legal notice, here is a blessing:
|
|
//
|
|
// May you do good and not evil.
|
|
// May you find forgiveness for yourself and forgive others.
|
|
// May you share freely, never taking more than you give.
|
|
//
|
|
//
|
|
//
|
|
// Interfaces to extend FTS5. Using the interfaces defined in this file,
|
|
// FTS5 may be extended with:
|
|
//
|
|
// * custom tokenizers, and
|
|
// * custom auxiliary functions.
|
|
|
|
// ************************************************************************
|
|
//
|
|
// CUSTOM AUXILIARY FUNCTIONS
|
|
//
|
|
// Virtual table implementations may overload SQL functions by implementing
|
|
// the sqlite3_module.xFindFunction() method.
|
|
|
|
type Fts5ExtensionApi1 = struct {
|
|
iVersion int32
|
|
_ [4]byte
|
|
xUserData uintptr
|
|
xColumnCount uintptr
|
|
xRowCount uintptr
|
|
xColumnTotalSize uintptr
|
|
xTokenize uintptr
|
|
xPhraseCount uintptr
|
|
xPhraseSize uintptr
|
|
xInstCount uintptr
|
|
xInst uintptr
|
|
xRowid uintptr
|
|
xColumnText uintptr
|
|
xColumnSize uintptr
|
|
xQueryPhrase uintptr
|
|
xSetAuxdata uintptr
|
|
xGetAuxdata uintptr
|
|
xPhraseFirst uintptr
|
|
xPhraseNext uintptr
|
|
xPhraseFirstColumn uintptr
|
|
xPhraseNextColumn uintptr
|
|
} /* sqlite3.h:11724:9 */
|
|
|
|
// Allowed values for sqlite3_rtree_query.eWithin and .eParentWithin.
|
|
|
|
//******* End of sqlite3rtree.h ********
|
|
//******* Begin file sqlite3session.h ********
|
|
|
|
//******* End of sqlite3session.h ********
|
|
//******* Begin file fts5.h ********
|
|
// 2014 May 31
|
|
//
|
|
// The author disclaims copyright to this source code. In place of
|
|
// a legal notice, here is a blessing:
|
|
//
|
|
// May you do good and not evil.
|
|
// May you find forgiveness for yourself and forgive others.
|
|
// May you share freely, never taking more than you give.
|
|
//
|
|
//
|
|
//
|
|
// Interfaces to extend FTS5. Using the interfaces defined in this file,
|
|
// FTS5 may be extended with:
|
|
//
|
|
// * custom tokenizers, and
|
|
// * custom auxiliary functions.
|
|
|
|
// ************************************************************************
|
|
//
|
|
// CUSTOM AUXILIARY FUNCTIONS
|
|
//
|
|
// Virtual table implementations may overload SQL functions by implementing
|
|
// the sqlite3_module.xFindFunction() method.
|
|
|
|
type Fts5ExtensionApi = Fts5ExtensionApi1 /* sqlite3.h:11724:33 */
|
|
type Fts5PhraseIter1 = struct {
|
|
a uintptr
|
|
b uintptr
|
|
} /* sqlite3.h:11726:9 */
|
|
|
|
type Fts5PhraseIter = Fts5PhraseIter1 /* sqlite3.h:11726:31 */
|
|
|
|
type fts5_extension_function = uintptr /* sqlite3.h:11728:14 */
|
|
type fts5_tokenizer1 = struct {
|
|
xCreate uintptr
|
|
xDelete uintptr
|
|
xTokenize uintptr
|
|
} /* sqlite3.h:12187:9 */
|
|
|
|
type fts5_tokenizer = fts5_tokenizer1 /* sqlite3.h:12187:31 */
|
|
|
|
// Flags that may be passed as the third argument to xTokenize()
|
|
|
|
// Flags that may be passed by the tokenizer implementation back to FTS5
|
|
// as the third argument to the supplied xToken callback.
|
|
|
|
//
|
|
// END OF CUSTOM TOKENIZERS
|
|
//
|
|
|
|
// ************************************************************************
|
|
//
|
|
// FTS5 EXTENSION REGISTRATION API
|
|
type fts5_api1 = struct {
|
|
iVersion int32
|
|
_ [4]byte
|
|
xCreateTokenizer uintptr
|
|
xFindTokenizer uintptr
|
|
xCreateFunction uintptr
|
|
} /* sqlite3.h:12223:9 */
|
|
|
|
// Flags that may be passed as the third argument to xTokenize()
|
|
|
|
// Flags that may be passed by the tokenizer implementation back to FTS5
|
|
// as the third argument to the supplied xToken callback.
|
|
|
|
//
|
|
// END OF CUSTOM TOKENIZERS
|
|
//
|
|
|
|
// ************************************************************************
|
|
//
|
|
// FTS5 EXTENSION REGISTRATION API
|
|
type fts5_api = fts5_api1 /* sqlite3.h:12223:25 */
|
|
|
|
// Copyright (c) 2003-2013 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// pthread opaque structures
|
|
|
|
type __darwin_pthread_handler_rec = struct {
|
|
__routine uintptr
|
|
__arg uintptr
|
|
__next uintptr
|
|
} /* _pthread_types.h:57:1 */
|
|
|
|
type _opaque_pthread_attr_t = struct {
|
|
__sig int64
|
|
__opaque [56]int8
|
|
} /* _pthread_types.h:63:1 */
|
|
|
|
type _opaque_pthread_cond_t = struct {
|
|
__sig int64
|
|
__opaque [40]int8
|
|
} /* _pthread_types.h:68:1 */
|
|
|
|
type _opaque_pthread_condattr_t = struct {
|
|
__sig int64
|
|
__opaque [8]int8
|
|
} /* _pthread_types.h:73:1 */
|
|
|
|
type _opaque_pthread_mutex_t = struct {
|
|
__sig int64
|
|
__opaque [56]int8
|
|
} /* _pthread_types.h:78:1 */
|
|
|
|
type _opaque_pthread_mutexattr_t = struct {
|
|
__sig int64
|
|
__opaque [8]int8
|
|
} /* _pthread_types.h:83:1 */
|
|
|
|
type _opaque_pthread_once_t = struct {
|
|
__sig int64
|
|
__opaque [8]int8
|
|
} /* _pthread_types.h:88:1 */
|
|
|
|
type _opaque_pthread_rwlock_t = struct {
|
|
__sig int64
|
|
__opaque [192]int8
|
|
} /* _pthread_types.h:93:1 */
|
|
|
|
type _opaque_pthread_rwlockattr_t = struct {
|
|
__sig int64
|
|
__opaque [16]int8
|
|
} /* _pthread_types.h:98:1 */
|
|
|
|
type _opaque_pthread_t = struct {
|
|
__sig int64
|
|
__cleanup_stack uintptr
|
|
__opaque [8176]int8
|
|
} /* _pthread_types.h:103:1 */
|
|
|
|
// DO NOT REMOVE THIS COMMENT: fixincludes needs to see:
|
|
// __gnuc_va_list and include <stdarg.h>
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
|
|
// Copyright (c) 2000-2008 Apple Inc. All rights reserved.
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1990, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)types.h 8.3 (Berkeley) 1/5/94
|
|
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Basic integral types. Omit the typedef if
|
|
// not possible for a machine/compiler combination.
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type int8_t = int8 /* _int8_t.h:30:31 */
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type int16_t = int16 /* _int16_t.h:30:33 */
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type int32_t = int32 /* _int32_t.h:30:33 */
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type int64_t = int64 /* _int64_t.h:30:33 */
|
|
|
|
// Copyright (c) 2016 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type u_int8_t = uint8 /* _u_int8_t.h:30:33 */
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type u_int16_t = uint16 /* _u_int16_t.h:30:41 */
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type u_int32_t = uint32 /* _u_int32_t.h:30:33 */
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type u_int64_t = uint64 /* _u_int64_t.h:30:33 */
|
|
|
|
type register_t = int64_t /* types.h:63:33 */
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
|
|
type intptr_t = int64 /* _intptr_t.h:32:33 */
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type uintptr_t = uint64 /* _uintptr_t.h:30:33 */
|
|
|
|
// These types are used for reserving the largest possible size.
|
|
type user_addr_t = u_int64_t /* types.h:74:33 */
|
|
type user_size_t = u_int64_t /* types.h:75:33 */
|
|
type user_ssize_t = int64_t /* types.h:76:33 */
|
|
type user_long_t = int64_t /* types.h:77:33 */
|
|
type user_ulong_t = u_int64_t /* types.h:78:33 */
|
|
type user_time_t = int64_t /* types.h:79:33 */
|
|
type user_off_t = int64_t /* types.h:80:33 */
|
|
|
|
// This defines the size of syscall arguments after copying into the kernel:
|
|
type syscall_arg_t = u_int64_t /* types.h:101:33 */
|
|
|
|
type fpos_t = int64 /* _stdio.h:81:25 */
|
|
|
|
// NB: to fit things in six character monocase externals, the stdio
|
|
// code uses the prefix `__s' for stdio objects, typically followed
|
|
// by a three-character attempt at a mnemonic.
|
|
|
|
// stdio buffers
|
|
type __sbuf = struct {
|
|
_base uintptr
|
|
_size int32
|
|
_ [4]byte
|
|
} /* _stdio.h:92:1 */
|
|
|
|
// stdio state variables.
|
|
//
|
|
// The following always hold:
|
|
//
|
|
// if (_flags&(__SLBF|__SWR)) == (__SLBF|__SWR),
|
|
// _lbfsize is -_bf._size, else _lbfsize is 0
|
|
// if _flags&__SRD, _w is 0
|
|
// if _flags&__SWR, _r is 0
|
|
//
|
|
// This ensures that the getc and putc macros (or inline functions) never
|
|
// try to write or read from a file that is in `read' or `write' mode.
|
|
// (Moreover, they can, and do, automatically switch from read mode to
|
|
// write mode, and back, on "r+" and "w+" files.)
|
|
//
|
|
// _lbfsize is used only to make the inline line-buffered output stream
|
|
// code as compact as possible.
|
|
//
|
|
// _ub, _up, and _ur are used when ungetc() pushes back more characters
|
|
// than fit in the current _bf, or when ungetc() pushes back a character
|
|
// that does not match the previous one in _bf. When this happens,
|
|
// _ub._base becomes non-nil (i.e., a stream has ungetc() data iff
|
|
// _ub._base!=NULL) and _up and _ur save the current values of _p and _r.
|
|
//
|
|
// NB: see WARNING above before changing the layout of this structure!
|
|
type __sFILE = struct {
|
|
_p uintptr
|
|
_r int32
|
|
_w int32
|
|
_flags int16
|
|
_file int16
|
|
_ [4]byte
|
|
_bf struct {
|
|
_base uintptr
|
|
_size int32
|
|
_ [4]byte
|
|
}
|
|
_lbfsize int32
|
|
_ [4]byte
|
|
_cookie uintptr
|
|
_close uintptr
|
|
_read uintptr
|
|
_seek uintptr
|
|
_write uintptr
|
|
_ub struct {
|
|
_base uintptr
|
|
_size int32
|
|
_ [4]byte
|
|
}
|
|
_extra uintptr
|
|
_ur int32
|
|
_ubuf [3]uint8
|
|
_nbuf [1]uint8
|
|
_lb struct {
|
|
_base uintptr
|
|
_size int32
|
|
_ [4]byte
|
|
}
|
|
_blksize int32
|
|
_ [4]byte
|
|
_offset fpos_t
|
|
} /* _stdio.h:126:9 */
|
|
|
|
// stdio state variables.
|
|
//
|
|
// The following always hold:
|
|
//
|
|
// if (_flags&(__SLBF|__SWR)) == (__SLBF|__SWR),
|
|
// _lbfsize is -_bf._size, else _lbfsize is 0
|
|
// if _flags&__SRD, _w is 0
|
|
// if _flags&__SWR, _r is 0
|
|
//
|
|
// This ensures that the getc and putc macros (or inline functions) never
|
|
// try to write or read from a file that is in `read' or `write' mode.
|
|
// (Moreover, they can, and do, automatically switch from read mode to
|
|
// write mode, and back, on "r+" and "w+" files.)
|
|
//
|
|
// _lbfsize is used only to make the inline line-buffered output stream
|
|
// code as compact as possible.
|
|
//
|
|
// _ub, _up, and _ur are used when ungetc() pushes back more characters
|
|
// than fit in the current _bf, or when ungetc() pushes back a character
|
|
// that does not match the previous one in _bf. When this happens,
|
|
// _ub._base becomes non-nil (i.e., a stream has ungetc() data iff
|
|
// _ub._base!=NULL) and _up and _ur save the current values of _p and _r.
|
|
//
|
|
// NB: see WARNING above before changing the layout of this structure!
|
|
type FILE = __sFILE /* _stdio.h:157:3 */
|
|
|
|
// Additional functionality provided by:
|
|
// POSIX.1-2001
|
|
// ISO C99
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type off_t = int64 /* _off_t.h:31:33 */
|
|
|
|
// Additional functionality provided by:
|
|
// POSIX.1-2008
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
type ssize_t = int64 /* _ssize_t.h:31:33 */
|
|
|
|
// Copyright (c) 2000, 2002-2006, 2008-2010, 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
// -
|
|
// Copyright (c) 1998-1999 Apple Computer, Inc. All Rights Reserved
|
|
// Copyright (c) 1991, 1993, 1994
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)unistd.h 8.12 (Berkeley) 4/27/95
|
|
//
|
|
// Copyright (c) 1998 Apple Compter, Inc.
|
|
// All Rights Reserved
|
|
|
|
// History:
|
|
// 7/14/99 EKN at Apple fixed getdirentriesattr from getdirentryattr
|
|
// 3/26/98 CHW at Apple added real interface to searchfs call
|
|
// 3/5/98 CHW at Apple added hfs semantic system calls headers
|
|
|
|
// Copyright (c) 2004, 2008, 2009 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2013 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 1995 NeXT Computer, Inc. All Rights Reserved
|
|
// Copyright (c) 1989, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)unistd.h 8.2 (Berkeley) 1/7/94
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Although we have saved user/group IDs, we do not use them in setuid
|
|
// as described in POSIX 1003.1, because the feature does not work for
|
|
// root. We use the saved IDs in seteuid/setegid, which are not currently
|
|
// part of the POSIX 1003.1 specification.
|
|
|
|
// execution-time symbolic constants
|
|
// may disable terminal special characters
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// access function
|
|
|
|
// Extended access functions.
|
|
// Note that we depend on these matching the definitions in sys/kauth.h,
|
|
// but with the bits shifted left by 8.
|
|
|
|
// whence values for lseek(2)
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// whence values for lseek(2)
|
|
|
|
// whence values for lseek(2); renamed by POSIX 1003.1
|
|
|
|
type accessx_descriptor = struct {
|
|
ad_name_offset uint32
|
|
ad_flags int32
|
|
ad_pad [2]int32
|
|
} /* unistd.h:132:1 */
|
|
|
|
// configurable pathname variables
|
|
|
|
// configurable system strings
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type uint64_t = uint64 /* _uint64_t.h:31:28 */
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type uint32_t = uint32 /* _uint32_t.h:31:22 */
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type uid_t = uint32 /* _uid_t.h:31:31 */
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type gid_t = uint32 /* _gid_t.h:31:25 */
|
|
|
|
// Copyright (c) 2007-2016 by Apple Inc.. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type pid_t = int32 /* _pid_t.h:31:31 */
|
|
// DO NOT REMOVE THIS COMMENT: fixincludes needs to see:
|
|
// _GCC_SIZE_T
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type useconds_t = uint32 /* _useconds_t.h:31:33 */
|
|
|
|
// Darwin extensions
|
|
|
|
// Copyright (c) 2000-2005 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 1992, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)select.h 8.2 (Berkeley) 1/4/94
|
|
|
|
// Copyright (c) 2002 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// [XSI] The <sys/select.h> header shall define the fd_set type as a structure.
|
|
// The timespec structure shall be defined as described in <time.h>
|
|
// The <sys/select.h> header shall define the timeval structure.
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 2007-2016 by Apple Inc.. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Select uses bit masks of file descriptors in longs. These macros
|
|
// manipulate such bit fields (the filesystem macros use chars). The
|
|
// extra protection here is to permit application redefinition above
|
|
// the default size.
|
|
|
|
type fd_set1 = struct{ fds_bits [32]int32 } /* _fd_def.h:50:9 */
|
|
|
|
// Darwin extensions
|
|
|
|
// Copyright (c) 2000-2005 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 1992, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)select.h 8.2 (Berkeley) 1/4/94
|
|
|
|
// Copyright (c) 2002 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// [XSI] The <sys/select.h> header shall define the fd_set type as a structure.
|
|
// The timespec structure shall be defined as described in <time.h>
|
|
// The <sys/select.h> header shall define the timeval structure.
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 2007-2016 by Apple Inc.. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Select uses bit masks of file descriptors in longs. These macros
|
|
// manipulate such bit fields (the filesystem macros use chars). The
|
|
// extra protection here is to permit application redefinition above
|
|
// the default size.
|
|
|
|
type fd_set = fd_set1 /* _fd_def.h:52:3 */
|
|
|
|
// Use the built-in bzero function instead of the library version so that
|
|
// we do not pollute the namespace or introduce prototype warnings.
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
|
|
type timespec = struct {
|
|
tv_sec int64
|
|
tv_nsec int64
|
|
} /* _timespec.h:33:1 */
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type timeval = struct {
|
|
tv_sec int64
|
|
tv_usec int32
|
|
_ [4]byte
|
|
} /* _timeval.h:34:1 */
|
|
|
|
// The time_t and suseconds_t types shall be defined as described in
|
|
// <sys/types.h>
|
|
// The sigset_t type shall be defined as described in <signal.h>
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
type time_t = int64 /* _time_t.h:31:33 */
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type suseconds_t = int32 /* _suseconds_t.h:31:33 */
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type sigset_t = uint32 /* _sigset_t.h:31:41 */
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type dev_t = int32 /* _dev_t.h:31:31 */ // device number
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type mode_t = uint16 /* _mode_t.h:31:33 */
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type uuid_t = [16]uint8 /* _uuid_t.h:31:25 */
|
|
|
|
// Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2000-2012 Apple, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 1995 NeXT Computer, Inc. All Rights Reserved
|
|
// Copyright (c) 1982, 1986, 1989, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
// (c) UNIX System Laboratories, Inc.
|
|
// All or some portions of this file are derived from material licensed
|
|
// to the University of California by American Telephone and Telegraph
|
|
// Co. or Unix System Laboratories, Inc. and are reproduced herein with
|
|
// the permission of UNIX System Laboratories, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)errno.h 8.5 (Berkeley) 1/21/94
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type errno_t = int32 /* _errno_t.h:30:32 */
|
|
|
|
// Error codes
|
|
|
|
// 11 was EAGAIN
|
|
|
|
// math software
|
|
|
|
// non-blocking and interrupt i/o
|
|
|
|
// ipc/network software -- argument errors
|
|
|
|
// ipc/network software -- operational errors
|
|
|
|
// should be rearranged
|
|
|
|
// quotas & mush
|
|
|
|
// Network File System
|
|
|
|
// Intelligent device errors
|
|
|
|
// Program loading errors
|
|
|
|
// This value is only discrete when compiling __DARWIN_UNIX03, or KERNEL
|
|
|
|
// Copyright (c) 2000, 2002 - 2008 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
// -
|
|
// Copyright (c) 1990, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)stdlib.h 8.5 (Berkeley) 5/19/95
|
|
|
|
// Copyright (c) 2007-2016 by Apple Inc.. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2004, 2008, 2009 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 1995 NeXT Computer, Inc. All Rights Reserved
|
|
// Copyright (c) 1982, 1986, 1989, 1993, 1994
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)wait.h 8.2 (Berkeley) 7/10/94
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// This file holds definitions relevent to the wait4 system call
|
|
// and the alternate interfaces that use it (wait, wait3, waitpid).
|
|
|
|
// [XSI] The type idtype_t shall be defined as an enumeration type whose
|
|
// possible values shall include at least P_ALL, P_PID, and P_PGID.
|
|
type idtype_t = uint32 /* wait.h:83:3 */
|
|
|
|
// [XSI] The id_t and pid_t types shall be defined as described
|
|
// in <sys/types.h>
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type id_t = uint32 /* _id_t.h:31:25 */ // can hold pid_t, gid_t, or uid_t
|
|
|
|
// [XSI] The siginfo_t type shall be defined as described in <signal.h>
|
|
// [XSI] The rusage structure shall be defined as described in <sys/resource.h>
|
|
// [XSI] Inclusion of the <sys/wait.h> header may also make visible all
|
|
// symbols from <signal.h> and <sys/resource.h>
|
|
//
|
|
// NOTE: This requirement is currently being satisfied by the direct
|
|
// inclusion of <sys/signal.h> and <sys/resource.h>, below.
|
|
//
|
|
// Software should not depend on the exposure of anything other
|
|
// than the types siginfo_t and struct rusage as a result of
|
|
// this inclusion. If you depend on any types or manifest
|
|
// values othe than siginfo_t and struct rusage from either of
|
|
// those files, you should explicitly include them yourself, as
|
|
// well, or in future releases your stware may not compile
|
|
// without modification.
|
|
// Copyright (c) 2000-2006 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 1995 NeXT Computer, Inc. All Rights Reserved
|
|
// Copyright (c) 1982, 1986, 1989, 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
// (c) UNIX System Laboratories, Inc.
|
|
// All or some portions of this file are derived from material licensed
|
|
// to the University of California by American Telephone and Telegraph
|
|
// Co. or Unix System Laboratories, Inc. and are reproduced herein with
|
|
// the permission of UNIX System Laboratories, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)signal.h 8.2 (Berkeley) 1/21/94
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2002 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2007-2016 by Apple Inc.. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2009 Apple, Inc. All rights reserved.
|
|
// Copyright (c) 1992 NeXT Computer, Inc.
|
|
//
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
type sig_atomic_t = int32 /* signal.h:15:13 */
|
|
|
|
// Language spec sez we must list exactly one parameter, even though we
|
|
// actually supply three. Ugh!
|
|
// SIG_HOLD is chosen to avoid KERN_SIG_* values in <sys/signalvar.h>
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2002 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2017 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2004-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// @OSF_COPYRIGHT@
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
|
|
type __darwin_arm_exception_state = struct {
|
|
__exception uint32
|
|
__fsr uint32
|
|
__far uint32
|
|
} /* _structs.h:39:1 */
|
|
|
|
type __darwin_arm_exception_state64 = struct {
|
|
__far uint64
|
|
__esr uint32
|
|
__exception uint32
|
|
} /* _structs.h:57:1 */
|
|
|
|
type __darwin_arm_thread_state = struct {
|
|
__r [13]uint32
|
|
__sp uint32
|
|
__lr uint32
|
|
__pc uint32
|
|
__cpsr uint32
|
|
} /* _structs.h:75:1 */
|
|
|
|
// By default, the pointer fields in the arm_thread_state64_t structure are
|
|
// opaque on the arm64e architecture and require the use of accessor macros.
|
|
// This mode can also be enabled on the arm64 architecture by building with
|
|
// -D__DARWIN_OPAQUE_ARM_THREAD_STATE64=1.
|
|
|
|
type __darwin_arm_thread_state64 = struct {
|
|
__x [29]uint64
|
|
__fp uint64
|
|
__lr uint64
|
|
__sp uint64
|
|
__pc uint64
|
|
__cpsr uint32
|
|
__pad uint32
|
|
} /* _structs.h:134:1 */
|
|
|
|
// Accessor macros for arm_thread_state64_t pointer fields
|
|
|
|
// Return pc field of arm_thread_state64_t as a data pointer value
|
|
// Return pc field of arm_thread_state64_t as a function pointer
|
|
// Set pc field of arm_thread_state64_t to a function pointer
|
|
// Return lr field of arm_thread_state64_t as a data pointer value
|
|
// Return lr field of arm_thread_state64_t as a function pointer
|
|
// Set lr field of arm_thread_state64_t to a function pointer
|
|
// Return sp field of arm_thread_state64_t as a data pointer value
|
|
// Set sp field of arm_thread_state64_t to a data pointer value
|
|
// Return fp field of arm_thread_state64_t as a data pointer value
|
|
// Set fp field of arm_thread_state64_t to a data pointer value
|
|
// Strip ptr auth bits from pc, lr, sp and fp field of arm_thread_state64_t
|
|
|
|
type __darwin_arm_vfp_state = struct {
|
|
__r [64]uint32
|
|
__fpscr uint32
|
|
} /* _structs.h:422:1 */
|
|
|
|
type __darwin_arm_neon_state64 = struct {
|
|
__v [32]struct {
|
|
lo uint64
|
|
hi uint64
|
|
}
|
|
__fpsr uint32
|
|
__fpcr uint32
|
|
} /* _structs.h:441:1 */
|
|
|
|
type __darwin_arm_neon_state = struct {
|
|
__v [16]struct {
|
|
lo uint64
|
|
hi uint64
|
|
}
|
|
__fpsr uint32
|
|
__fpcr uint32
|
|
} /* _structs.h:448:1 */
|
|
|
|
type __darwin_arm_amx_state_v1 = struct {
|
|
_ [0]uint64
|
|
__x [8][64]uint8
|
|
__y [8][64]uint8
|
|
__z [64][64]uint8
|
|
__amx_state_t_el1 uint64
|
|
} /* _structs.h:512:1 */
|
|
|
|
type __arm_pagein_state = struct{ __pagein_error int32 } /* _structs.h:531:1 */
|
|
|
|
// Debug State
|
|
|
|
// ARM's arm_debug_state is ARM64's arm_legacy_debug_state
|
|
|
|
type __arm_legacy_debug_state = struct {
|
|
__bvr [16]uint32
|
|
__bcr [16]uint32
|
|
__wvr [16]uint32
|
|
__wcr [16]uint32
|
|
} /* _structs.h:568:1 */
|
|
|
|
type __darwin_arm_debug_state32 = struct {
|
|
__bvr [16]uint32
|
|
__bcr [16]uint32
|
|
__wvr [16]uint32
|
|
__wcr [16]uint32
|
|
__mdscr_el1 uint64
|
|
} /* _structs.h:591:1 */
|
|
|
|
type __darwin_arm_debug_state64 = struct {
|
|
__bvr [16]uint64
|
|
__bcr [16]uint64
|
|
__wvr [16]uint64
|
|
__wcr [16]uint64
|
|
__mdscr_el1 uint64
|
|
} /* _structs.h:601:1 */
|
|
|
|
type __darwin_arm_cpmu_state64 = struct{ __ctrs [16]uint64 } /* _structs.h:633:1 */
|
|
|
|
type __darwin_mcontext32 = struct {
|
|
__es struct {
|
|
__exception uint32
|
|
__fsr uint32
|
|
__far uint32
|
|
}
|
|
__ss struct {
|
|
__r [13]uint32
|
|
__sp uint32
|
|
__lr uint32
|
|
__pc uint32
|
|
__cpsr uint32
|
|
}
|
|
__fs struct {
|
|
__r [64]uint32
|
|
__fpscr uint32
|
|
}
|
|
} /* _mcontext.h:39:1 */
|
|
|
|
type __darwin_mcontext64 = struct {
|
|
__es struct {
|
|
__far uint64
|
|
__esr uint32
|
|
__exception uint32
|
|
}
|
|
__ss struct {
|
|
__x [29]uint64
|
|
__fp uint64
|
|
__lr uint64
|
|
__sp uint64
|
|
__pc uint64
|
|
__cpsr uint32
|
|
__pad uint32
|
|
}
|
|
__ns struct {
|
|
__v [32]struct {
|
|
lo uint64
|
|
hi uint64
|
|
}
|
|
__fpsr uint32
|
|
__fpcr uint32
|
|
}
|
|
} /* _mcontext.h:62:1 */
|
|
|
|
type mcontext_t = uintptr /* _mcontext.h:83:33 */
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2013 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type pthread_attr_t = _opaque_pthread_attr_t /* _pthread_attr_t.h:31:33 */
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Structure used in sigaltstack call.
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
|
|
type __darwin_sigaltstack = struct {
|
|
ss_sp uintptr
|
|
ss_size uint64
|
|
ss_flags int32
|
|
_ [4]byte
|
|
} /* _sigaltstack.h:42:1 */
|
|
|
|
type stack_t = __darwin_sigaltstack /* _sigaltstack.h:48:33 */ // [???] signal stack
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Structure used in sigaltstack call.
|
|
|
|
type __darwin_ucontext = struct {
|
|
uc_onstack int32
|
|
uc_sigmask uint32
|
|
uc_stack struct {
|
|
ss_sp uintptr
|
|
ss_size uint64
|
|
ss_flags int32
|
|
_ [4]byte
|
|
}
|
|
uc_link uintptr
|
|
uc_mcsize uint64
|
|
uc_mcontext uintptr
|
|
} /* _ucontext.h:43:1 */
|
|
|
|
// user context
|
|
type ucontext_t = __darwin_ucontext /* _ucontext.h:57:33 */ // [???] user context
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type sigval = struct {
|
|
_ [0]uint64
|
|
sival_int int32
|
|
_ [4]byte
|
|
} /* signal.h:158:1 */
|
|
|
|
type sigevent = struct {
|
|
sigev_notify int32
|
|
sigev_signo int32
|
|
sigev_value struct {
|
|
_ [0]uint64
|
|
sival_int int32
|
|
_ [4]byte
|
|
}
|
|
sigev_notify_function uintptr
|
|
sigev_notify_attributes uintptr
|
|
} /* signal.h:168:1 */
|
|
|
|
type __siginfo = struct {
|
|
si_signo int32
|
|
si_errno int32
|
|
si_code int32
|
|
si_pid pid_t
|
|
si_uid uid_t
|
|
si_status int32
|
|
si_addr uintptr
|
|
si_value struct {
|
|
_ [0]uint64
|
|
sival_int int32
|
|
_ [4]byte
|
|
}
|
|
si_band int64
|
|
__pad [7]uint64
|
|
} /* signal.h:177:9 */
|
|
|
|
type siginfo_t = __siginfo /* signal.h:188:3 */
|
|
|
|
// When the signal is SIGILL or SIGFPE, si_addr contains the address of
|
|
// the faulting instruction.
|
|
// When the signal is SIGSEGV or SIGBUS, si_addr contains the address of
|
|
// the faulting memory reference. Although for x86 there are cases of SIGSEGV
|
|
// for which si_addr cannot be determined and is NULL.
|
|
// If the signal is SIGCHLD, the si_pid field will contain the child process ID,
|
|
// si_status contains the exit value or signal and
|
|
// si_uid contains the real user ID of the process that sent the signal.
|
|
|
|
// Values for si_code
|
|
|
|
// Codes for SIGILL
|
|
|
|
// Codes for SIGFPE
|
|
|
|
// Codes for SIGSEGV
|
|
|
|
// Codes for SIGBUS
|
|
|
|
// Codes for SIGTRAP
|
|
|
|
// Codes for SIGCHLD
|
|
|
|
// Codes for SIGPOLL
|
|
|
|
// union for signal handlers
|
|
type __sigaction_u = struct{ __sa_handler uintptr } /* signal.h:269:1 */
|
|
|
|
// Signal vector template for Kernel user boundary
|
|
type __sigaction = struct {
|
|
__sigaction_u struct{ __sa_handler uintptr }
|
|
sa_tramp uintptr
|
|
sa_mask sigset_t
|
|
sa_flags int32
|
|
} /* signal.h:276:1 */
|
|
|
|
// Signal vector "template" used in sigaction call.
|
|
type sigaction = struct {
|
|
__sigaction_u struct{ __sa_handler uintptr }
|
|
sa_mask sigset_t
|
|
sa_flags int32
|
|
} /* signal.h:286:1 */
|
|
|
|
// if SA_SIGINFO is set, sa_sigaction is to be used instead of sa_handler.
|
|
|
|
// This will provide 64bit register set in a 32bit user address space
|
|
|
|
// the following are the only bits we support from user space, the
|
|
// rest are for kernel use only.
|
|
|
|
// Flags for sigprocmask:
|
|
|
|
// POSIX 1003.1b required values.
|
|
|
|
type sig_t = uintptr /* signal.h:331:14 */ // type of signal function
|
|
|
|
// Structure used in sigaltstack call.
|
|
|
|
// 4.3 compatibility:
|
|
// Signal vector "template" used in sigvec call.
|
|
type sigvec = struct {
|
|
sv_handler uintptr
|
|
sv_mask int32
|
|
sv_flags int32
|
|
} /* signal.h:348:1 */
|
|
|
|
// Structure used in sigstack call.
|
|
type sigstack = struct {
|
|
ss_sp uintptr
|
|
ss_onstack int32
|
|
_ [4]byte
|
|
} /* signal.h:367:1 */
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 1995 NeXT Computer, Inc. All Rights Reserved
|
|
// Copyright (c) 1982, 1986, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)resource.h 8.2 (Berkeley) 1/4/94
|
|
|
|
// Copyright (c) 2002 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// DO NOT EDIT THIS FILE.
|
|
//
|
|
// It has been auto-edited by fixincludes from:
|
|
//
|
|
// "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdint.h"
|
|
//
|
|
// This had to be done to correct non-standard usages in the
|
|
// original, manufacturer supplied header file.
|
|
|
|
// Copyright (c) 2000-2010 Apple Inc.
|
|
// All rights reserved.
|
|
|
|
// from ISO/IEC 988:1999 spec
|
|
|
|
// 7.18.1.1 Exact-width integer types
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type uint8_t = uint8 /* _uint8_t.h:31:23 */
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type uint16_t = uint16 /* _uint16_t.h:31:24 */
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// 7.18.1.2 Minimum-width integer types
|
|
type int_least8_t = int8_t /* stdint.h:38:26 */
|
|
type int_least16_t = int16_t /* stdint.h:39:25 */
|
|
type int_least32_t = int32_t /* stdint.h:40:25 */
|
|
type int_least64_t = int64_t /* stdint.h:41:25 */
|
|
type uint_least8_t = uint8_t /* stdint.h:42:25 */
|
|
type uint_least16_t = uint16_t /* stdint.h:43:24 */
|
|
type uint_least32_t = uint32_t /* stdint.h:44:24 */
|
|
type uint_least64_t = uint64_t /* stdint.h:45:24 */
|
|
|
|
// 7.18.1.3 Fastest-width integer types
|
|
type int_fast8_t = int8_t /* stdint.h:49:27 */
|
|
type int_fast16_t = int16_t /* stdint.h:50:26 */
|
|
type int_fast32_t = int32_t /* stdint.h:51:26 */
|
|
type int_fast64_t = int64_t /* stdint.h:52:26 */
|
|
type uint_fast8_t = uint8_t /* stdint.h:53:26 */
|
|
type uint_fast16_t = uint16_t /* stdint.h:54:25 */
|
|
type uint_fast32_t = uint32_t /* stdint.h:55:25 */
|
|
type uint_fast64_t = uint64_t /* stdint.h:56:25 */
|
|
|
|
// 7.18.1.4 Integer types capable of holding object pointers
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// 7.18.1.5 Greatest-width integer types
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type intmax_t = int64 /* _intmax_t.h:32:25 */
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
type uintmax_t = uint64 /* _uintmax_t.h:32:26 */
|
|
|
|
// 7.18.4 Macros for integer constants
|
|
|
|
// 7.18.2 Limits of specified-width integer types:
|
|
// These #defines specify the minimum and maximum limits
|
|
// of each of the types declared above.
|
|
//
|
|
// They must have "the same type as would an expression that is an
|
|
// object of the corresponding type converted according to the integer
|
|
// promotion".
|
|
|
|
// 7.18.2.1 Limits of exact-width integer types
|
|
|
|
//
|
|
// Note: the literal "most negative int" cannot be written in C --
|
|
// the rules in the standard (section 6.4.4.1 in C99) will give it
|
|
// an unsigned type, so INT32_MIN (and the most negative member of
|
|
// any larger signed type) must be written via a constant expression.
|
|
//
|
|
|
|
// 7.18.2.2 Limits of minimum-width integer types
|
|
|
|
// 7.18.2.3 Limits of fastest minimum-width integer types
|
|
|
|
// 7.18.2.4 Limits of integer types capable of holding object pointers
|
|
|
|
// 7.18.2.5 Limits of greatest-width integer types
|
|
|
|
// 7.18.3 "Other"
|
|
|
|
// WCHAR_MIN should be 0 if wchar_t is an unsigned type and
|
|
// (-WCHAR_MAX-1) if wchar_t is a signed type. Unfortunately,
|
|
// it turns out that -fshort-wchar changes the signedness of
|
|
// the type.
|
|
|
|
// Copyright (c) 2007-2016 by Apple Inc.. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// [XSI] The timeval structure shall be defined as described in
|
|
// <sys/time.h>
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// The id_t type shall be defined as described in <sys/types.h>
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Resource limit type (low 63 bits, excluding the sign bit)
|
|
type rlim_t = uint64 /* resource.h:89:25 */
|
|
|
|
// ****
|
|
//
|
|
// PRIORITY
|
|
|
|
// Possible values of the first parameter to getpriority()/setpriority(),
|
|
// used to indicate the type of the second parameter.
|
|
|
|
// Range limitations for the value of the third parameter to setpriority().
|
|
|
|
// use PRIO_DARWIN_BG to set the current thread into "background" state
|
|
// which lowers CPU, disk IO, and networking priorites until thread terminates
|
|
// or "background" state is revoked
|
|
|
|
// use PRIO_DARWIN_NONUI to restrict a process's ability to make calls to
|
|
// the GPU. (deprecated)
|
|
|
|
// ****
|
|
//
|
|
// RESOURCE USAGE
|
|
|
|
// Possible values of the first parameter to getrusage(), used to indicate
|
|
// the scope of the information to be returned.
|
|
|
|
// A structure representing an accounting of resource utilization. The
|
|
// address of an instance of this structure is the second parameter to
|
|
// getrusage().
|
|
//
|
|
// Note: All values other than ru_utime and ru_stime are implementaiton
|
|
// defined and subject to change in a future release. Their use
|
|
// is discouraged for standards compliant programs.
|
|
type rusage = struct {
|
|
ru_utime struct {
|
|
tv_sec int64
|
|
tv_usec int32
|
|
_ [4]byte
|
|
}
|
|
ru_stime struct {
|
|
tv_sec int64
|
|
tv_usec int32
|
|
_ [4]byte
|
|
}
|
|
ru_maxrss int64
|
|
ru_ixrss int64
|
|
ru_idrss int64
|
|
ru_isrss int64
|
|
ru_minflt int64
|
|
ru_majflt int64
|
|
ru_nswap int64
|
|
ru_inblock int64
|
|
ru_oublock int64
|
|
ru_msgsnd int64
|
|
ru_msgrcv int64
|
|
ru_nsignals int64
|
|
ru_nvcsw int64
|
|
ru_nivcsw int64
|
|
} /* resource.h:152:1 */
|
|
|
|
// Flavors for proc_pid_rusage().
|
|
|
|
// Flags for RUSAGE_INFO_V5
|
|
|
|
type rusage_info_t = uintptr /* resource.h:199:14 */
|
|
|
|
type rusage_info_v0 = struct {
|
|
ri_uuid [16]uint8_t
|
|
ri_user_time uint64_t
|
|
ri_system_time uint64_t
|
|
ri_pkg_idle_wkups uint64_t
|
|
ri_interrupt_wkups uint64_t
|
|
ri_pageins uint64_t
|
|
ri_wired_size uint64_t
|
|
ri_resident_size uint64_t
|
|
ri_phys_footprint uint64_t
|
|
ri_proc_start_abstime uint64_t
|
|
ri_proc_exit_abstime uint64_t
|
|
} /* resource.h:201:1 */
|
|
|
|
type rusage_info_v1 = struct {
|
|
ri_uuid [16]uint8_t
|
|
ri_user_time uint64_t
|
|
ri_system_time uint64_t
|
|
ri_pkg_idle_wkups uint64_t
|
|
ri_interrupt_wkups uint64_t
|
|
ri_pageins uint64_t
|
|
ri_wired_size uint64_t
|
|
ri_resident_size uint64_t
|
|
ri_phys_footprint uint64_t
|
|
ri_proc_start_abstime uint64_t
|
|
ri_proc_exit_abstime uint64_t
|
|
ri_child_user_time uint64_t
|
|
ri_child_system_time uint64_t
|
|
ri_child_pkg_idle_wkups uint64_t
|
|
ri_child_interrupt_wkups uint64_t
|
|
ri_child_pageins uint64_t
|
|
ri_child_elapsed_abstime uint64_t
|
|
} /* resource.h:215:1 */
|
|
|
|
type rusage_info_v2 = struct {
|
|
ri_uuid [16]uint8_t
|
|
ri_user_time uint64_t
|
|
ri_system_time uint64_t
|
|
ri_pkg_idle_wkups uint64_t
|
|
ri_interrupt_wkups uint64_t
|
|
ri_pageins uint64_t
|
|
ri_wired_size uint64_t
|
|
ri_resident_size uint64_t
|
|
ri_phys_footprint uint64_t
|
|
ri_proc_start_abstime uint64_t
|
|
ri_proc_exit_abstime uint64_t
|
|
ri_child_user_time uint64_t
|
|
ri_child_system_time uint64_t
|
|
ri_child_pkg_idle_wkups uint64_t
|
|
ri_child_interrupt_wkups uint64_t
|
|
ri_child_pageins uint64_t
|
|
ri_child_elapsed_abstime uint64_t
|
|
ri_diskio_bytesread uint64_t
|
|
ri_diskio_byteswritten uint64_t
|
|
} /* resource.h:235:1 */
|
|
|
|
type rusage_info_v3 = struct {
|
|
ri_uuid [16]uint8_t
|
|
ri_user_time uint64_t
|
|
ri_system_time uint64_t
|
|
ri_pkg_idle_wkups uint64_t
|
|
ri_interrupt_wkups uint64_t
|
|
ri_pageins uint64_t
|
|
ri_wired_size uint64_t
|
|
ri_resident_size uint64_t
|
|
ri_phys_footprint uint64_t
|
|
ri_proc_start_abstime uint64_t
|
|
ri_proc_exit_abstime uint64_t
|
|
ri_child_user_time uint64_t
|
|
ri_child_system_time uint64_t
|
|
ri_child_pkg_idle_wkups uint64_t
|
|
ri_child_interrupt_wkups uint64_t
|
|
ri_child_pageins uint64_t
|
|
ri_child_elapsed_abstime uint64_t
|
|
ri_diskio_bytesread uint64_t
|
|
ri_diskio_byteswritten uint64_t
|
|
ri_cpu_time_qos_default uint64_t
|
|
ri_cpu_time_qos_maintenance uint64_t
|
|
ri_cpu_time_qos_background uint64_t
|
|
ri_cpu_time_qos_utility uint64_t
|
|
ri_cpu_time_qos_legacy uint64_t
|
|
ri_cpu_time_qos_user_initiated uint64_t
|
|
ri_cpu_time_qos_user_interactive uint64_t
|
|
ri_billed_system_time uint64_t
|
|
ri_serviced_system_time uint64_t
|
|
} /* resource.h:257:1 */
|
|
|
|
type rusage_info_v4 = struct {
|
|
ri_uuid [16]uint8_t
|
|
ri_user_time uint64_t
|
|
ri_system_time uint64_t
|
|
ri_pkg_idle_wkups uint64_t
|
|
ri_interrupt_wkups uint64_t
|
|
ri_pageins uint64_t
|
|
ri_wired_size uint64_t
|
|
ri_resident_size uint64_t
|
|
ri_phys_footprint uint64_t
|
|
ri_proc_start_abstime uint64_t
|
|
ri_proc_exit_abstime uint64_t
|
|
ri_child_user_time uint64_t
|
|
ri_child_system_time uint64_t
|
|
ri_child_pkg_idle_wkups uint64_t
|
|
ri_child_interrupt_wkups uint64_t
|
|
ri_child_pageins uint64_t
|
|
ri_child_elapsed_abstime uint64_t
|
|
ri_diskio_bytesread uint64_t
|
|
ri_diskio_byteswritten uint64_t
|
|
ri_cpu_time_qos_default uint64_t
|
|
ri_cpu_time_qos_maintenance uint64_t
|
|
ri_cpu_time_qos_background uint64_t
|
|
ri_cpu_time_qos_utility uint64_t
|
|
ri_cpu_time_qos_legacy uint64_t
|
|
ri_cpu_time_qos_user_initiated uint64_t
|
|
ri_cpu_time_qos_user_interactive uint64_t
|
|
ri_billed_system_time uint64_t
|
|
ri_serviced_system_time uint64_t
|
|
ri_logical_writes uint64_t
|
|
ri_lifetime_max_phys_footprint uint64_t
|
|
ri_instructions uint64_t
|
|
ri_cycles uint64_t
|
|
ri_billed_energy uint64_t
|
|
ri_serviced_energy uint64_t
|
|
ri_interval_max_phys_footprint uint64_t
|
|
ri_runnable_time uint64_t
|
|
} /* resource.h:288:1 */
|
|
|
|
type rusage_info_v5 = struct {
|
|
ri_uuid [16]uint8_t
|
|
ri_user_time uint64_t
|
|
ri_system_time uint64_t
|
|
ri_pkg_idle_wkups uint64_t
|
|
ri_interrupt_wkups uint64_t
|
|
ri_pageins uint64_t
|
|
ri_wired_size uint64_t
|
|
ri_resident_size uint64_t
|
|
ri_phys_footprint uint64_t
|
|
ri_proc_start_abstime uint64_t
|
|
ri_proc_exit_abstime uint64_t
|
|
ri_child_user_time uint64_t
|
|
ri_child_system_time uint64_t
|
|
ri_child_pkg_idle_wkups uint64_t
|
|
ri_child_interrupt_wkups uint64_t
|
|
ri_child_pageins uint64_t
|
|
ri_child_elapsed_abstime uint64_t
|
|
ri_diskio_bytesread uint64_t
|
|
ri_diskio_byteswritten uint64_t
|
|
ri_cpu_time_qos_default uint64_t
|
|
ri_cpu_time_qos_maintenance uint64_t
|
|
ri_cpu_time_qos_background uint64_t
|
|
ri_cpu_time_qos_utility uint64_t
|
|
ri_cpu_time_qos_legacy uint64_t
|
|
ri_cpu_time_qos_user_initiated uint64_t
|
|
ri_cpu_time_qos_user_interactive uint64_t
|
|
ri_billed_system_time uint64_t
|
|
ri_serviced_system_time uint64_t
|
|
ri_logical_writes uint64_t
|
|
ri_lifetime_max_phys_footprint uint64_t
|
|
ri_instructions uint64_t
|
|
ri_cycles uint64_t
|
|
ri_billed_energy uint64_t
|
|
ri_serviced_energy uint64_t
|
|
ri_interval_max_phys_footprint uint64_t
|
|
ri_runnable_time uint64_t
|
|
ri_flags uint64_t
|
|
} /* resource.h:327:1 */
|
|
|
|
type rusage_info_current = rusage_info_v5 /* resource.h:367:31 */
|
|
|
|
// ****
|
|
//
|
|
// RESOURCE LIMITS
|
|
|
|
// Symbolic constants for resource limits; since all limits are representable
|
|
// as a type rlim_t, we are permitted to define RLIM_SAVED_* in terms of
|
|
// RLIM_INFINITY.
|
|
|
|
// Possible values of the first parameter to getrlimit()/setrlimit(), to
|
|
// indicate for which resource the operation is being performed.
|
|
|
|
// A structure representing a resource limit. The address of an instance
|
|
// of this structure is the second parameter to getrlimit()/setrlimit().
|
|
type rlimit = struct {
|
|
rlim_cur rlim_t
|
|
rlim_max rlim_t
|
|
} /* resource.h:411:1 */
|
|
|
|
// proc_rlimit_control()
|
|
//
|
|
// Resource limit flavors
|
|
|
|
// Flags for wakeups monitor control.
|
|
|
|
// Flags for CPU usage monitor control.
|
|
|
|
// Flags for memory footprint interval tracking.
|
|
|
|
type proc_rlimit_control_wakeupmon = struct {
|
|
wm_flags uint32_t
|
|
wm_rate int32_t
|
|
} /* resource.h:446:1 */
|
|
|
|
// Option bits for the third argument of wait4. WNOHANG causes the
|
|
// wait to not hang if there are no stopped or terminated processes, rather
|
|
// returning an error indication in this case (pid==0). WUNTRACED
|
|
// indicates that the caller should receive status about untraced children
|
|
// which stop due to signals. If children are stopped and a wait without
|
|
// this option is done, it is as though they were still running... nothing
|
|
// about them is returned.
|
|
|
|
// Macros to test the exit status returned by wait
|
|
// and extract the relevant values.
|
|
|
|
// These macros are permited, as they are in the implementation namespace
|
|
|
|
// [XSI] The <sys/wait.h> header shall define the following macros for
|
|
// analysis of process status values
|
|
// 0x13 == SIGCONT
|
|
|
|
// [XSI] The following symbolic constants shall be defined as possible
|
|
// values for the fourth argument to waitid().
|
|
// WNOHANG already defined for wait4()
|
|
// WUNTRACED defined for wait4() but not for waitid()
|
|
// waitid() parameter
|
|
|
|
// POSIX extensions and 4.2/4.3 compatability:
|
|
|
|
// Tokens for special values of the "pid" parameter to wait4.
|
|
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1987, 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)endian.h 8.1 (Berkeley) 6/11/93
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Define _NOQUAD if the compiler does NOT support 64-bit integers.
|
|
// #define _NOQUAD
|
|
|
|
// Define the order of 32-bit words in 64-bit words.
|
|
|
|
// Definitions for byte order, according to byte significance from low
|
|
// address to high.
|
|
|
|
// Copyright (c) 2004, 2006 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 2000-2002 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 1987, 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Macros for network/external number representation conversion.
|
|
|
|
// Copyright (c) 2006 Apple Computer, Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// This header is normally included from <libkern/OSByteOrder.h>. However,
|
|
// <sys/_endian.h> also includes this in the case of little-endian
|
|
// architectures, so that we can map OSByteOrder routines to the hton* and ntoh*
|
|
// macros. This results in the asymmetry below; we only include
|
|
// <libkern/arch/_OSByteOrder.h> for little-endian architectures.
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Macros for swapping constant values in the preprocessing stage.
|
|
|
|
// Copyright (c) 1999-2007 Apple Inc. All rights reserved.
|
|
|
|
// Copyright (c) 2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Collect the __ARM_ARCH_*__ compiler flags into something easier to use.
|
|
|
|
// Generic byte swapping functions.
|
|
|
|
func _OSSwapInt16(tls *libc.TLS, _data uint16_t) uint16_t { /* OSByteOrder.h:15:1: */
|
|
// Reduces to 'rev16' with clang
|
|
return (uint16_t((int32(_data) << 8) | (int32(_data) >> 8)))
|
|
}
|
|
|
|
func _OSSwapInt32(tls *libc.TLS, _data uint32_t) uint32_t { /* OSByteOrder.h:25:1: */
|
|
// This actually generates the best code
|
|
_data = ((((_data ^ ((_data >> 16) | (_data << 16))) & 0xFF00FFFF) >> 8) ^ ((_data >> 8) | (_data << 24)))
|
|
|
|
return _data
|
|
}
|
|
|
|
func _OSSwapInt64(tls *libc.TLS, _data uint64_t) uint64_t { /* OSByteOrder.h:41:1: */
|
|
bp := tls.Alloc(8)
|
|
defer tls.Free(8)
|
|
|
|
// var _u struct {_ull uint64_t;} at bp, 8
|
|
|
|
// This actually generates the best code
|
|
*(*uint32_t)(unsafe.Pointer((bp /* &_u */ /* &._ul */))) = (uint32_t(_data >> 32))
|
|
*(*uint32_t)(unsafe.Pointer((bp /* &_u */ /* &._ul */) + 1*4)) = (uint32_t(_data & uint64(0xffffffff)))
|
|
*(*uint32_t)(unsafe.Pointer((bp /* &_u */ /* &._ul */))) = _OSSwapInt32(tls, *(*uint32_t)(unsafe.Pointer((bp /* &_u */ /* &._ul */))))
|
|
*(*uint32_t)(unsafe.Pointer((bp /* &_u */ /* &._ul */) + 1*4)) = _OSSwapInt32(tls, *(*uint32_t)(unsafe.Pointer((bp /* &_u */ /* &._ul */) + 1*4)))
|
|
return *(*uint64_t)(unsafe.Pointer(bp /* &_u */))
|
|
}
|
|
|
|
// Functions for byte reversed loads.
|
|
|
|
type _OSUnalignedU16 = struct{ __val uint16_t } /* OSByteOrder.h:64:1 */
|
|
|
|
type _OSUnalignedU32 = struct{ __val uint32_t } /* OSByteOrder.h:68:1 */
|
|
|
|
type _OSUnalignedU64 = struct{ __val uint64_t } /* OSByteOrder.h:72:1 */
|
|
|
|
// Deprecated:
|
|
// Structure of the information in the status word returned by wait4.
|
|
// If w_stopval==_WSTOPPED, then the second structure describes
|
|
// the information returned, else the first.
|
|
type wait = struct{ w_status int32 } /* wait.h:194:1 */
|
|
|
|
// built-in for gcc
|
|
|
|
// built-in for gcc 3
|
|
|
|
// DO NOT REMOVE THIS COMMENT: fixincludes needs to see:
|
|
// _GCC_SIZE_T
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type ct_rune_t = int32 /* _ct_rune_t.h:32:28 */
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type rune_t = int32 /* _rune_t.h:31:25 */
|
|
|
|
type div_t = struct {
|
|
quot int32
|
|
rem int32
|
|
} /* stdlib.h:86:3 */
|
|
|
|
type ldiv_t = struct {
|
|
quot int64
|
|
rem int64
|
|
} /* stdlib.h:91:3 */
|
|
|
|
type lldiv_t = struct {
|
|
quot int64
|
|
rem int64
|
|
} /* stdlib.h:97:3 */
|
|
|
|
// C11 Annex K
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2000-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
type rsize_t = uint64 /* _rsize_t.h:31:32 */
|
|
|
|
// Copyright (c) 2000, 2007, 2010 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
// -
|
|
// Copyright (c) 1990, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)string.h 8.1 (Berkeley) 6/2/93
|
|
|
|
// Security checking functions.
|
|
// Copyright (c) 2017 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2007-2016 by Apple Inc.. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2007, 2008 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// bcopy and bzero
|
|
|
|
// Removed in Issue 7
|
|
|
|
// void bcopy(const void *src, void *dst, size_t len)
|
|
|
|
// void bzero(void *s, size_t n)
|
|
|
|
// Security checking functions.
|
|
// Copyright (c) 2007,2017 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Copyright (c) 2007-2016 by Apple Inc.. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2007, 2008 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// <rdar://problem/12622659>
|
|
|
|
// memccpy, memcpy, mempcpy, memmove, memset, strcpy, strlcpy, stpcpy,
|
|
// strncpy, stpncpy, strcat, strlcat, and strncat
|
|
|
|
// void *memcpy(void *dst, const void *src, size_t n)
|
|
|
|
// void *memmove(void *dst, const void *src, size_t len)
|
|
|
|
// void *memset(void *b, int c, size_t len)
|
|
|
|
// char *strcpy(char *dst, const char *src)
|
|
|
|
// char *stpcpy(char *dst, const char *src)
|
|
|
|
// char *stpncpy(char *dst, const char *src, size_t n)
|
|
|
|
// char *strncpy(char *dst, const char *src, size_t n)
|
|
|
|
// char *strcat(char *s1, const char *s2)
|
|
|
|
// char *strncat(char *s1, const char *s2, size_t n)
|
|
|
|
// -
|
|
// Copyright (c) 1992, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
// (c) UNIX System Laboratories, Inc.
|
|
// All or some portions of this file are derived from material licensed
|
|
// to the University of California by American Telephone and Telegraph
|
|
// Co. or Unix System Laboratories, Inc. and are reproduced herein with
|
|
// the permission of UNIX System Laboratories, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)assert.h 8.2 (Berkeley) 1/21/94
|
|
// $FreeBSD: src/include/assert.h,v 1.4 2002/03/23 17:24:53 imp Exp $
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// Unlike other ANSI header files, <assert.h> may usefully be included
|
|
// multiple times, with and without NDEBUG defined.
|
|
|
|
// Copyright (c) 2000, 2005, 2008 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
// Copyright (c) 1989, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
// (c) UNIX System Laboratories, Inc.
|
|
// All or some portions of this file are derived from material licensed
|
|
// to the University of California by American Telephone and Telegraph
|
|
// Co. or Unix System Laboratories, Inc. and are reproduced herein with
|
|
// the permission of UNIX System Laboratories, Inc.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Paul Borman at Krystal Technologies.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)ctype.h 8.4 (Berkeley) 1/21/94
|
|
|
|
// Copyright (c) 2000, 2005, 2008 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
// Copyright (c) 1989, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
// (c) UNIX System Laboratories, Inc.
|
|
// All or some portions of this file are derived from material licensed
|
|
// to the University of California by American Telephone and Telegraph
|
|
// Co. or Unix System Laboratories, Inc. and are reproduced herein with
|
|
// the permission of UNIX System Laboratories, Inc.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Paul Borman at Krystal Technologies.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)ctype.h 8.4 (Berkeley) 1/21/94
|
|
|
|
// Copyright (c) 2000-2018 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright 1995 NeXT Computer, Inc. All rights reserved.
|
|
// Copyright (c) 1991, 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Berkeley Software Design, Inc.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)cdefs.h 8.8 (Berkeley) 1/9/95
|
|
|
|
// -
|
|
// Copyright (c) 1993
|
|
// The Regents of the University of California. All rights reserved.
|
|
//
|
|
// This code is derived from software contributed to Berkeley by
|
|
// Paul Borman at Krystal Technologies.
|
|
//
|
|
// Redistribution and use in source and binary forms, with or without
|
|
// modification, are permitted provided that the following conditions
|
|
// are met:
|
|
// 1. Redistributions of source code must retain the above copyright
|
|
// notice, this list of conditions and the following disclaimer.
|
|
// 2. Redistributions in binary form must reproduce the above copyright
|
|
// notice, this list of conditions and the following disclaimer in the
|
|
// documentation and/or other materials provided with the distribution.
|
|
// 3. All advertising materials mentioning features or use of this software
|
|
// must display the following acknowledgement:
|
|
// This product includes software developed by the University of
|
|
// California, Berkeley and its contributors.
|
|
// 4. Neither the name of the University nor the names of its contributors
|
|
// may be used to endorse or promote products derived from this software
|
|
// without specific prior written permission.
|
|
//
|
|
// THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
// OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
// OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
// SUCH DAMAGE.
|
|
//
|
|
// @(#)runetype.h 8.1 (Berkeley) 6/2/93
|
|
|
|
// Copyright (c) 2004, 2008, 2009 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this
|
|
// file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2003-2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// wchar_t is a built-in type in C++
|
|
// Copyright (c) 2012 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
|
|
// Copyright (c) 2003-2007 Apple Inc. All rights reserved.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_START@
|
|
//
|
|
// This file contains Original Code and/or Modifications of Original Code
|
|
// as defined in and that are subject to the Apple Public Source License
|
|
// Version 2.0 (the 'License'). You may not use this file except in
|
|
// compliance with the License. The rights granted to you under the License
|
|
// may not be used to create, or enable the creation or redistribution of,
|
|
// unlawful or unlicensed copies of an Apple operating system, or to
|
|
// circumvent, violate, or enable the circumvention or violation of, any
|
|
// terms of an Apple operating system software license agreement.
|
|
//
|
|
// Please obtain a copy of the License at
|
|
// http://www.opensource.apple.com/apsl/ and read it before using this file.
|
|
//
|
|
// The Original Code and all software distributed under the License are
|
|
// distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
|
|
// EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
|
|
// INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
|
|
// FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
|
|
// Please see the License for the specific language governing rights and
|
|
// limitations under the License.
|
|
//
|
|
// @APPLE_OSREFERENCE_LICENSE_HEADER_END@
|
|
type wint_t = int32 /* _wint_t.h:32:25 */
|
|
|
|
// The lower 8 bits of runetype[] contain the digit value of the rune.
|
|
type _RuneEntry = struct {
|
|
__min int32
|
|
__max int32
|
|
__map int32
|
|
_ [4]byte
|
|
__types uintptr
|
|
} /* runetype.h:65:3 */
|
|
|
|
type _RuneRange = struct {
|
|
__nranges int32
|
|
_ [4]byte
|
|
__ranges uintptr
|
|
} /* runetype.h:70:3 */
|
|
|
|
type _RuneCharClass = struct {
|
|
__name [14]int8
|
|
_ [2]byte
|
|
__mask uint32
|
|
} /* runetype.h:75:3 */
|
|
|
|
type _RuneLocale = struct {
|
|
__magic [8]int8
|
|
__encoding [32]int8
|
|
__sgetrune uintptr
|
|
__sputrune uintptr
|
|
__invalid_rune int32
|
|
__runetype [256]uint32
|
|
__maplower [256]int32
|
|
__mapupper [256]int32
|
|
_ [4]byte
|
|
__runetype_ext _RuneRange
|
|
__maplower_ext _RuneRange
|
|
__mapupper_ext _RuneRange
|
|
__variable uintptr
|
|
__variable_len int32
|
|
__ncharclasses int32
|
|
__charclasses uintptr
|
|
} /* runetype.h:106:3 */
|
|
|
|
// The suffix to append to the child command lines, if any
|
|
|
|
// The directory separator character(s)
|
|
|
|
// Mark a parameter as unused to suppress compiler warnings
|
|
|
|
// Global data
|
|
type Global = struct {
|
|
argv0 uintptr
|
|
zVfs uintptr
|
|
zDbFile uintptr
|
|
db uintptr
|
|
zErrLog uintptr
|
|
pErrLog uintptr
|
|
zLog uintptr
|
|
pLog uintptr
|
|
zName [32]int8
|
|
taskId int32
|
|
iTrace int32
|
|
bSqlTrace int32
|
|
bIgnoreSqlErrors int32
|
|
nError int32
|
|
nTest int32
|
|
iTimeout int32
|
|
bSync int32
|
|
} /* mptest.c:72:8 */
|
|
|
|
// The suffix to append to the child command lines, if any
|
|
|
|
// The directory separator character(s)
|
|
|
|
// Mark a parameter as unused to suppress compiler warnings
|
|
|
|
// Global data
|
|
var g Global /* mptest.c:90:3: */
|
|
|
|
// Default timeout
|
|
|
|
// Print a message adding zPrefix[] to the beginning of every line.
|
|
func printWithPrefix(tls *libc.TLS, pOut uintptr, zPrefix uintptr, zMsg uintptr) { /* mptest.c:98:13: */
|
|
bp := tls.Alloc(24)
|
|
defer tls.Free(24)
|
|
|
|
for (zMsg != 0) && (*(*int8)(unsafe.Pointer(zMsg)) != 0) {
|
|
var i int32
|
|
for i = 0; ((*(*int8)(unsafe.Pointer(zMsg + uintptr(i))) != 0) && (int32(*(*int8)(unsafe.Pointer(zMsg + uintptr(i)))) != '\n')) && (int32(*(*int8)(unsafe.Pointer(zMsg + uintptr(i)))) != '\r'); i++ {
|
|
}
|
|
libc.Xfprintf(tls, pOut, ts /* "%s%.*s\n" */, libc.VaList(bp, zPrefix, i, zMsg))
|
|
zMsg += uintptr(i)
|
|
for (int32(*(*int8)(unsafe.Pointer(zMsg))) == '\n') || (int32(*(*int8)(unsafe.Pointer(zMsg))) == '\r') {
|
|
zMsg++
|
|
}
|
|
}
|
|
}
|
|
|
|
// Compare two pointers to strings, where the pointers might be NULL.
|
|
func safe_strcmp(tls *libc.TLS, a uintptr, b uintptr) int32 { /* mptest.c:111:12: */
|
|
if a == b {
|
|
return 0
|
|
}
|
|
if a == uintptr(0) {
|
|
return -1
|
|
}
|
|
if b == uintptr(0) {
|
|
return 1
|
|
}
|
|
return libc.Xstrcmp(tls, a, b)
|
|
}
|
|
|
|
// Return TRUE if string z[] matches glob pattern zGlob[].
|
|
// Return FALSE if the pattern does not match.
|
|
//
|
|
// Globbing rules:
|
|
//
|
|
// '*' Matches any sequence of zero or more characters.
|
|
//
|
|
// '?' Matches exactly one character.
|
|
//
|
|
// [...] Matches one character from the enclosed list of
|
|
// characters.
|
|
//
|
|
// [^...] Matches one character not in the enclosed list.
|
|
//
|
|
// '#' Matches any sequence of one or more digits with an
|
|
// optional + or - sign in front
|
|
func strglob(tls *libc.TLS, zGlob uintptr, z uintptr) int32 { /* mptest.c:136:5: */
|
|
var c int32
|
|
var c2 int32
|
|
var invert int32
|
|
var seen int32
|
|
|
|
for (libc.AssignInt32(&c, int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&zGlob, 1)))))) != 0 {
|
|
if c == '*' {
|
|
for ((libc.AssignInt32(&c, int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&zGlob, 1)))))) == '*') || (c == '?') {
|
|
if (c == '?') && ((int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&z, 1))))) == 0) {
|
|
return 0
|
|
}
|
|
}
|
|
if c == 0 {
|
|
return 1
|
|
} else if c == '[' {
|
|
for (*(*int8)(unsafe.Pointer(z)) != 0) && (strglob(tls, (zGlob-uintptr(1)), z) != 0) {
|
|
z++
|
|
}
|
|
return (libc.Bool32((int32(*(*int8)(unsafe.Pointer(z)))) != 0))
|
|
}
|
|
for (libc.AssignInt32(&c2, int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&z, 1)))))) != 0 {
|
|
for c2 != c {
|
|
c2 = int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&z, 1))))
|
|
if c2 == 0 {
|
|
return 0
|
|
}
|
|
}
|
|
if strglob(tls, zGlob, z) != 0 {
|
|
return 1
|
|
}
|
|
}
|
|
return 0
|
|
} else if c == '?' {
|
|
if (int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&z, 1))))) == 0 {
|
|
return 0
|
|
}
|
|
} else if c == '[' {
|
|
var prior_c int32 = 0
|
|
seen = 0
|
|
invert = 0
|
|
c = int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&z, 1))))
|
|
if c == 0 {
|
|
return 0
|
|
}
|
|
c2 = int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&zGlob, 1))))
|
|
if c2 == '^' {
|
|
invert = 1
|
|
c2 = int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&zGlob, 1))))
|
|
}
|
|
if c2 == ']' {
|
|
if c == ']' {
|
|
seen = 1
|
|
}
|
|
c2 = int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&zGlob, 1))))
|
|
}
|
|
for (c2 != 0) && (c2 != ']') {
|
|
if (((c2 == '-') && (int32(*(*int8)(unsafe.Pointer(zGlob))) != ']')) && (int32(*(*int8)(unsafe.Pointer(zGlob))) != 0)) && (prior_c > 0) {
|
|
c2 = int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&zGlob, 1))))
|
|
if (c >= prior_c) && (c <= c2) {
|
|
seen = 1
|
|
}
|
|
prior_c = 0
|
|
} else {
|
|
if c == c2 {
|
|
seen = 1
|
|
}
|
|
prior_c = c2
|
|
}
|
|
c2 = int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&zGlob, 1))))
|
|
}
|
|
if (c2 == 0) || ((seen ^ invert) == 0) {
|
|
return 0
|
|
}
|
|
} else if c == '#' {
|
|
if ((int32(*(*int8)(unsafe.Pointer(z))) == '-') || (int32(*(*int8)(unsafe.Pointer(z))) == '+')) && (libc.Xisdigit(tls, int32(uint8(*(*int8)(unsafe.Pointer(z + 1))))) != 0) {
|
|
z++
|
|
}
|
|
if !(libc.Xisdigit(tls, int32(uint8(*(*int8)(unsafe.Pointer(z))))) != 0) {
|
|
return 0
|
|
}
|
|
z++
|
|
for libc.Xisdigit(tls, int32(uint8(*(*int8)(unsafe.Pointer(z))))) != 0 {
|
|
z++
|
|
}
|
|
} else {
|
|
if c != (int32(*(*int8)(unsafe.Pointer(libc.PostIncUintptr(&z, 1))))) {
|
|
return 0
|
|
}
|
|
}
|
|
}
|
|
return (libc.Bool32(int32(*(*int8)(unsafe.Pointer(z))) == 0))
|
|
}
|
|
|
|
// Close output stream pOut if it is not stdout or stderr
|
|
func maybeClose(tls *libc.TLS, pOut uintptr) { /* mptest.c:208:13: */
|
|
if (pOut != libc.X__stdoutp) && (pOut != libc.X__stderrp) {
|
|
libc.Xfclose(tls, pOut)
|
|
}
|
|
}
|
|
|
|
// Print an error message
|
|
func errorMessage(tls *libc.TLS, zFormat uintptr, va uintptr) { /* mptest.c:215:13: */
|
|
bp := tls.Alloc(38)
|
|
defer tls.Free(38)
|
|
|
|
var ap va_list
|
|
_ = ap
|
|
var zMsg uintptr
|
|
// var zPrefix [30]int8 at bp+8, 30
|
|
|
|
ap = va
|
|
zMsg = sqlite3.Xsqlite3_vmprintf(tls, zFormat, ap)
|
|
_ = ap
|
|
sqlite3.Xsqlite3_snprintf(tls, int32(unsafe.Sizeof([30]int8{})), bp+8 /* &zPrefix[0] */, ts+8 /* "%s:ERROR: " */, libc.VaList(bp, uintptr(unsafe.Pointer(&g))+64 /* &.zName */))
|
|
if g.pLog != 0 {
|
|
printWithPrefix(tls, g.pLog, bp+8 /* &zPrefix[0] */, zMsg)
|
|
libc.Xfflush(tls, g.pLog)
|
|
}
|
|
if (g.pErrLog != 0) && (safe_strcmp(tls, g.zErrLog, g.zLog) != 0) {
|
|
printWithPrefix(tls, g.pErrLog, bp+8 /* &zPrefix[0] */, zMsg)
|
|
libc.Xfflush(tls, g.pErrLog)
|
|
}
|
|
sqlite3.Xsqlite3_free(tls, zMsg)
|
|
g.nError++
|
|
}
|
|
|
|
// Print an error message and then quit.
|
|
func fatalError(tls *libc.TLS, zFormat uintptr, va uintptr) { /* mptest.c:241:13: */
|
|
bp := tls.Alloc(38)
|
|
defer tls.Free(38)
|
|
|
|
var ap va_list
|
|
_ = ap
|
|
var zMsg uintptr
|
|
// var zPrefix [30]int8 at bp+8, 30
|
|
|
|
ap = va
|
|
zMsg = sqlite3.Xsqlite3_vmprintf(tls, zFormat, ap)
|
|
_ = ap
|
|
sqlite3.Xsqlite3_snprintf(tls, int32(unsafe.Sizeof([30]int8{})), bp+8 /* &zPrefix[0] */, ts+19 /* "%s:FATAL: " */, libc.VaList(bp, uintptr(unsafe.Pointer(&g))+64 /* &.zName */))
|
|
if g.pLog != 0 {
|
|
printWithPrefix(tls, g.pLog, bp+8 /* &zPrefix[0] */, zMsg)
|
|
libc.Xfflush(tls, g.pLog)
|
|
maybeClose(tls, g.pLog)
|
|
}
|
|
if (g.pErrLog != 0) && (safe_strcmp(tls, g.zErrLog, g.zLog) != 0) {
|
|
printWithPrefix(tls, g.pErrLog, bp+8 /* &zPrefix[0] */, zMsg)
|
|
libc.Xfflush(tls, g.pErrLog)
|
|
maybeClose(tls, g.pErrLog)
|
|
}
|
|
sqlite3.Xsqlite3_free(tls, zMsg)
|
|
if g.db != 0 {
|
|
var nTry int32 = 0
|
|
g.iTimeout = 0
|
|
for (trySql(tls, ts+30 /* "UPDATE client SE..." */, 0) == SQLITE_BUSY) &&
|
|
((libc.PostIncInt32(&nTry, 1)) < 100) {
|
|
sqlite3.Xsqlite3_sleep(tls, 10)
|
|
}
|
|
}
|
|
sqlite3.Xsqlite3_close(tls, g.db)
|
|
libc.Xexit(tls, 1)
|
|
}
|
|
|
|
// Print a log message
|
|
func logMessage(tls *libc.TLS, zFormat uintptr, va uintptr) { /* mptest.c:276:13: */
|
|
bp := tls.Alloc(38)
|
|
defer tls.Free(38)
|
|
|
|
var ap va_list
|
|
_ = ap
|
|
var zMsg uintptr
|
|
// var zPrefix [30]int8 at bp+8, 30
|
|
|
|
ap = va
|
|
zMsg = sqlite3.Xsqlite3_vmprintf(tls, zFormat, ap)
|
|
_ = ap
|
|
sqlite3.Xsqlite3_snprintf(tls, int32(unsafe.Sizeof([30]int8{})), bp+8 /* &zPrefix[0] */, ts+60 /* "%s: " */, libc.VaList(bp, uintptr(unsafe.Pointer(&g))+64 /* &.zName */))
|
|
if g.pLog != 0 {
|
|
printWithPrefix(tls, g.pLog, bp+8 /* &zPrefix[0] */, zMsg)
|
|
libc.Xfflush(tls, g.pLog)
|
|
}
|
|
sqlite3.Xsqlite3_free(tls, zMsg)
|
|
}
|
|
|
|
// Return the length of a string omitting trailing whitespace
|
|
func clipLength(tls *libc.TLS, z uintptr) int32 { /* mptest.c:294:12: */
|
|
var n int32 = int32(libc.Xstrlen(tls, z))
|
|
for (n > 0) && (libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(z + uintptr((n - 1))))))) != 0) {
|
|
n--
|
|
}
|
|
return n
|
|
}
|
|
|
|
// Auxiliary SQL function to return the name of the VFS
|
|
func vfsNameFunc(tls *libc.TLS, context uintptr, argc int32, argv uintptr) { /* mptest.c:303:13: */
|
|
bp := tls.Alloc(8)
|
|
defer tls.Free(8)
|
|
|
|
var db uintptr = sqlite3.Xsqlite3_context_db_handle(tls, context)
|
|
*(*uintptr)(unsafe.Pointer(bp /* zVfs */)) = uintptr(0)
|
|
_ = argc
|
|
_ = argv
|
|
sqlite3.Xsqlite3_file_control(tls, db, ts+65 /* "main" */, SQLITE_FCNTL_VFSNAME, bp /* &zVfs */)
|
|
if *(*uintptr)(unsafe.Pointer(bp /* zVfs */)) != 0 {
|
|
sqlite3.Xsqlite3_result_text(tls, context, *(*uintptr)(unsafe.Pointer(bp /* zVfs */)), -1, *(*uintptr)(unsafe.Pointer(&struct{ f func(*libc.TLS, uintptr) }{sqlite3.Xsqlite3_free})))
|
|
}
|
|
}
|
|
|
|
// Busy handler with a g.iTimeout-millisecond timeout
|
|
func busyHandler(tls *libc.TLS, pCD uintptr, count int32) int32 { /* mptest.c:321:12: */
|
|
bp := tls.Alloc(8)
|
|
defer tls.Free(8)
|
|
|
|
_ = pCD
|
|
if (count * 10) > g.iTimeout {
|
|
if g.iTimeout > 0 {
|
|
errorMessage(tls, ts+70 /* "timeout after %d..." */, libc.VaList(bp, g.iTimeout))
|
|
}
|
|
return 0
|
|
}
|
|
sqlite3.Xsqlite3_sleep(tls, 10)
|
|
return 1
|
|
}
|
|
|
|
// SQL Trace callback
|
|
func sqlTraceCallback(tls *libc.TLS, NotUsed1 uintptr, zSql uintptr) { /* mptest.c:334:13: */
|
|
bp := tls.Alloc(16)
|
|
defer tls.Free(16)
|
|
|
|
_ = NotUsed1
|
|
logMessage(tls, ts+89 /* "[%.*s]" */, libc.VaList(bp, clipLength(tls, zSql), zSql))
|
|
}
|
|
|
|
// SQL error log callback
|
|
func sqlErrorCallback(tls *libc.TLS, pArg uintptr, iErrCode int32, zMsg uintptr) { /* mptest.c:342:13: */
|
|
bp := tls.Alloc(24)
|
|
defer tls.Free(24)
|
|
|
|
_ = pArg
|
|
if (iErrCode == SQLITE_ERROR) && (g.bIgnoreSqlErrors != 0) {
|
|
return
|
|
}
|
|
if ((iErrCode & 0xff) == SQLITE_SCHEMA) && (g.iTrace < 3) {
|
|
return
|
|
}
|
|
if ((g.iTimeout == 0) && ((iErrCode & 0xff) == SQLITE_BUSY)) && (g.iTrace < 3) {
|
|
return
|
|
}
|
|
if (iErrCode & 0xff) == SQLITE_NOTICE {
|
|
logMessage(tls, ts+96 /* "(info) %s" */, libc.VaList(bp, zMsg))
|
|
} else {
|
|
errorMessage(tls, ts+106 /* "(errcode=%d) %s" */, libc.VaList(bp+8, iErrCode, zMsg))
|
|
}
|
|
}
|
|
|
|
// Prepare an SQL statement. Issue a fatal error if unable.
|
|
func prepareSql(tls *libc.TLS, zFormat uintptr, va uintptr) uintptr { /* mptest.c:357:21: */
|
|
bp := tls.Alloc(24)
|
|
defer tls.Free(24)
|
|
|
|
var ap va_list
|
|
_ = ap
|
|
var zSql uintptr
|
|
var rc int32
|
|
*(*uintptr)(unsafe.Pointer(bp + 16 /* pStmt */)) = uintptr(0)
|
|
ap = va
|
|
zSql = sqlite3.Xsqlite3_vmprintf(tls, zFormat, ap)
|
|
_ = ap
|
|
rc = sqlite3.Xsqlite3_prepare_v2(tls, g.db, zSql, -1, bp+16 /* &pStmt */, uintptr(0))
|
|
if rc != SQLITE_OK {
|
|
sqlite3.Xsqlite3_finalize(tls, *(*uintptr)(unsafe.Pointer(bp + 16 /* pStmt */)))
|
|
fatalError(tls, ts+122 /* "%s\n%s\n" */, libc.VaList(bp, sqlite3.Xsqlite3_errmsg(tls, g.db), zSql))
|
|
}
|
|
sqlite3.Xsqlite3_free(tls, zSql)
|
|
return *(*uintptr)(unsafe.Pointer(bp + 16 /* pStmt */))
|
|
}
|
|
|
|
// Run arbitrary SQL. Issue a fatal error on failure.
|
|
func runSql(tls *libc.TLS, zFormat uintptr, va uintptr) { /* mptest.c:377:13: */
|
|
bp := tls.Alloc(16)
|
|
defer tls.Free(16)
|
|
|
|
var ap va_list
|
|
_ = ap
|
|
var zSql uintptr
|
|
var rc int32
|
|
ap = va
|
|
zSql = sqlite3.Xsqlite3_vmprintf(tls, zFormat, ap)
|
|
_ = ap
|
|
rc = sqlite3.Xsqlite3_exec(tls, g.db, zSql, uintptr(0), uintptr(0), uintptr(0))
|
|
if rc != SQLITE_OK {
|
|
fatalError(tls, ts+122 /* "%s\n%s\n" */, libc.VaList(bp, sqlite3.Xsqlite3_errmsg(tls, g.db), zSql))
|
|
}
|
|
sqlite3.Xsqlite3_free(tls, zSql)
|
|
}
|
|
|
|
// Try to run arbitrary SQL. Return success code.
|
|
func trySql(tls *libc.TLS, zFormat uintptr, va uintptr) int32 { /* mptest.c:394:12: */
|
|
var ap va_list
|
|
_ = ap
|
|
var zSql uintptr
|
|
var rc int32
|
|
ap = va
|
|
zSql = sqlite3.Xsqlite3_vmprintf(tls, zFormat, ap)
|
|
_ = ap
|
|
rc = sqlite3.Xsqlite3_exec(tls, g.db, zSql, uintptr(0), uintptr(0), uintptr(0))
|
|
sqlite3.Xsqlite3_free(tls, zSql)
|
|
return rc
|
|
}
|
|
|
|
// Structure for holding an arbitrary length string
|
|
type String1 = struct {
|
|
z uintptr
|
|
n int32
|
|
nAlloc int32
|
|
} /* mptest.c:408:9 */
|
|
|
|
// Structure for holding an arbitrary length string
|
|
type String = String1 /* mptest.c:408:23 */
|
|
|
|
// Free a string
|
|
func stringFree(tls *libc.TLS, p uintptr) { /* mptest.c:416:13: */
|
|
if (*String)(unsafe.Pointer(p)).z != 0 {
|
|
sqlite3.Xsqlite3_free(tls, (*String)(unsafe.Pointer(p)).z)
|
|
}
|
|
libc.X__builtin___memset_chk(tls, p, 0, uint64(unsafe.Sizeof(String{})), libc.X__builtin_object_size(tls, p, 0))
|
|
}
|
|
|
|
// Append n bytes of text to a string. If n<0 append the entire string.
|
|
func stringAppend(tls *libc.TLS, p uintptr, z uintptr, n int32) { /* mptest.c:422:13: */
|
|
if n < 0 {
|
|
n = int32(libc.Xstrlen(tls, z))
|
|
}
|
|
if ((*String)(unsafe.Pointer(p)).n + n) >= (*String)(unsafe.Pointer(p)).nAlloc {
|
|
var nAlloc int32 = ((((*String)(unsafe.Pointer(p)).nAlloc * 2) + n) + 100)
|
|
var zNew uintptr = sqlite3.Xsqlite3_realloc(tls, (*String)(unsafe.Pointer(p)).z, nAlloc)
|
|
if zNew == uintptr(0) {
|
|
fatalError(tls, ts+129 /* "out of memory" */, 0)
|
|
}
|
|
(*String)(unsafe.Pointer(p)).z = zNew
|
|
(*String)(unsafe.Pointer(p)).nAlloc = nAlloc
|
|
}
|
|
libc.X__builtin___memcpy_chk(tls, ((*String)(unsafe.Pointer(p)).z + uintptr((*String)(unsafe.Pointer(p)).n)), z, uint64(n), libc.X__builtin_object_size(tls, ((*String)(unsafe.Pointer(p)).z+uintptr((*String)(unsafe.Pointer(p)).n)), 0))
|
|
*(*int32)(unsafe.Pointer(p + 8 /* &.n */)) += (n)
|
|
*(*int8)(unsafe.Pointer((*String)(unsafe.Pointer(p)).z + uintptr((*String)(unsafe.Pointer(p)).n))) = int8(0)
|
|
}
|
|
|
|
// Reset a string to an empty string
|
|
func stringReset(tls *libc.TLS, p uintptr) { /* mptest.c:437:13: */
|
|
if (*String)(unsafe.Pointer(p)).z == uintptr(0) {
|
|
stringAppend(tls, p, ts+143 /* " " */, 1)
|
|
}
|
|
(*String)(unsafe.Pointer(p)).n = 0
|
|
*(*int8)(unsafe.Pointer((*String)(unsafe.Pointer(p)).z)) = int8(0)
|
|
}
|
|
|
|
// Append a new token onto the end of the string
|
|
func stringAppendTerm(tls *libc.TLS, p uintptr, z uintptr) { /* mptest.c:444:13: */
|
|
var i int32
|
|
if (*String)(unsafe.Pointer(p)).n != 0 {
|
|
stringAppend(tls, p, ts+143 /* " " */, 1)
|
|
}
|
|
if z == uintptr(0) {
|
|
stringAppend(tls, p, ts+145 /* "nil" */, 3)
|
|
return
|
|
}
|
|
for i = 0; (*(*int8)(unsafe.Pointer(z + uintptr(i))) != 0) && !(libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(z + uintptr(i)))))) != 0); i++ {
|
|
}
|
|
if (i > 0) && (int32(*(*int8)(unsafe.Pointer(z + uintptr(i)))) == 0) {
|
|
stringAppend(tls, p, z, i)
|
|
return
|
|
}
|
|
stringAppend(tls, p, ts+149 /* "'" */, 1)
|
|
for *(*int8)(unsafe.Pointer(z)) != 0 {
|
|
for i = 0; (*(*int8)(unsafe.Pointer(z + uintptr(i))) != 0) && (int32(*(*int8)(unsafe.Pointer(z + uintptr(i)))) != '\''); i++ {
|
|
}
|
|
if *(*int8)(unsafe.Pointer(z + uintptr(i))) != 0 {
|
|
stringAppend(tls, p, z, (i + 1))
|
|
stringAppend(tls, p, ts+149 /* "'" */, 1)
|
|
z += (uintptr(i + 1))
|
|
} else {
|
|
stringAppend(tls, p, z, i)
|
|
break
|
|
}
|
|
}
|
|
stringAppend(tls, p, ts+149 /* "'" */, 1)
|
|
}
|
|
|
|
// Callback function for evalSql()
|
|
func evalCallback(tls *libc.TLS, pCData uintptr, argc int32, argv uintptr, azCol uintptr) int32 { /* mptest.c:474:12: */
|
|
var p uintptr = pCData
|
|
var i int32
|
|
_ = azCol
|
|
for i = 0; i < argc; i++ {
|
|
stringAppendTerm(tls, p, *(*uintptr)(unsafe.Pointer(argv + uintptr(i)*8)))
|
|
}
|
|
return 0
|
|
}
|
|
|
|
// Run arbitrary SQL and record the results in an output string
|
|
// given by the first parameter.
|
|
func evalSql(tls *libc.TLS, p uintptr, zFormat uintptr, va uintptr) int32 { /* mptest.c:486:12: */
|
|
bp := tls.Alloc(46)
|
|
defer tls.Free(46)
|
|
|
|
var ap va_list
|
|
_ = ap
|
|
var zSql uintptr
|
|
var rc int32
|
|
*(*uintptr)(unsafe.Pointer(bp + 8 /* zErrMsg */)) = uintptr(0)
|
|
ap = va
|
|
zSql = sqlite3.Xsqlite3_vmprintf(tls, zFormat, ap)
|
|
_ = ap
|
|
|
|
rc = sqlite3.Xsqlite3_exec(tls, g.db, zSql, *(*uintptr)(unsafe.Pointer(&struct {
|
|
f func(*libc.TLS, uintptr, int32, uintptr, uintptr) int32
|
|
}{evalCallback})), p, bp+8 /* &zErrMsg */)
|
|
sqlite3.Xsqlite3_free(tls, zSql)
|
|
if rc != 0 {
|
|
// var zErr [30]int8 at bp+16, 30
|
|
|
|
sqlite3.Xsqlite3_snprintf(tls, int32(unsafe.Sizeof([30]int8{})), bp+16 /* &zErr[0] */, ts+151 /* "error(%d)" */, libc.VaList(bp, rc))
|
|
stringAppendTerm(tls, p, bp+16 /* &zErr[0] */)
|
|
if *(*uintptr)(unsafe.Pointer(bp + 8 /* zErrMsg */)) != 0 {
|
|
stringAppendTerm(tls, p, *(*uintptr)(unsafe.Pointer(bp + 8 /* zErrMsg */)))
|
|
sqlite3.Xsqlite3_free(tls, *(*uintptr)(unsafe.Pointer(bp + 8 /* zErrMsg */)))
|
|
}
|
|
}
|
|
return rc
|
|
}
|
|
|
|
// Auxiliary SQL function to recursively evaluate SQL.
|
|
func evalFunc(tls *libc.TLS, context uintptr, argc int32, argv uintptr) { /* mptest.c:512:13: */
|
|
bp := tls.Alloc(24)
|
|
defer tls.Free(24)
|
|
|
|
var db uintptr = sqlite3.Xsqlite3_context_db_handle(tls, context)
|
|
var zSql uintptr = sqlite3.Xsqlite3_value_text(tls, *(*uintptr)(unsafe.Pointer(argv)))
|
|
// var res String at bp, 16
|
|
|
|
*(*uintptr)(unsafe.Pointer(bp + 16 /* zErrMsg */)) = uintptr(0)
|
|
var rc int32
|
|
_ = argc
|
|
libc.X__builtin___memset_chk(tls, bp /* &res */, 0, uint64(unsafe.Sizeof(String{})), libc.X__builtin_object_size(tls, bp /* &res */, 0))
|
|
rc = sqlite3.Xsqlite3_exec(tls, db, zSql, *(*uintptr)(unsafe.Pointer(&struct {
|
|
f func(*libc.TLS, uintptr, int32, uintptr, uintptr) int32
|
|
}{evalCallback})), bp /* &res */, bp+16 /* &zErrMsg */)
|
|
if *(*uintptr)(unsafe.Pointer(bp + 16 /* zErrMsg */)) != 0 {
|
|
sqlite3.Xsqlite3_result_error(tls, context, *(*uintptr)(unsafe.Pointer(bp + 16 /* zErrMsg */)), -1)
|
|
sqlite3.Xsqlite3_free(tls, *(*uintptr)(unsafe.Pointer(bp + 16 /* zErrMsg */)))
|
|
} else if rc != 0 {
|
|
sqlite3.Xsqlite3_result_error_code(tls, context, rc)
|
|
} else {
|
|
sqlite3.Xsqlite3_result_text(tls, context, (*String)(unsafe.Pointer(bp /* &res */)).z, -1, libc.UintptrFromInt32(-1))
|
|
}
|
|
stringFree(tls, bp /* &res */)
|
|
}
|
|
|
|
// Look up the next task for client iClient in the database.
|
|
// Return the task script and the task number and mark that
|
|
// task as being under way.
|
|
func startScript(tls *libc.TLS, iClient int32, pzScript uintptr, pTaskId uintptr, pzTaskName uintptr) int32 { /* mptest.c:541:12: */
|
|
bp := tls.Alloc(80)
|
|
defer tls.Free(80)
|
|
|
|
var pStmt uintptr = uintptr(0)
|
|
var taskId int32
|
|
var rc int32
|
|
var totalTime int32 = 0
|
|
|
|
*(*uintptr)(unsafe.Pointer(pzScript)) = uintptr(0)
|
|
g.iTimeout = 0
|
|
for 1 != 0 {
|
|
rc = trySql(tls, ts+161 /* "BEGIN IMMEDIATE" */, 0)
|
|
if rc == SQLITE_BUSY {
|
|
sqlite3.Xsqlite3_sleep(tls, 10)
|
|
totalTime = totalTime + (10)
|
|
continue
|
|
}
|
|
if rc != SQLITE_OK {
|
|
fatalError(tls, ts+177 /* "in startScript: ..." */, libc.VaList(bp, sqlite3.Xsqlite3_errmsg(tls, g.db)))
|
|
}
|
|
if (g.nError != 0) || (g.nTest != 0) {
|
|
runSql(tls, ts+196, /* "UPDATE counters ..." */
|
|
libc.VaList(bp+8, g.nError, g.nTest))
|
|
g.nError = 0
|
|
g.nTest = 0
|
|
}
|
|
pStmt = prepareSql(tls, ts+249 /* "SELECT 1 FROM cl..." */, libc.VaList(bp+24, iClient))
|
|
rc = sqlite3.Xsqlite3_step(tls, pStmt)
|
|
sqlite3.Xsqlite3_finalize(tls, pStmt)
|
|
if rc == SQLITE_ROW {
|
|
runSql(tls, ts+295 /* "DELETE FROM clie..." */, libc.VaList(bp+32, iClient))
|
|
g.iTimeout = DEFAULT_TIMEOUT
|
|
runSql(tls, ts+326 /* "COMMIT TRANSACTI..." */, 0)
|
|
return SQLITE_DONE
|
|
}
|
|
pStmt = prepareSql(tls,
|
|
|
|
ts+346 /* "SELECT script, i..." */, libc.VaList(bp+40, iClient))
|
|
rc = sqlite3.Xsqlite3_step(tls, pStmt)
|
|
if rc == SQLITE_ROW {
|
|
var n int32 = sqlite3.Xsqlite3_column_bytes(tls, pStmt, 0)
|
|
*(*uintptr)(unsafe.Pointer(pzScript)) = sqlite3.Xsqlite3_malloc(tls, (n + 1))
|
|
libc.X__builtin___strcpy_chk(tls, *(*uintptr)(unsafe.Pointer(pzScript)), sqlite3.Xsqlite3_column_text(tls, pStmt, 0), libc.X__builtin_object_size(tls, *(*uintptr)(unsafe.Pointer(pzScript)), func() int32 {
|
|
if X_USE_FORTIFY_LEVEL > 1 {
|
|
return 1
|
|
}
|
|
return 0
|
|
}()))
|
|
*(*int32)(unsafe.Pointer(pTaskId)) = libc.AssignInt32(&taskId, sqlite3.Xsqlite3_column_int(tls, pStmt, 1))
|
|
*(*uintptr)(unsafe.Pointer(pzTaskName)) = sqlite3.Xsqlite3_mprintf(tls, ts+438 /* "%s" */, libc.VaList(bp+48, sqlite3.Xsqlite3_column_text(tls, pStmt, 2)))
|
|
sqlite3.Xsqlite3_finalize(tls, pStmt)
|
|
runSql(tls,
|
|
|
|
ts+441 /* "UPDATE task SE..." */, libc.VaList(bp+56, taskId))
|
|
g.iTimeout = DEFAULT_TIMEOUT
|
|
runSql(tls, ts+326 /* "COMMIT TRANSACTI..." */, 0)
|
|
return SQLITE_OK
|
|
}
|
|
sqlite3.Xsqlite3_finalize(tls, pStmt)
|
|
if rc == SQLITE_DONE {
|
|
if totalTime > 30000 {
|
|
errorMessage(tls, ts+524 /* "Waited over 30 s..." */, 0)
|
|
runSql(tls, ts+573 /* "DELETE FROM clie..." */, libc.VaList(bp+64, iClient))
|
|
sqlite3.Xsqlite3_close(tls, g.db)
|
|
libc.Xexit(tls, 1)
|
|
}
|
|
for trySql(tls, ts+613 /* "COMMIT" */, 0) == SQLITE_BUSY {
|
|
sqlite3.Xsqlite3_sleep(tls, 10)
|
|
totalTime = totalTime + (10)
|
|
}
|
|
sqlite3.Xsqlite3_sleep(tls, 100)
|
|
totalTime = totalTime + (100)
|
|
continue
|
|
}
|
|
fatalError(tls, ts+438 /* "%s" */, libc.VaList(bp+72, sqlite3.Xsqlite3_errmsg(tls, g.db)))
|
|
}
|
|
g.iTimeout = DEFAULT_TIMEOUT
|
|
return int32(0)
|
|
}
|
|
|
|
// Mark a script as having finished. Remove the CLIENT table entry
|
|
// if bShutdown is true.
|
|
func finishScript(tls *libc.TLS, iClient int32, taskId int32, bShutdown int32) int32 { /* mptest.c:623:12: */
|
|
bp := tls.Alloc(16)
|
|
defer tls.Free(16)
|
|
|
|
runSql(tls,
|
|
|
|
ts+620 /* "UPDATE task SE..." */, libc.VaList(bp, taskId))
|
|
if bShutdown != 0 {
|
|
runSql(tls, ts+295 /* "DELETE FROM clie..." */, libc.VaList(bp+8, iClient))
|
|
}
|
|
return SQLITE_OK
|
|
}
|
|
|
|
// Start up a client process for iClient, if it is not already
|
|
// running. If the client is already running, then this routine
|
|
// is a no-op.
|
|
func startClient(tls *libc.TLS, iClient int32) { /* mptest.c:638:13: */
|
|
bp := tls.Alloc(96)
|
|
defer tls.Free(96)
|
|
|
|
runSql(tls, ts+701 /* "INSERT OR IGNORE..." */, libc.VaList(bp, iClient))
|
|
if sqlite3.Xsqlite3_changes(tls, g.db) != 0 {
|
|
var zSys uintptr
|
|
var rc int32
|
|
zSys = sqlite3.Xsqlite3_mprintf(tls, ts+743, /* "%s \"%s\" --client..." */
|
|
libc.VaList(bp+8, g.argv0, g.zDbFile, iClient, g.iTrace))
|
|
if g.bSqlTrace != 0 {
|
|
zSys = sqlite3.Xsqlite3_mprintf(tls, ts+774 /* "%z --sqltrace" */, libc.VaList(bp+40, zSys))
|
|
}
|
|
if g.bSync != 0 {
|
|
zSys = sqlite3.Xsqlite3_mprintf(tls, ts+788 /* "%z --sync" */, libc.VaList(bp+48, zSys))
|
|
}
|
|
if g.zVfs != 0 {
|
|
zSys = sqlite3.Xsqlite3_mprintf(tls, ts+798 /* "%z --vfs \"%s\"" */, libc.VaList(bp+56, zSys, g.zVfs))
|
|
}
|
|
if g.iTrace >= 2 {
|
|
logMessage(tls, ts+812 /* "system('%q')" */, libc.VaList(bp+72, zSys))
|
|
}
|
|
zSys = sqlite3.Xsqlite3_mprintf(tls, ts+825 /* "%z &" */, libc.VaList(bp+80, zSys))
|
|
rc = libc.Xsystem(tls, zSys)
|
|
if rc != 0 {
|
|
errorMessage(tls, ts+830 /* "system() fails w..." */, libc.VaList(bp+88, rc))
|
|
}
|
|
sqlite3.Xsqlite3_free(tls, zSys)
|
|
}
|
|
}
|
|
|
|
// Read the entire content of a file into memory
|
|
func readFile(tls *libc.TLS, zFilename uintptr) uintptr { /* mptest.c:684:13: */
|
|
bp := tls.Alloc(8)
|
|
defer tls.Free(8)
|
|
|
|
var in uintptr = libc.Xfopen(tls, zFilename, ts+864 /* "rb" */)
|
|
var sz int64
|
|
var z uintptr
|
|
if in == uintptr(0) {
|
|
fatalError(tls, ts+867 /* "cannot open \"%s\"..." */, libc.VaList(bp, zFilename))
|
|
}
|
|
libc.Xfseek(tls, in, int64(0), SEEK_END)
|
|
sz = libc.Xftell(tls, in)
|
|
libc.Xrewind(tls, in)
|
|
z = sqlite3.Xsqlite3_malloc(tls, (int32(sz + int64(1))))
|
|
sz = int64(libc.Xfread(tls, z, uint64(1), uint64(sz), in))
|
|
*(*int8)(unsafe.Pointer(z + uintptr(sz))) = int8(0)
|
|
libc.Xfclose(tls, in)
|
|
return z
|
|
}
|
|
|
|
// Return the length of the next token.
|
|
func tokenLength(tls *libc.TLS, z uintptr, pnLine uintptr) int32 { /* mptest.c:704:12: */
|
|
var n int32 = 0
|
|
if (libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(z))))) != 0) || ((int32(*(*int8)(unsafe.Pointer(z))) == '/') && (int32(*(*int8)(unsafe.Pointer(z + 1))) == '*')) {
|
|
var inC int32 = 0
|
|
var c int32
|
|
if int32(*(*int8)(unsafe.Pointer(z))) == '/' {
|
|
inC = 1
|
|
n = 2
|
|
}
|
|
for (libc.AssignInt32(&c, int32(*(*int8)(unsafe.Pointer(z + uintptr(libc.PostIncInt32(&n, 1))))))) != 0 {
|
|
if c == '\n' {
|
|
(*(*int32)(unsafe.Pointer(pnLine)))++
|
|
}
|
|
if libc.Xisspace(tls, int32(uint8(c))) != 0 {
|
|
continue
|
|
}
|
|
if ((inC != 0) && (c == '*')) && (int32(*(*int8)(unsafe.Pointer(z + uintptr(n)))) == '/') {
|
|
n++
|
|
inC = 0
|
|
} else if (!(inC != 0) && (c == '/')) && (int32(*(*int8)(unsafe.Pointer(z + uintptr(n)))) == '*') {
|
|
n++
|
|
inC = 1
|
|
} else if !(inC != 0) {
|
|
break
|
|
}
|
|
}
|
|
n--
|
|
} else if (int32(*(*int8)(unsafe.Pointer(z))) == '-') && (int32(*(*int8)(unsafe.Pointer(z + 1))) == '-') {
|
|
for n = 2; (*(*int8)(unsafe.Pointer(z + uintptr(n))) != 0) && (int32(*(*int8)(unsafe.Pointer(z + uintptr(n)))) != '\n'); n++ {
|
|
}
|
|
if *(*int8)(unsafe.Pointer(z + uintptr(n))) != 0 {
|
|
(*(*int32)(unsafe.Pointer(pnLine)))++
|
|
n++
|
|
}
|
|
} else if (int32(*(*int8)(unsafe.Pointer(z))) == '"') || (int32(*(*int8)(unsafe.Pointer(z))) == '\'') {
|
|
var delim int32 = int32(*(*int8)(unsafe.Pointer(z)))
|
|
for n = 1; *(*int8)(unsafe.Pointer(z + uintptr(n))) != 0; n++ {
|
|
if int32(*(*int8)(unsafe.Pointer(z + uintptr(n)))) == '\n' {
|
|
(*(*int32)(unsafe.Pointer(pnLine)))++
|
|
}
|
|
if int32(*(*int8)(unsafe.Pointer(z + uintptr(n)))) == delim {
|
|
n++
|
|
if int32(*(*int8)(unsafe.Pointer(z + uintptr((n + 1))))) != delim {
|
|
break
|
|
}
|
|
}
|
|
}
|
|
} else {
|
|
var c int32
|
|
for n = 1; (((((libc.AssignInt32(&c, int32(*(*int8)(unsafe.Pointer(z + uintptr(n)))))) != 0) && !(libc.Xisspace(tls, int32(uint8(c))) != 0)) && (c != '"')) && (c != '\'')) && (c != ';'); n++ {
|
|
}
|
|
}
|
|
return n
|
|
}
|
|
|
|
// Copy a single token into a string buffer.
|
|
func extractToken(tls *libc.TLS, zIn uintptr, nIn int32, zOut uintptr, nOut int32) int32 { /* mptest.c:749:12: */
|
|
var i int32
|
|
if nIn <= 0 {
|
|
*(*int8)(unsafe.Pointer(zOut)) = int8(0)
|
|
return 0
|
|
}
|
|
for i = 0; ((i < nIn) && (i < (nOut - 1))) && !(libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(zIn + uintptr(i)))))) != 0); i++ {
|
|
*(*int8)(unsafe.Pointer(zOut + uintptr(i))) = *(*int8)(unsafe.Pointer(zIn + uintptr(i)))
|
|
}
|
|
*(*int8)(unsafe.Pointer(zOut + uintptr(i))) = int8(0)
|
|
return i
|
|
}
|
|
|
|
// Find the number of characters up to the start of the next "--end" token.
|
|
func findEnd(tls *libc.TLS, z uintptr, pnLine uintptr) int32 { /* mptest.c:763:12: */
|
|
var n int32 = 0
|
|
for (*(*int8)(unsafe.Pointer(z + uintptr(n))) != 0) && ((libc.Xstrncmp(tls, (z+uintptr(n)), ts+896 /* "--end" */, uint64(5)) != 0) || !(libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(z + uintptr((n + 5))))))) != 0)) {
|
|
n = n + (tokenLength(tls, (z + uintptr(n)), pnLine))
|
|
}
|
|
return n
|
|
}
|
|
|
|
// Find the number of characters up to the first character past the
|
|
// of the next "--endif" or "--else" token. Nested --if commands are
|
|
// also skipped.
|
|
func findEndif(tls *libc.TLS, z uintptr, stopAtElse int32, pnLine uintptr) int32 { /* mptest.c:776:12: */
|
|
var n int32 = 0
|
|
for *(*int8)(unsafe.Pointer(z + uintptr(n))) != 0 {
|
|
var len int32 = tokenLength(tls, (z + uintptr(n)), pnLine)
|
|
if ((libc.Xstrncmp(tls, (z+uintptr(n)), ts+902 /* "--endif" */, uint64(7)) == 0) && (libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(z + uintptr((n + 7))))))) != 0)) ||
|
|
(((stopAtElse != 0) && (libc.Xstrncmp(tls, (z+uintptr(n)), ts+910 /* "--else" */, uint64(6)) == 0)) && (libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(z + uintptr((n + 6))))))) != 0)) {
|
|
return (n + len)
|
|
}
|
|
if (libc.Xstrncmp(tls, (z+uintptr(n)), ts+917 /* "--if" */, uint64(4)) == 0) && (libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(z + uintptr((n + 4))))))) != 0) {
|
|
var skip int32 = findEndif(tls, ((z + uintptr(n)) + uintptr(len)), 0, pnLine)
|
|
n = n + (skip + len)
|
|
} else {
|
|
n = n + (len)
|
|
}
|
|
}
|
|
return n
|
|
}
|
|
|
|
// Wait for a client process to complete all its tasks
|
|
func waitForClient(tls *libc.TLS, iClient int32, iTimeout int32, zErrPrefix uintptr) { /* mptest.c:798:13: */
|
|
bp := tls.Alloc(32)
|
|
defer tls.Free(32)
|
|
|
|
var pStmt uintptr
|
|
var rc int32
|
|
if iClient > 0 {
|
|
pStmt = prepareSql(tls,
|
|
|
|
ts+922, /* "SELECT 1 FROM ta..." */
|
|
libc.VaList(bp, iClient))
|
|
} else {
|
|
pStmt = prepareSql(tls,
|
|
|
|
ts+1018 /* "SELECT 1 FROM ta..." */, 0)
|
|
}
|
|
g.iTimeout = 0
|
|
for (((libc.AssignInt32(&rc, sqlite3.Xsqlite3_step(tls, pStmt))) == SQLITE_BUSY) || (rc == SQLITE_ROW)) &&
|
|
(iTimeout > 0) {
|
|
sqlite3.Xsqlite3_reset(tls, pStmt)
|
|
sqlite3.Xsqlite3_sleep(tls, 50)
|
|
iTimeout = iTimeout - (50)
|
|
}
|
|
sqlite3.Xsqlite3_finalize(tls, pStmt)
|
|
g.iTimeout = DEFAULT_TIMEOUT
|
|
if rc != SQLITE_DONE {
|
|
if zErrPrefix == uintptr(0) {
|
|
zErrPrefix = ts + 1099 /* "" */
|
|
}
|
|
if iClient > 0 {
|
|
errorMessage(tls, ts+1100 /* "%stimeout waitin..." */, libc.VaList(bp+8, zErrPrefix, iClient))
|
|
} else {
|
|
errorMessage(tls, ts+1132 /* "%stimeout waitin..." */, libc.VaList(bp+24, zErrPrefix))
|
|
}
|
|
}
|
|
}
|
|
|
|
// Return a pointer to the tail of a filename
|
|
func filenameTail(tls *libc.TLS, z uintptr) uintptr { /* mptest.c:836:13: */
|
|
var i int32
|
|
var j int32
|
|
for i = libc.AssignInt32(&j, 0); *(*int8)(unsafe.Pointer(z + uintptr(i))) != 0; i++ {
|
|
if (int32(*(*int8)(unsafe.Pointer(z + uintptr(i))))) == '/' {
|
|
j = (i + 1)
|
|
}
|
|
}
|
|
return (z + uintptr(j))
|
|
}
|
|
|
|
// Interpret zArg as a boolean value. Return either 0 or 1.
|
|
func booleanValue(tls *libc.TLS, zArg uintptr) int32 { /* mptest.c:845:12: */
|
|
bp := tls.Alloc(8)
|
|
defer tls.Free(8)
|
|
|
|
var i int32
|
|
if zArg == uintptr(0) {
|
|
return 0
|
|
}
|
|
for i = 0; (int32(*(*int8)(unsafe.Pointer(zArg + uintptr(i)))) >= '0') && (int32(*(*int8)(unsafe.Pointer(zArg + uintptr(i)))) <= '9'); i++ {
|
|
}
|
|
if (i > 0) && (int32(*(*int8)(unsafe.Pointer(zArg + uintptr(i)))) == 0) {
|
|
return libc.Xatoi(tls, zArg)
|
|
}
|
|
if (sqlite3.Xsqlite3_stricmp(tls, zArg, ts+1166 /* "on" */) == 0) || (sqlite3.Xsqlite3_stricmp(tls, zArg, ts+1169 /* "yes" */) == 0) {
|
|
return 1
|
|
}
|
|
if (sqlite3.Xsqlite3_stricmp(tls, zArg, ts+1173 /* "off" */) == 0) || (sqlite3.Xsqlite3_stricmp(tls, zArg, ts+1177 /* "no" */) == 0) {
|
|
return 0
|
|
}
|
|
errorMessage(tls, ts+1180 /* "unknown boolean:..." */, libc.VaList(bp, zArg))
|
|
return 0
|
|
}
|
|
|
|
// This routine exists as a convenient place to set a debugger
|
|
// breakpoint.
|
|
func test_breakpoint(tls *libc.TLS) { /* mptest.c:864:13: */
|
|
atomic.AddInt32(&cnt, 1)
|
|
}
|
|
|
|
var cnt int32 = 0 /* mptest.c:864:56 */
|
|
|
|
// Maximum number of arguments to a --command
|
|
|
|
// Run a script.
|
|
func runScript(tls *libc.TLS, iClient int32, taskId int32, zScript uintptr, zFilename uintptr) { /* mptest.c:872:13: */
|
|
bp := tls.Alloc(1610)
|
|
defer tls.Free(1610)
|
|
|
|
*(*int32)(unsafe.Pointer(bp + 376 /* lineno */)) = 1
|
|
var prevLine int32 = 1
|
|
var ii int32 = 0
|
|
var iBegin int32 = 0
|
|
var n int32
|
|
var c int32
|
|
var j int32
|
|
var len int32
|
|
var nArg int32
|
|
// var sResult String at bp+360, 16
|
|
|
|
// var zCmd [30]int8 at bp+380, 30
|
|
|
|
// var zError [1000]int8 at bp+610, 1000
|
|
|
|
// var azArg [2][100]int8 at bp+410, 200
|
|
|
|
libc.X__builtin___memset_chk(tls, bp+360 /* &sResult */, 0, uint64(unsafe.Sizeof(String{})), libc.X__builtin_object_size(tls, bp+360 /* &sResult */, 0))
|
|
stringReset(tls, bp+360 /* &sResult */)
|
|
for (libc.AssignInt32(&c, int32(*(*int8)(unsafe.Pointer(zScript + uintptr(ii)))))) != 0 {
|
|
prevLine = *(*int32)(unsafe.Pointer(bp + 376 /* lineno */))
|
|
len = tokenLength(tls, (zScript + uintptr(ii)), bp+376 /* &lineno */)
|
|
if (libc.Xisspace(tls, int32(uint8(c))) != 0) || ((c == '/') && (int32(*(*int8)(unsafe.Pointer(zScript + uintptr((ii + 1))))) == '*')) {
|
|
ii = ii + (len)
|
|
continue
|
|
}
|
|
if ((c != '-') || (int32(*(*int8)(unsafe.Pointer(zScript + uintptr((ii + 1))))) != '-')) || !(libc.Xisalpha(tls, int32(*(*int8)(unsafe.Pointer(zScript + uintptr((ii + 2)))))) != 0) {
|
|
ii = ii + (len)
|
|
continue
|
|
}
|
|
|
|
// Run any prior SQL before processing the new --command
|
|
if ii > iBegin {
|
|
var zSql uintptr = sqlite3.Xsqlite3_mprintf(tls, ts+1202 /* "%.*s" */, libc.VaList(bp, (ii-iBegin), (zScript+uintptr(iBegin))))
|
|
evalSql(tls, bp+360 /* &sResult */, zSql, 0)
|
|
sqlite3.Xsqlite3_free(tls, zSql)
|
|
iBegin = (ii + len)
|
|
}
|
|
|
|
// Parse the --command
|
|
if g.iTrace >= 2 {
|
|
logMessage(tls, ts+1202 /* "%.*s" */, libc.VaList(bp+16, len, (zScript+uintptr(ii))))
|
|
}
|
|
n = extractToken(tls, ((zScript + uintptr(ii)) + uintptr(2)), (len - 2), bp+380 /* &zCmd[0] */, int32(unsafe.Sizeof([30]int8{})))
|
|
for nArg = 0; (n < (len - 2)) && (nArg < MX_ARG); nArg++ {
|
|
for (n < (len - 2)) && (libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(zScript + uintptr(((ii + 2) + n))))))) != 0) {
|
|
n++
|
|
}
|
|
if n >= (len - 2) {
|
|
break
|
|
}
|
|
n = n + (extractToken(tls, (((zScript + uintptr(ii)) + uintptr(2)) + uintptr(n)), ((len - 2) - n),
|
|
(bp + 410 /* &azArg[0] */ + uintptr(nArg)*100), int32(unsafe.Sizeof([100]int8{}))))
|
|
}
|
|
for j = nArg; j < MX_ARG; j++ {
|
|
*(*int8)(unsafe.Pointer((bp + 410 /* &azArg[0] */ + uintptr(libc.PostIncInt32(&j, 1))*100))) = int8(0)
|
|
}
|
|
|
|
// --sleep N
|
|
//
|
|
// Pause for N milliseconds
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1207 /* "sleep" */) == 0 {
|
|
sqlite3.Xsqlite3_sleep(tls, libc.Xatoi(tls, (bp+410 /* &azArg[0] */)))
|
|
} else
|
|
|
|
// --exit N
|
|
//
|
|
// Exit this process. If N>0 then exit without shutting down
|
|
// SQLite. (In other words, simulate a crash.)
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1213 /* "exit" */) == 0 {
|
|
var rc int32 = libc.Xatoi(tls, (bp + 410 /* &azArg[0] */))
|
|
finishScript(tls, iClient, taskId, 1)
|
|
if rc == 0 {
|
|
sqlite3.Xsqlite3_close(tls, g.db)
|
|
}
|
|
libc.Xexit(tls, rc)
|
|
} else
|
|
|
|
// --testcase NAME
|
|
//
|
|
// Begin a new test case. Announce in the log that the test case
|
|
// has begun.
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1218 /* "testcase" */) == 0 {
|
|
if g.iTrace == 1 {
|
|
logMessage(tls, ts+1202 /* "%.*s" */, libc.VaList(bp+32, (len-1), (zScript+uintptr(ii))))
|
|
}
|
|
stringReset(tls, bp+360 /* &sResult */)
|
|
} else
|
|
|
|
// --finish
|
|
//
|
|
// Mark the current task as having finished, even if it is not.
|
|
// This can be used in conjunction with --exit to simulate a crash.
|
|
if (libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1227 /* "finish" */) == 0) && (iClient > 0) {
|
|
finishScript(tls, iClient, taskId, 1)
|
|
} else
|
|
|
|
// --reset
|
|
//
|
|
// Reset accumulated results back to an empty string
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1234 /* "reset" */) == 0 {
|
|
stringReset(tls, bp+360 /* &sResult */)
|
|
} else
|
|
|
|
// --match ANSWER...
|
|
//
|
|
// Check to see if output matches ANSWER. Report an error if not.
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1240 /* "match" */) == 0 {
|
|
var jj int32
|
|
var zAns uintptr = (zScript + uintptr(ii))
|
|
for jj = 7; (jj < (len - 1)) && (libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(zAns + uintptr(jj)))))) != 0); jj++ {
|
|
}
|
|
zAns += uintptr(jj)
|
|
if (((len - jj) - 1) != (*String)(unsafe.Pointer(bp+360 /* &sResult */)).n) || (libc.Xstrncmp(tls, (*String)(unsafe.Pointer(bp+360 /* &sResult */)).z, zAns, (uint64((len-jj)-1))) != 0) {
|
|
errorMessage(tls, ts+1246, /* "line %d of %s:\nE..." */
|
|
libc.VaList(bp+48, prevLine, zFilename, ((len-jj)-1), zAns, (*String)(unsafe.Pointer(bp+360 /* &sResult */)).z))
|
|
}
|
|
g.nTest++
|
|
stringReset(tls, bp+360 /* &sResult */)
|
|
} else
|
|
|
|
// --glob ANSWER...
|
|
// --notglob ANSWER....
|
|
//
|
|
// Check to see if output does or does not match the glob pattern
|
|
// ANSWER.
|
|
if (libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1291 /* "glob" */) == 0) || (libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1296 /* "notglob" */) == 0) {
|
|
var jj int32
|
|
var zAns uintptr = (zScript + uintptr(ii))
|
|
var zCopy uintptr
|
|
var isGlob int32 = (libc.Bool32(int32(*(*int8)(unsafe.Pointer(bp + 380 /* &zCmd[0] */))) == 'g'))
|
|
for jj = (9 - (3 * isGlob)); (jj < (len - 1)) && (libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(zAns + uintptr(jj)))))) != 0); jj++ {
|
|
}
|
|
zAns += uintptr(jj)
|
|
zCopy = sqlite3.Xsqlite3_mprintf(tls, ts+1202 /* "%.*s" */, libc.VaList(bp+88, ((len-jj)-1), zAns))
|
|
if ((libc.Bool32(sqlite3.Xsqlite3_strglob(tls, zCopy, (*String)(unsafe.Pointer(bp+360 /* &sResult */)).z) == 0)) ^ isGlob) != 0 {
|
|
errorMessage(tls, ts+1304, /* "line %d of %s:\nE..." */
|
|
libc.VaList(bp+104, prevLine, zFilename, zCopy, (*String)(unsafe.Pointer(bp+360 /* &sResult */)).z))
|
|
}
|
|
sqlite3.Xsqlite3_free(tls, zCopy)
|
|
g.nTest++
|
|
stringReset(tls, bp+360 /* &sResult */)
|
|
} else
|
|
|
|
// --output
|
|
//
|
|
// Output the result of the previous SQL.
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1347 /* "output" */) == 0 {
|
|
logMessage(tls, ts+438 /* "%s" */, libc.VaList(bp+136, (*String)(unsafe.Pointer(bp+360 /* &sResult */)).z))
|
|
} else
|
|
|
|
// --source FILENAME
|
|
//
|
|
// Run a subscript from a separate file.
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1354 /* "source" */) == 0 {
|
|
var zNewFile uintptr
|
|
var zNewScript uintptr
|
|
var zToDel uintptr = uintptr(0)
|
|
zNewFile = (bp + 410 /* &azArg[0] */)
|
|
if !((int32(*(*int8)(unsafe.Pointer(zNewFile)))) == '/') {
|
|
var k int32
|
|
for k = (int32(libc.Xstrlen(tls, zFilename)) - 1); (k >= 0) && !((int32(*(*int8)(unsafe.Pointer(zFilename + uintptr(k))))) == '/'); k-- {
|
|
}
|
|
if k > 0 {
|
|
zNewFile = libc.AssignUintptr(&zToDel, sqlite3.Xsqlite3_mprintf(tls, ts+1361 /* "%.*s/%s" */, libc.VaList(bp+144, k, zFilename, zNewFile)))
|
|
}
|
|
}
|
|
zNewScript = readFile(tls, zNewFile)
|
|
if g.iTrace != 0 {
|
|
logMessage(tls, ts+1369 /* "begin script [%s..." */, libc.VaList(bp+168, zNewFile))
|
|
}
|
|
runScript(tls, 0, 0, zNewScript, zNewFile)
|
|
sqlite3.Xsqlite3_free(tls, zNewScript)
|
|
if g.iTrace != 0 {
|
|
logMessage(tls, ts+1388 /* "end script [%s]\n" */, libc.VaList(bp+176, zNewFile))
|
|
}
|
|
sqlite3.Xsqlite3_free(tls, zToDel)
|
|
} else
|
|
|
|
// --print MESSAGE....
|
|
//
|
|
// Output the remainder of the line to the log file
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1405 /* "print" */) == 0 {
|
|
var jj int32
|
|
for jj = 7; (jj < len) && (libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(zScript + uintptr((ii + jj))))))) != 0); jj++ {
|
|
}
|
|
logMessage(tls, ts+1202 /* "%.*s" */, libc.VaList(bp+184, (len-jj), ((zScript+uintptr(ii))+uintptr(jj))))
|
|
} else
|
|
|
|
// --if EXPR
|
|
//
|
|
// Skip forward to the next matching --endif or --else if EXPR is false.
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1411 /* "if" */) == 0 {
|
|
var jj int32
|
|
var rc int32
|
|
var pStmt uintptr
|
|
for jj = 4; (jj < len) && (libc.Xisspace(tls, int32(uint8(*(*int8)(unsafe.Pointer(zScript + uintptr((ii + jj))))))) != 0); jj++ {
|
|
}
|
|
pStmt = prepareSql(tls, ts+1414 /* "SELECT %.*s" */, libc.VaList(bp+200, (len-jj), ((zScript+uintptr(ii))+uintptr(jj))))
|
|
rc = sqlite3.Xsqlite3_step(tls, pStmt)
|
|
if (rc != SQLITE_ROW) || (sqlite3.Xsqlite3_column_int(tls, pStmt, 0) == 0) {
|
|
ii = ii + (findEndif(tls, ((zScript + uintptr(ii)) + uintptr(len)), 1, bp+376 /* &lineno */))
|
|
}
|
|
sqlite3.Xsqlite3_finalize(tls, pStmt)
|
|
} else
|
|
|
|
// --else
|
|
//
|
|
// This command can only be encountered if currently inside an --if that
|
|
// is true. Skip forward to the next matching --endif.
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1426 /* "else" */) == 0 {
|
|
ii = ii + (findEndif(tls, ((zScript + uintptr(ii)) + uintptr(len)), 0, bp+376 /* &lineno */))
|
|
} else
|
|
|
|
// --endif
|
|
//
|
|
// This command can only be encountered if currently inside an --if that
|
|
// is true or an --else of a false if. This is a no-op.
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1431 /* "endif" */) == 0 {
|
|
// no-op
|
|
} else
|
|
|
|
// --start CLIENT
|
|
//
|
|
// Start up the given client.
|
|
if (libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1437 /* "start" */) == 0) && (iClient == 0) {
|
|
var iNewClient int32 = libc.Xatoi(tls, (bp + 410 /* &azArg[0] */))
|
|
if iNewClient > 0 {
|
|
startClient(tls, iNewClient)
|
|
}
|
|
} else
|
|
|
|
// --wait CLIENT TIMEOUT
|
|
//
|
|
// Wait until all tasks complete for the given client. If CLIENT is
|
|
// "all" then wait for all clients to complete. Wait no longer than
|
|
// TIMEOUT milliseconds (default 10,000)
|
|
if (libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1443 /* "wait" */) == 0) && (iClient == 0) {
|
|
var iTimeout int32
|
|
if nArg >= 2 {
|
|
iTimeout = libc.Xatoi(tls, (bp + 410 /* &azArg[0] */ + 1*100))
|
|
} else {
|
|
iTimeout = 10000
|
|
}
|
|
sqlite3.Xsqlite3_snprintf(tls, int32(unsafe.Sizeof([1000]int8{})), bp+610 /* &zError[0] */, ts+1448, /* "line %d of %s\n" */
|
|
libc.VaList(bp+216, prevLine, zFilename))
|
|
waitForClient(tls, libc.Xatoi(tls, (bp+410 /* &azArg[0] */)), iTimeout, bp+610 /* &zError[0] */)
|
|
} else
|
|
|
|
// --task CLIENT
|
|
// <task-content-here>
|
|
// --end
|
|
//
|
|
// Assign work to a client. Start the client if it is not running
|
|
// already.
|
|
if (libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1463 /* "task" */) == 0) && (iClient == 0) {
|
|
var iTarget int32 = libc.Xatoi(tls, (bp + 410 /* &azArg[0] */))
|
|
var iEnd int32
|
|
var zTask uintptr
|
|
var zTName uintptr
|
|
iEnd = findEnd(tls, ((zScript + uintptr(ii)) + uintptr(len)), bp+376 /* &lineno */)
|
|
if iTarget < 0 {
|
|
errorMessage(tls, ts+1468, /* "line %d of %s: b..." */
|
|
libc.VaList(bp+232, prevLine, zFilename, iTarget))
|
|
} else {
|
|
zTask = sqlite3.Xsqlite3_mprintf(tls, ts+1202 /* "%.*s" */, libc.VaList(bp+256, iEnd, ((zScript+uintptr(ii))+uintptr(len))))
|
|
if nArg > 1 {
|
|
zTName = sqlite3.Xsqlite3_mprintf(tls, ts+438 /* "%s" */, libc.VaList(bp+272, (bp+410 /* &azArg[0] */ +1*100)))
|
|
} else {
|
|
zTName = sqlite3.Xsqlite3_mprintf(tls, ts+1505 /* "%s:%d" */, libc.VaList(bp+280, filenameTail(tls, zFilename), prevLine))
|
|
}
|
|
startClient(tls, iTarget)
|
|
runSql(tls,
|
|
ts+1511 /* "INSERT INTO task..." */, libc.VaList(bp+296, iTarget, zTask, zTName))
|
|
sqlite3.Xsqlite3_free(tls, zTask)
|
|
sqlite3.Xsqlite3_free(tls, zTName)
|
|
}
|
|
iEnd = iEnd + (tokenLength(tls, (((zScript + uintptr(ii)) + uintptr(len)) + uintptr(iEnd)), bp+376 /* &lineno */))
|
|
len = len + (iEnd)
|
|
iBegin = (ii + len)
|
|
} else
|
|
|
|
// --breakpoint
|
|
//
|
|
// This command calls "test_breakpoint()" which is a routine provided
|
|
// as a convenient place to set a debugger breakpoint.
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1567 /* "breakpoint" */) == 0 {
|
|
test_breakpoint(tls)
|
|
} else
|
|
|
|
// --show-sql-errors BOOLEAN
|
|
//
|
|
// Turn display of SQL errors on and off.
|
|
if libc.Xstrcmp(tls, bp+380 /* &zCmd[0] */, ts+1578 /* "show-sql-errors" */) == 0 {
|
|
g.bIgnoreSqlErrors = func() int32 {
|
|
if nArg >= 1 {
|
|
return libc.BoolInt32(!(booleanValue(tls, (bp+410 /* &azArg[0] */)) != 0))
|
|
}
|
|
return 1
|
|
}()
|
|
} else {
|
|
errorMessage(tls, ts+1594, /* "line %d of %s: u..." */
|
|
libc.VaList(bp+320, prevLine, zFilename, bp+380 /* &zCmd[0] */))
|
|
}
|
|
ii = ii + (len)
|
|
}
|
|
if iBegin < ii {
|
|
var zSql uintptr = sqlite3.Xsqlite3_mprintf(tls, ts+1202 /* "%.*s" */, libc.VaList(bp+344, (ii-iBegin), (zScript+uintptr(iBegin))))
|
|
runSql(tls, zSql, 0)
|
|
sqlite3.Xsqlite3_free(tls, zSql)
|
|
}
|
|
stringFree(tls, bp+360 /* &sResult */)
|
|
}
|
|
|
|
// Look for a command-line option. If present, return a pointer.
|
|
// Return NULL if missing.
|
|
//
|
|
// hasArg==0 means the option is a flag. It is either present or not.
|
|
// hasArg==1 means the option has an argument. Return a pointer to the
|
|
// argument.
|
|
func findOption(tls *libc.TLS, azArg uintptr, pnArg uintptr, zOption uintptr, hasArg int32) uintptr { /* mptest.c:1201:13: */
|
|
bp := tls.Alloc(8)
|
|
defer tls.Free(8)
|
|
|
|
var i int32
|
|
var j int32
|
|
var zReturn uintptr = uintptr(0)
|
|
var nArg int32 = *(*int32)(unsafe.Pointer(pnArg))
|
|
|
|
for i = 0; i < nArg; i++ {
|
|
var z uintptr
|
|
if (i + hasArg) >= nArg {
|
|
break
|
|
}
|
|
z = *(*uintptr)(unsafe.Pointer(azArg + uintptr(i)*8))
|
|
if int32(*(*int8)(unsafe.Pointer(z))) != '-' {
|
|
continue
|
|
}
|
|
z++
|
|
if int32(*(*int8)(unsafe.Pointer(z))) == '-' {
|
|
if int32(*(*int8)(unsafe.Pointer(z + 1))) == 0 {
|
|
break
|
|
}
|
|
z++
|
|
}
|
|
if libc.Xstrcmp(tls, z, zOption) == 0 {
|
|
if (hasArg != 0) && (i == (nArg - 1)) {
|
|
fatalError(tls, ts+1630 /* "command-line opt..." */, libc.VaList(bp, z))
|
|
}
|
|
if hasArg != 0 {
|
|
zReturn = *(*uintptr)(unsafe.Pointer(azArg + uintptr((i+1))*8))
|
|
} else {
|
|
zReturn = *(*uintptr)(unsafe.Pointer(azArg + uintptr(i)*8))
|
|
}
|
|
j = ((i + 1) + (libc.Bool32(hasArg != 0)))
|
|
for j < nArg {
|
|
*(*uintptr)(unsafe.Pointer(azArg + uintptr(libc.PostIncInt32(&i, 1))*8)) = *(*uintptr)(unsafe.Pointer(azArg + uintptr(libc.PostIncInt32(&j, 1))*8))
|
|
}
|
|
*(*int32)(unsafe.Pointer(pnArg)) = i
|
|
return zReturn
|
|
}
|
|
}
|
|
return zReturn
|
|
}
|
|
|
|
// Print a usage message for the program and exit
|
|
func usage(tls *libc.TLS, argv0 uintptr) { /* mptest.c:1241:13: */
|
|
bp := tls.Alloc(8)
|
|
defer tls.Free(8)
|
|
|
|
var i int32
|
|
var zTail uintptr = argv0
|
|
for i = 0; *(*int8)(unsafe.Pointer(argv0 + uintptr(i))) != 0; i++ {
|
|
if (int32(*(*int8)(unsafe.Pointer(argv0 + uintptr(i))))) == '/' {
|
|
zTail = ((argv0 + uintptr(i)) + uintptr(1))
|
|
}
|
|
}
|
|
libc.Xfprintf(tls, libc.X__stderrp, ts+1678 /* "Usage: %s DATABA..." */, libc.VaList(bp, zTail))
|
|
libc.Xfprintf(tls, libc.X__stderrp,
|
|
|
|
ts+1717 /* "Options:\n --er..." */, 0)
|
|
libc.Xexit(tls, 1)
|
|
}
|
|
|
|
// Report on unrecognized arguments
|
|
func unrecognizedArguments(tls *libc.TLS, argv0 uintptr, nArg int32, azArg uintptr) { /* mptest.c:1265:13: */
|
|
bp := tls.Alloc(16)
|
|
defer tls.Free(16)
|
|
|
|
var i int32
|
|
libc.Xfprintf(tls, libc.X__stderrp, ts+2289 /* "%s: unrecognized..." */, libc.VaList(bp, argv0))
|
|
for i = 0; i < nArg; i++ {
|
|
libc.Xfprintf(tls, libc.X__stderrp, ts+2317 /* " %s" */, libc.VaList(bp+8, *(*uintptr)(unsafe.Pointer(azArg + uintptr(i)*8))))
|
|
}
|
|
libc.Xfprintf(tls, libc.X__stderrp, ts+2321 /* "\n" */, 0)
|
|
libc.Xexit(tls, 1)
|
|
}
|
|
|
|
func main1(tls *libc.TLS, argc int32, argv uintptr) int32 { /* mptest.c:1279:18: */
|
|
bp := tls.Alloc(264)
|
|
defer tls.Free(264)
|
|
|
|
var zClient uintptr
|
|
var iClient int32
|
|
// var n int32 at bp+232, 4
|
|
|
|
var i int32
|
|
var openFlags int32 = SQLITE_OPEN_READWRITE
|
|
var rc int32
|
|
// var zScript uintptr at bp+240, 8
|
|
|
|
// var taskId int32 at bp+248, 4
|
|
|
|
var zTrace uintptr
|
|
var zCOption uintptr
|
|
var zJMode uintptr
|
|
var zNRep uintptr
|
|
var nRep int32 = 1
|
|
var iRep int32
|
|
var iTmout int32 = 0 // Default: no timeout
|
|
var zTmout uintptr
|
|
|
|
g.argv0 = *(*uintptr)(unsafe.Pointer(argv))
|
|
g.iTrace = 1
|
|
if argc < 2 {
|
|
usage(tls, *(*uintptr)(unsafe.Pointer(argv)))
|
|
}
|
|
g.zDbFile = *(*uintptr)(unsafe.Pointer(argv + 1*8))
|
|
if strglob(tls, ts+2323 /* "*.test" */, g.zDbFile) != 0 {
|
|
usage(tls, *(*uintptr)(unsafe.Pointer(argv)))
|
|
}
|
|
if libc.Xstrcmp(tls, sqlite3.Xsqlite3_sourceid(tls), ts+2330 /* "2021-04-19 18:32..." */) != 0 {
|
|
libc.Xfprintf(tls, libc.X__stderrp,
|
|
|
|
ts+2415, /* "SQLite library a..." */
|
|
libc.VaList(bp, sqlite3.Xsqlite3_sourceid(tls), ts+2330 /* "2021-04-19 18:32..." */))
|
|
libc.Xexit(tls, 1)
|
|
}
|
|
*(*int32)(unsafe.Pointer(bp + 232 /* n */)) = (argc - 2)
|
|
sqlite3.Xsqlite3_snprintf(tls, int32(unsafe.Sizeof([32]int8{})), uintptr(unsafe.Pointer(&g))+64 /* &.zName */, ts+2475 /* "%05d.mptest" */, libc.VaList(bp+16, libc.Xgetpid(tls)))
|
|
zJMode = findOption(tls, (argv + uintptr(2)*8), bp+232 /* &n */, ts+2487 /* "journalmode" */, 1)
|
|
zNRep = findOption(tls, (argv + uintptr(2)*8), bp+232 /* &n */, ts+2499 /* "repeat" */, 1)
|
|
if zNRep != 0 {
|
|
nRep = libc.Xatoi(tls, zNRep)
|
|
}
|
|
if nRep < 1 {
|
|
nRep = 1
|
|
}
|
|
g.zVfs = findOption(tls, (argv + uintptr(2)*8), bp+232 /* &n */, ts+2506 /* "vfs" */, 1)
|
|
zClient = findOption(tls, (argv + uintptr(2)*8), bp+232 /* &n */, ts+2510 /* "client" */, 1)
|
|
g.zErrLog = findOption(tls, (argv + uintptr(2)*8), bp+232 /* &n */, ts+2517 /* "errlog" */, 1)
|
|
g.zLog = findOption(tls, (argv + uintptr(2)*8), bp+232 /* &n */, ts+2524 /* "log" */, 1)
|
|
zTrace = findOption(tls, (argv + uintptr(2)*8), bp+232 /* &n */, ts+2528 /* "trace" */, 1)
|
|
if zTrace != 0 {
|
|
g.iTrace = libc.Xatoi(tls, zTrace)
|
|
}
|
|
if findOption(tls, (argv+uintptr(2)*8), bp+232 /* &n */, ts+2534 /* "quiet" */, 0) != uintptr(0) {
|
|
g.iTrace = 0
|
|
}
|
|
zTmout = findOption(tls, (argv + uintptr(2)*8), bp+232 /* &n */, ts+2540 /* "timeout" */, 1)
|
|
if zTmout != 0 {
|
|
iTmout = libc.Xatoi(tls, zTmout)
|
|
}
|
|
g.bSqlTrace = (libc.Bool32(findOption(tls, (argv+uintptr(2)*8), bp+232 /* &n */, ts+2548 /* "sqltrace" */, 0) != uintptr(0)))
|
|
g.bSync = (libc.Bool32(findOption(tls, (argv+uintptr(2)*8), bp+232 /* &n */, ts+2557 /* "sync" */, 0) != uintptr(0)))
|
|
if g.zErrLog != 0 {
|
|
g.pErrLog = libc.Xfopen(tls, g.zErrLog, ts+2562 /* "a" */)
|
|
} else {
|
|
g.pErrLog = libc.X__stderrp
|
|
}
|
|
if g.zLog != 0 {
|
|
g.pLog = libc.Xfopen(tls, g.zLog, ts+2562 /* "a" */)
|
|
} else {
|
|
g.pLog = libc.X__stdoutp
|
|
}
|
|
|
|
sqlite3.Xsqlite3_config(tls, SQLITE_CONFIG_LOG, libc.VaList(bp+24, *(*uintptr)(unsafe.Pointer(&struct {
|
|
f func(*libc.TLS, uintptr, int32, uintptr)
|
|
}{sqlErrorCallback})), 0))
|
|
if zClient != 0 {
|
|
iClient = libc.Xatoi(tls, zClient)
|
|
if iClient < 1 {
|
|
fatalError(tls, ts+2564 /* "illegal client n..." */, libc.VaList(bp+40, iClient))
|
|
}
|
|
sqlite3.Xsqlite3_snprintf(tls, int32(unsafe.Sizeof([32]int8{})), uintptr(unsafe.Pointer(&g))+64 /* &.zName */, ts+2591, /* "%05d.client%02d" */
|
|
libc.VaList(bp+48, libc.Xgetpid(tls), iClient))
|
|
} else {
|
|
var nTry int32 = 0
|
|
if g.iTrace > 0 {
|
|
libc.Xprintf(tls, ts+2607 /* "BEGIN: %s" */, libc.VaList(bp+64, *(*uintptr)(unsafe.Pointer(argv))))
|
|
for i = 1; i < argc; i++ {
|
|
libc.Xprintf(tls, ts+2317 /* " %s" */, libc.VaList(bp+72, *(*uintptr)(unsafe.Pointer(argv + uintptr(i)*8))))
|
|
}
|
|
libc.Xprintf(tls, ts+2321 /* "\n" */, 0)
|
|
libc.Xprintf(tls, ts+2617 /* "With SQLite 3.35..." */, 0)
|
|
for i = 0; (libc.AssignUintptr(&zCOption, sqlite3.Xsqlite3_compileoption_get(tls, i))) != uintptr(0); i++ {
|
|
libc.Xprintf(tls, ts+2722 /* "-DSQLITE_%s\n" */, libc.VaList(bp+80, zCOption))
|
|
}
|
|
libc.Xfflush(tls, libc.X__stdoutp)
|
|
}
|
|
iClient = 0
|
|
for ok := true; ok; ok = (((rc != 0) && ((libc.PreIncInt32(&nTry, 1)) < 60)) && (sqlite3.Xsqlite3_sleep(tls, 1000) > 0)) {
|
|
if (nTry % 5) == 4 {
|
|
libc.Xprintf(tls, ts+2735, /* "... %strying to ..." */
|
|
libc.VaList(bp+88, func() uintptr {
|
|
if nTry > 5 {
|
|
return ts + 2764 /* "still " */
|
|
}
|
|
return ts + 1099 /* "" */
|
|
}(), g.zDbFile))
|
|
}
|
|
rc = libc.Xunlink(tls, g.zDbFile)
|
|
if (rc != 0) && ((*(*int32)(unsafe.Pointer(libc.X__error(tls)))) == ENOENT) {
|
|
rc = 0
|
|
}
|
|
}
|
|
if rc != 0 {
|
|
fatalError(tls, ts+2771, /* "unable to unlink..." */
|
|
libc.VaList(bp+104, g.zDbFile, nTry))
|
|
}
|
|
openFlags = openFlags | (SQLITE_OPEN_CREATE)
|
|
}
|
|
rc = sqlite3.Xsqlite3_open_v2(tls, g.zDbFile, (uintptr(unsafe.Pointer(&g)) + 24 /* &.db */), openFlags, g.zVfs)
|
|
if rc != 0 {
|
|
fatalError(tls, ts+2812 /* "cannot open [%s]" */, libc.VaList(bp+120, g.zDbFile))
|
|
}
|
|
if iTmout > 0 {
|
|
sqlite3.Xsqlite3_busy_timeout(tls, g.db, iTmout)
|
|
}
|
|
|
|
if zJMode != 0 {
|
|
runSql(tls, ts+2829 /* "PRAGMA journal_m..." */, libc.VaList(bp+128, zJMode))
|
|
}
|
|
if !(g.bSync != 0) {
|
|
trySql(tls, ts+2853 /* "PRAGMA synchrono..." */, 0)
|
|
}
|
|
sqlite3.Xsqlite3_enable_load_extension(tls, g.db, 1)
|
|
sqlite3.Xsqlite3_busy_handler(tls, g.db, *(*uintptr)(unsafe.Pointer(&struct {
|
|
f func(*libc.TLS, uintptr, int32) int32
|
|
}{busyHandler})), uintptr(0))
|
|
sqlite3.Xsqlite3_create_function(tls, g.db, ts+2876 /* "vfsname" */, 0, SQLITE_UTF8, uintptr(0),
|
|
*(*uintptr)(unsafe.Pointer(&struct {
|
|
f func(*libc.TLS, uintptr, int32, uintptr)
|
|
}{vfsNameFunc})), uintptr(0), uintptr(0))
|
|
sqlite3.Xsqlite3_create_function(tls, g.db, ts+2884 /* "eval" */, 1, SQLITE_UTF8, uintptr(0),
|
|
*(*uintptr)(unsafe.Pointer(&struct {
|
|
f func(*libc.TLS, uintptr, int32, uintptr)
|
|
}{evalFunc})), uintptr(0), uintptr(0))
|
|
g.iTimeout = DEFAULT_TIMEOUT
|
|
if g.bSqlTrace != 0 {
|
|
sqlite3.Xsqlite3_trace(tls, g.db, *(*uintptr)(unsafe.Pointer(&struct {
|
|
f func(*libc.TLS, uintptr, uintptr)
|
|
}{sqlTraceCallback})), uintptr(0))
|
|
}
|
|
if iClient > 0 {
|
|
if *(*int32)(unsafe.Pointer(bp + 232 /* n */)) > 0 {
|
|
unrecognizedArguments(tls, *(*uintptr)(unsafe.Pointer(argv)), *(*int32)(unsafe.Pointer(bp + 232 /* n */)), (argv + uintptr(2)*8))
|
|
}
|
|
if g.iTrace != 0 {
|
|
logMessage(tls, ts+2889 /* "start-client" */, 0)
|
|
}
|
|
for 1 != 0 {
|
|
*(*uintptr)(unsafe.Pointer(bp + 256 /* zTaskName */)) = uintptr(0)
|
|
rc = startScript(tls, iClient, bp+240 /* &zScript */, bp+248 /* &taskId */, bp+256 /* &zTaskName */)
|
|
if rc == SQLITE_DONE {
|
|
break
|
|
}
|
|
if g.iTrace != 0 {
|
|
logMessage(tls, ts+2902 /* "begin %s (%d)" */, libc.VaList(bp+136, *(*uintptr)(unsafe.Pointer(bp + 256 /* zTaskName */)), *(*int32)(unsafe.Pointer(bp + 248 /* taskId */))))
|
|
}
|
|
runScript(tls, iClient, *(*int32)(unsafe.Pointer(bp + 248 /* taskId */)), *(*uintptr)(unsafe.Pointer(bp + 240 /* zScript */)), *(*uintptr)(unsafe.Pointer(bp + 256 /* zTaskName */)))
|
|
if g.iTrace != 0 {
|
|
logMessage(tls, ts+2916 /* "end %s (%d)" */, libc.VaList(bp+152, *(*uintptr)(unsafe.Pointer(bp + 256 /* zTaskName */)), *(*int32)(unsafe.Pointer(bp + 248 /* taskId */))))
|
|
}
|
|
finishScript(tls, iClient, *(*int32)(unsafe.Pointer(bp + 248 /* taskId */)), 0)
|
|
sqlite3.Xsqlite3_free(tls, *(*uintptr)(unsafe.Pointer(bp + 256 /* zTaskName */)))
|
|
sqlite3.Xsqlite3_sleep(tls, 10)
|
|
}
|
|
if g.iTrace != 0 {
|
|
logMessage(tls, ts+2928 /* "end-client" */, 0)
|
|
}
|
|
} else {
|
|
var pStmt uintptr
|
|
var iTimeout int32
|
|
if *(*int32)(unsafe.Pointer(bp + 232 /* n */)) == 0 {
|
|
fatalError(tls, ts+2939 /* "missing script f..." */, 0)
|
|
}
|
|
if *(*int32)(unsafe.Pointer(bp + 232 /* n */)) > 1 {
|
|
unrecognizedArguments(tls, *(*uintptr)(unsafe.Pointer(argv)), *(*int32)(unsafe.Pointer(bp + 232 /* n */)), (argv + uintptr(2)*8))
|
|
}
|
|
runSql(tls,
|
|
|
|
ts+2963 /* "DROP TABLE IF EX..." */, 0)
|
|
*(*uintptr)(unsafe.Pointer(bp + 240 /* zScript */)) = readFile(tls, *(*uintptr)(unsafe.Pointer(argv + 2*8)))
|
|
for iRep = 1; iRep <= nRep; iRep++ {
|
|
if g.iTrace != 0 {
|
|
logMessage(tls, ts+3399 /* "begin script [%s..." */, libc.VaList(bp+168, *(*uintptr)(unsafe.Pointer(argv + 2*8)), iRep))
|
|
}
|
|
runScript(tls, 0, 0, *(*uintptr)(unsafe.Pointer(bp + 240 /* zScript */)), *(*uintptr)(unsafe.Pointer(argv + 2*8)))
|
|
if g.iTrace != 0 {
|
|
logMessage(tls, ts+3427 /* "end script [%s] ..." */, libc.VaList(bp+184, *(*uintptr)(unsafe.Pointer(argv + 2*8)), iRep))
|
|
}
|
|
}
|
|
sqlite3.Xsqlite3_free(tls, *(*uintptr)(unsafe.Pointer(bp + 240 /* zScript */)))
|
|
waitForClient(tls, 0, 2000, ts+3453 /* "during shutdown...." */)
|
|
trySql(tls, ts+3473 /* "UPDATE client SE..." */, 0)
|
|
sqlite3.Xsqlite3_sleep(tls, 10)
|
|
g.iTimeout = 0
|
|
iTimeout = 1000
|
|
for (((libc.AssignInt32(&rc, trySql(tls, ts+3502 /* "SELECT 1 FROM cl..." */, 0))) == SQLITE_BUSY) ||
|
|
(rc == SQLITE_ROW)) && (iTimeout > 0) {
|
|
sqlite3.Xsqlite3_sleep(tls, 10)
|
|
iTimeout = iTimeout - (10)
|
|
}
|
|
sqlite3.Xsqlite3_sleep(tls, 100)
|
|
pStmt = prepareSql(tls, ts+3523 /* "SELECT nError, n..." */, 0)
|
|
iTimeout = 1000
|
|
for ((libc.AssignInt32(&rc, sqlite3.Xsqlite3_step(tls, pStmt))) == SQLITE_BUSY) && (iTimeout > 0) {
|
|
sqlite3.Xsqlite3_sleep(tls, 10)
|
|
iTimeout = iTimeout - (10)
|
|
}
|
|
if rc == SQLITE_ROW {
|
|
*(*int32)(unsafe.Pointer(uintptr(unsafe.Pointer(&g)) + 112 /* &.nError */)) += (sqlite3.Xsqlite3_column_int(tls, pStmt, 0))
|
|
*(*int32)(unsafe.Pointer(uintptr(unsafe.Pointer(&g)) + 116 /* &.nTest */)) += (sqlite3.Xsqlite3_column_int(tls, pStmt, 1))
|
|
}
|
|
sqlite3.Xsqlite3_finalize(tls, pStmt)
|
|
}
|
|
sqlite3.Xsqlite3_close(tls, g.db)
|
|
maybeClose(tls, g.pLog)
|
|
maybeClose(tls, g.pErrLog)
|
|
if iClient == 0 {
|
|
libc.Xprintf(tls, ts+3558 /* "Summary: %d erro..." */, libc.VaList(bp+200, g.nError, g.nTest))
|
|
libc.Xprintf(tls, ts+3594 /* "END: %s" */, libc.VaList(bp+216, *(*uintptr)(unsafe.Pointer(argv))))
|
|
for i = 1; i < argc; i++ {
|
|
libc.Xprintf(tls, ts+2317 /* " %s" */, libc.VaList(bp+224, *(*uintptr)(unsafe.Pointer(argv + uintptr(i)*8))))
|
|
}
|
|
libc.Xprintf(tls, ts+2321 /* "\n" */, 0)
|
|
}
|
|
return (libc.Bool32(g.nError > 0))
|
|
}
|
|
|
|
var ts1 = "%s%.*s\n\x00%s:ERROR: \x00%s:FATAL: \x00UPDATE client SET wantHalt=1;\x00%s: \x00main\x00timeout after %dms\x00[%.*s]\x00(info) %s\x00(errcode=%d) %s\x00%s\n%s\n\x00out of memory\x00 \x00nil\x00'\x00error(%d)\x00BEGIN IMMEDIATE\x00in startScript: %s\x00UPDATE counters SET nError=nError+%d, nTest=nTest+%d\x00SELECT 1 FROM client WHERE id=%d AND wantHalt\x00DELETE FROM client WHERE id=%d\x00COMMIT TRANSACTION;\x00SELECT script, id, name FROM task WHERE client=%d AND starttime IS NULL ORDER BY id LIMIT 1\x00%s\x00UPDATE task SET starttime=strftime('%%Y-%%m-%%d %%H:%%M:%%f','now') WHERE id=%d;\x00Waited over 30 seconds with no work. Giving up.\x00DELETE FROM client WHERE id=%d; COMMIT;\x00COMMIT\x00UPDATE task SET endtime=strftime('%%Y-%%m-%%d %%H:%%M:%%f','now') WHERE id=%d;\x00INSERT OR IGNORE INTO client VALUES(%d,0)\x00%s \"%s\" --client %d --trace %d\x00%z --sqltrace\x00%z --sync\x00%z --vfs \"%s\"\x00system('%q')\x00%z &\x00system() fails with error code %d\x00rb\x00cannot open \"%s\" for reading\x00--end\x00--endif\x00--else\x00--if\x00SELECT 1 FROM task WHERE client=%d AND client IN (SELECT id FROM client) AND endtime IS NULL\x00SELECT 1 FROM task WHERE client IN (SELECT id FROM client) AND endtime IS NULL\x00\x00%stimeout waiting for client %d\x00%stimeout waiting for all clients\x00on\x00yes\x00off\x00no\x00unknown boolean: [%s]\x00%.*s\x00sleep\x00exit\x00testcase\x00finish\x00reset\x00match\x00line %d of %s:\nExpected [%.*s]\n Got [%s]\x00glob\x00notglob\x00line %d of %s:\nExpected [%s]\n Got [%s]\x00output\x00source\x00%.*s/%s\x00begin script [%s]\n\x00end script [%s]\n\x00print\x00if\x00SELECT %.*s\x00else\x00endif\x00start\x00wait\x00line %d of %s\n\x00task\x00line %d of %s: bad client number: %d\x00%s:%d\x00INSERT INTO task(client,script,name) VALUES(%d,'%q',%Q)\x00breakpoint\x00show-sql-errors\x00line %d of %s: unknown command --%s\x00command-line option \"--%s\" requires an argument\x00Usage: %s DATABASE ?OPTIONS? ?SCRIPT?\n\x00Options:\n --errlog FILENAME Write errors to FILENAME\n --journalmode MODE Use MODE as the journal_mode\n --log FILENAME Log messages to FILENAME\n --quiet Suppress unnecessary output\n --vfs NAME Use NAME as the VFS\n --repeat N Repeat the test N times\n --sqltrace Enable SQL tracing\n --sync Enable synchronous disk writes\n --timeout MILLISEC Busy timeout is MILLISEC\n --trace BOOLEAN Enable or disable tracing\n\x00%s: unrecognized arguments:\x00 %s\x00\n\x00*.test\x002021-04-19 18:32:05 1b256d97b553a9611efca188a3d995a2fff712759044ba480f9a0c9e98fae886\x00SQLite library and header mismatch\nLibrary: %s\nHeader: %s\n\x00%05d.mptest\x00journalmode\x00repeat\x00vfs\x00client\x00errlog\x00log\x00trace\x00quiet\x00timeout\x00sqltrace\x00sync\x00a\x00illegal client number: %d\n\x00%05d.client%02d\x00BEGIN: %s\x00With SQLite 3.35.5 2021-04-19 18:32:05 1b256d97b553a9611efca188a3d995a2fff712759044ba480f9a0c9e98fae886\n\x00-DSQLITE_%s\n\x00... %strying to unlink '%s'\n\x00still \x00unable to unlink '%s' after %d attempts\n\x00cannot open [%s]\x00PRAGMA journal_mode=%Q;\x00PRAGMA synchronous=OFF\x00vfsname\x00eval\x00start-client\x00begin %s (%d)\x00end %s (%d)\x00end-client\x00missing script filename\x00DROP TABLE IF EXISTS task;\nDROP TABLE IF EXISTS counters;\nDROP TABLE IF EXISTS client;\nCREATE TABLE task(\n id INTEGER PRIMARY KEY,\n name TEXT,\n client INTEGER,\n starttime DATE,\n endtime DATE,\n script TEXT\n);CREATE INDEX task_i1 ON task(client, starttime);\nCREATE INDEX task_i2 ON task(client, endtime);\nCREATE TABLE counters(nError,nTest);\nINSERT INTO counters VALUES(0,0);\nCREATE TABLE client(id INTEGER PRIMARY KEY, wantHalt);\n\x00begin script [%s] cycle %d\n\x00end script [%s] cycle %d\n\x00during shutdown...\n\x00UPDATE client SET wantHalt=1\x00SELECT 1 FROM client\x00SELECT nError, nTest FROM counters\x00Summary: %d errors out of %d tests\n\x00END: %s\x00"
|
|
var ts = (*reflect.StringHeader)(unsafe.Pointer(&ts1)).Data
|