socket_netbsd_amd64.go 37 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863
  1. // Code generated by 'ccgo sys/socket/gen.c -crt-import-path "" -export-defines "" -export-enums "" -export-externs X -export-fields F -export-structs "" -export-typedefs "" -header -hide _OSSwapInt16,_OSSwapInt32,_OSSwapInt64 -ignore-unsupported-alignment -o sys/socket/socket_netbsd_amd64.go -pkgname socket', DO NOT EDIT.
  2. package socket
  3. import (
  4. "math"
  5. "reflect"
  6. "sync/atomic"
  7. "unsafe"
  8. )
  9. var _ = math.Pi
  10. var _ reflect.Kind
  11. var _ atomic.Value
  12. var _ unsafe.Pointer
  13. const (
  14. AF_APPLETALK = 16 // socket.h:218:1:
  15. AF_ARP = 28 // socket.h:237:1:
  16. AF_BLUETOOTH = 31 // socket.h:243:1:
  17. AF_CAN = 35 // socket.h:247:1:
  18. AF_CCITT = 10 // socket.h:212:1:
  19. AF_CHAOS = 5 // socket.h:206:1:
  20. AF_CNT = 21 // socket.h:225:1:
  21. AF_COIP = 20 // socket.h:224:1:
  22. AF_DATAKIT = 9 // socket.h:211:1:
  23. AF_DECnet = 12 // socket.h:214:1:
  24. AF_DLI = 13 // socket.h:215:1:
  25. AF_E164 = 26 // socket.h:235:1:
  26. AF_ECMA = 8 // socket.h:210:1:
  27. AF_ETHER = 36 // socket.h:248:1:
  28. AF_HYLINK = 15 // socket.h:217:1:
  29. AF_IEEE80211 = 32 // socket.h:244:1:
  30. AF_IMPLINK = 3 // socket.h:204:1:
  31. AF_INET = 2 // socket.h:203:1:
  32. AF_INET6 = 24 // socket.h:230:1:
  33. AF_IPX = 23 // socket.h:229:1:
  34. AF_ISDN = 26 // socket.h:234:1:
  35. AF_ISO = 7 // socket.h:208:1:
  36. AF_LAT = 14 // socket.h:216:1:
  37. AF_LINK = 18 // socket.h:220:1:
  38. AF_LOCAL = 1 // socket.h:201:1:
  39. AF_MAX = 37 // socket.h:249:1:
  40. AF_MPLS = 33 // socket.h:245:1:
  41. AF_NATM = 27 // socket.h:236:1:
  42. AF_NS = 6 // socket.h:207:1:
  43. AF_OROUTE = 17 // socket.h:219:1:
  44. AF_OSI = 7 // socket.h:209:1:
  45. AF_PUP = 4 // socket.h:205:1:
  46. AF_ROUTE = 34 // socket.h:246:1:
  47. AF_SNA = 11 // socket.h:213:1:
  48. AF_UNIX = 1 // socket.h:202:1:
  49. AF_UNSPEC = 0 // socket.h:200:1:
  50. MSG_BCAST = 0x0100 // socket.h:497:1:
  51. MSG_CMSG_CLOEXEC = 0x0800 // socket.h:501:1:
  52. MSG_CONTROLMBUF = 0x2000000 // socket.h:515:1:
  53. MSG_CTRUNC = 0x0020 // socket.h:494:1:
  54. MSG_DONTROUTE = 0x0004 // socket.h:491:1:
  55. MSG_DONTWAIT = 0x0080 // socket.h:496:1:
  56. MSG_EOR = 0x0008 // socket.h:492:1:
  57. MSG_IOVUSRSPACE = 0x4000000 // socket.h:516:1:
  58. MSG_LENUSRSPACE = 0x8000000 // socket.h:517:1:
  59. MSG_MCAST = 0x0200 // socket.h:498:1:
  60. MSG_NAMEMBUF = 0x1000000 // socket.h:514:1:
  61. MSG_NBIO = 0x1000 // socket.h:502:1:
  62. MSG_NOSIGNAL = 0x0400 // socket.h:499:1:
  63. MSG_NOTIFICATION = 0x4000 // socket.h:504:1:
  64. MSG_OOB = 0x0001 // socket.h:489:1:
  65. MSG_PEEK = 0x0002 // socket.h:490:1:
  66. MSG_TRUNC = 0x0010 // socket.h:493:1:
  67. MSG_USERFLAGS = 0x0ffffff // socket.h:513:1:
  68. MSG_WAITALL = 0x0040 // socket.h:495:1:
  69. MSG_WAITFORONE = 0x2000 // socket.h:503:1:
  70. NET_RT_DUMP = 1 // socket.h:457:1:
  71. NET_RT_FLAGS = 2 // socket.h:458:1:
  72. NET_RT_IFLIST = 6 // socket.h:462:1:
  73. NET_RT_OIFLIST = 5 // socket.h:461:1:
  74. NET_RT_OOIFLIST = 4 // socket.h:460:1:
  75. NET_RT_OOOIFLIST = 3 // socket.h:459:1:
  76. PCB_ALL = 0 // socket.h:444:1:
  77. PCB_SLOP = 20 // socket.h:443:1:
  78. PF_APPLETALK = 16 // socket.h:334:1:
  79. PF_ARP = 28 // socket.h:351:1:
  80. PF_BLUETOOTH = 31 // socket.h:355:1:
  81. PF_CAN = 35 // socket.h:358:1:
  82. PF_CCITT = 10 // socket.h:328:1:
  83. PF_CHAOS = 5 // socket.h:322:1:
  84. PF_CNT = 21 // socket.h:341:1:
  85. PF_COIP = 20 // socket.h:340:1:
  86. PF_DATAKIT = 9 // socket.h:327:1:
  87. PF_DECnet = 12 // socket.h:330:1:
  88. PF_DLI = 13 // socket.h:331:1:
  89. PF_E164 = 26 // socket.h:349:1:
  90. PF_ECMA = 8 // socket.h:326:1:
  91. PF_ETHER = 36 // socket.h:359:1:
  92. PF_HYLINK = 15 // socket.h:333:1:
  93. PF_IMPLINK = 3 // socket.h:320:1:
  94. PF_INET = 2 // socket.h:319:1:
  95. PF_INET6 = 24 // socket.h:342:1:
  96. PF_IPX = 23 // socket.h:343:1:
  97. PF_ISDN = 26 // socket.h:348:1:
  98. PF_ISO = 7 // socket.h:324:1:
  99. PF_KEY = 29 // socket.h:353:1:
  100. PF_LAT = 14 // socket.h:332:1:
  101. PF_LINK = 18 // socket.h:336:1:
  102. PF_LOCAL = 1 // socket.h:317:1:
  103. PF_MAX = 37 // socket.h:361:1:
  104. PF_MPLS = 33 // socket.h:356:1:
  105. PF_NATM = 27 // socket.h:350:1:
  106. PF_NS = 6 // socket.h:323:1:
  107. PF_OROUTE = 17 // socket.h:335:1:
  108. PF_OSI = 7 // socket.h:325:1:
  109. PF_PIP = 25 // socket.h:346:1:
  110. PF_PUP = 4 // socket.h:321:1:
  111. PF_ROUTE = 34 // socket.h:357:1:
  112. PF_RTIP = 22 // socket.h:345:1:
  113. PF_SNA = 11 // socket.h:329:1:
  114. PF_UNIX = 1 // socket.h:318:1:
  115. PF_UNSPEC = 0 // socket.h:316:1:
  116. PF_XTP = 19 // socket.h:338:1:
  117. SCM_CREDS = 0x10 // socket.h:581:1:
  118. SCM_RIGHTS = 0x01 // socket.h:576:1:
  119. SCM_TIMESTAMP = 0x08 // socket.h:580:1:
  120. SHUT_RD = 0 // socket.h:587:1:
  121. SHUT_RDWR = 2 // socket.h:589:1:
  122. SHUT_WR = 1 // socket.h:588:1:
  123. SOCK_CLOEXEC = 0x10000000 // socket.h:113:1:
  124. SOCK_CONN_DGRAM = 6 // socket.h:110:1:
  125. SOCK_DCCP = 6 // socket.h:111:1:
  126. SOCK_DGRAM = 2 // socket.h:106:1:
  127. SOCK_FLAGS_MASK = 0xf0000000 // socket.h:116:1:
  128. SOCK_NONBLOCK = 0x20000000 // socket.h:114:1:
  129. SOCK_NOSIGPIPE = 0x40000000 // socket.h:115:1:
  130. SOCK_RAW = 3 // socket.h:107:1:
  131. SOCK_RDM = 4 // socket.h:108:1:
  132. SOCK_SEQPACKET = 5 // socket.h:109:1:
  133. SOCK_STREAM = 1 // socket.h:105:1:
  134. SOL_SOCKET = 0xffff // socket.h:195:1:
  135. SOMAXCONN = 128 // socket.h:470:1:
  136. SO_ACCEPTCONN = 0x0002 // socket.h:122:1:
  137. SO_ACCEPTFILTER = 0x1000 // socket.h:133:1:
  138. SO_BROADCAST = 0x0020 // socket.h:126:1:
  139. SO_DEBUG = 0x0001 // socket.h:121:1:
  140. SO_DEFOPTS = 27645 // socket.h:138:1:
  141. SO_DONTROUTE = 0x0010 // socket.h:125:1:
  142. SO_ERROR = 0x1007 // socket.h:169:1:
  143. SO_KEEPALIVE = 0x0008 // socket.h:124:1:
  144. SO_LINGER = 0x0080 // socket.h:128:1:
  145. SO_NOHEADER = 0x100a // socket.h:173:1:
  146. SO_NOSIGPIPE = 0x0800 // socket.h:132:1:
  147. SO_OOBINLINE = 0x0100 // socket.h:129:1:
  148. SO_OVERFLOWED = 0x1009 // socket.h:171:1:
  149. SO_RCVBUF = 0x1002 // socket.h:164:1:
  150. SO_RCVLOWAT = 0x1004 // socket.h:166:1:
  151. SO_RCVTIMEO = 0x100c // socket.h:178:1:
  152. SO_RERROR = 0x4000 // socket.h:135:1:
  153. SO_REUSEADDR = 0x0004 // socket.h:123:1:
  154. SO_REUSEPORT = 0x0200 // socket.h:130:1:
  155. SO_SNDBUF = 0x1001 // socket.h:163:1:
  156. SO_SNDLOWAT = 0x1003 // socket.h:165:1:
  157. SO_SNDTIMEO = 0x100b // socket.h:177:1:
  158. SO_TIMESTAMP = 0x2000 // socket.h:134:1:
  159. SO_TYPE = 0x1008 // socket.h:170:1:
  160. SO_USELOOPBACK = 0x0040 // socket.h:127:1:
  161. UIO_MAXIOV = 1024 // uio.h:97:1:
  162. X_AMD64_INT_TYPES_H_ = 0 // int_types.h:35:1:
  163. X_FILE_OFFSET_BITS = 64 // <builtin>:25:1:
  164. X_LP64 = 1 // <predefined>:268:1:
  165. X_NETBSD_SOURCE = 1 // featuretest.h:70:1:
  166. X_SS_MAXSIZE = 128 // socket.h:294:1:
  167. X_SYS_ANSI_H_ = 0 // ansi.h:33:1:
  168. X_SYS_CDEFS_ELF_H_ = 0 // cdefs_elf.h:31:1:
  169. X_SYS_CDEFS_H_ = 0 // cdefs.h:37:1:
  170. X_SYS_COMMON_ANSI_H_ = 0 // common_ansi.h:33:1:
  171. X_SYS_COMMON_INT_TYPES_H_ = 0 // common_int_types.h:33:1:
  172. X_SYS_SIGTYPES_H_ = 0 // sigtypes.h:40:1:
  173. X_SYS_SOCKET_H_ = 0 // socket.h:64:1:
  174. X_SYS_UIO_H_ = 0 // uio.h:35:1:
  175. X_X86_64_CDEFS_H_ = 0 // cdefs.h:4:1:
  176. Pseudo_AF_HDRCMPLT = 30 // socket.h:240:1:
  177. Pseudo_AF_KEY = 29 // socket.h:239:1:
  178. Pseudo_AF_PIP = 25 // socket.h:232:1:
  179. Pseudo_AF_RTIP = 22 // socket.h:227:1:
  180. Pseudo_AF_XTP = 19 // socket.h:222:1:
  181. )
  182. // file offset
  183. const ( /* uio.h:69:1: */
  184. UIO_READ = 0
  185. UIO_WRITE = 1
  186. )
  187. // Segment flag values.
  188. const ( /* uio.h:72:1: */
  189. UIO_USERSPACE = 0 // from user data space
  190. UIO_SYSSPACE = 1
  191. )
  192. type Ptrdiff_t = int64 /* <builtin>:3:26 */
  193. type Size_t = uint64 /* <builtin>:9:23 */
  194. type Wchar_t = int32 /* <builtin>:15:24 */
  195. type X__int128_t = struct {
  196. Flo int64
  197. Fhi int64
  198. } /* <builtin>:21:43 */ // must match modernc.org/mathutil.Int128
  199. type X__uint128_t = struct {
  200. Flo uint64
  201. Fhi uint64
  202. } /* <builtin>:22:44 */ // must match modernc.org/mathutil.Int128
  203. type X__builtin_va_list = uintptr /* <builtin>:46:14 */
  204. type X__float128 = float64 /* <builtin>:47:21 */
  205. // return true if value 'a' fits in type 't'
  206. // $NetBSD: int_types.h,v 1.7 2014/07/25 21:43:13 joerg Exp $
  207. // -
  208. // Copyright (c) 1990 The Regents of the University of California.
  209. // All rights reserved.
  210. //
  211. // Redistribution and use in source and binary forms, with or without
  212. // modification, are permitted provided that the following conditions
  213. // are met:
  214. // 1. Redistributions of source code must retain the above copyright
  215. // notice, this list of conditions and the following disclaimer.
  216. // 2. Redistributions in binary form must reproduce the above copyright
  217. // notice, this list of conditions and the following disclaimer in the
  218. // documentation and/or other materials provided with the distribution.
  219. // 3. Neither the name of the University nor the names of its contributors
  220. // may be used to endorse or promote products derived from this software
  221. // without specific prior written permission.
  222. //
  223. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  224. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  225. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  226. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  227. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  228. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  229. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  230. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  231. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  232. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  233. // SUCH DAMAGE.
  234. //
  235. // from: @(#)types.h 7.5 (Berkeley) 3/9/91
  236. // $NetBSD: common_int_types.h,v 1.1 2014/07/25 21:43:13 joerg Exp $
  237. // -
  238. // Copyright (c) 2014 The NetBSD Foundation, Inc.
  239. // All rights reserved.
  240. //
  241. // This code is derived from software contributed to The NetBSD Foundation
  242. // by Joerg Sonnenberger.
  243. //
  244. // Redistribution and use in source and binary forms, with or without
  245. // modification, are permitted provided that the following conditions
  246. // are met:
  247. // 1. Redistributions of source code must retain the above copyright
  248. // notice, this list of conditions and the following disclaimer.
  249. // 2. Redistributions in binary form must reproduce the above copyright
  250. // notice, this list of conditions and the following disclaimer in the
  251. // documentation and/or other materials provided with the distribution.
  252. //
  253. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  254. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  255. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  256. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  257. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  258. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  259. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  260. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  261. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  262. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  263. // POSSIBILITY OF SUCH DAMAGE.
  264. // 7.18.1 Integer types
  265. // 7.18.1.1 Exact-width integer types
  266. type X__int8_t = int8 /* common_int_types.h:45:27 */
  267. type X__uint8_t = uint8 /* common_int_types.h:46:27 */
  268. type X__int16_t = int16 /* common_int_types.h:47:27 */
  269. type X__uint16_t = uint16 /* common_int_types.h:48:27 */
  270. type X__int32_t = int32 /* common_int_types.h:49:27 */
  271. type X__uint32_t = uint32 /* common_int_types.h:50:27 */
  272. type X__int64_t = int64 /* common_int_types.h:51:27 */
  273. type X__uint64_t = uint64 /* common_int_types.h:52:27 */
  274. // 7.18.1.4 Integer types capable of holding object pointers
  275. type X__intptr_t = int64 /* common_int_types.h:58:27 */
  276. type X__uintptr_t = uint64 /* common_int_types.h:59:26 */
  277. // Types which are fundamental to the implementation and may appear in
  278. // more than one standard header are defined here. Standard headers
  279. // then use:
  280. // #ifdef _BSD_SIZE_T_
  281. // typedef _BSD_SIZE_T_ size_t;
  282. // #undef _BSD_SIZE_T_
  283. // #endif
  284. type X__caddr_t = uintptr /* ansi.h:37:14 */ // core address
  285. type X__gid_t = X__uint32_t /* ansi.h:38:20 */ // group id
  286. type X__in_addr_t = X__uint32_t /* ansi.h:39:20 */ // IP(v4) address
  287. type X__in_port_t = X__uint16_t /* ansi.h:40:20 */ // "Internet" port number
  288. type X__mode_t = X__uint32_t /* ansi.h:41:20 */ // file permissions
  289. type X__off_t = X__int64_t /* ansi.h:42:19 */ // file offset
  290. type X__pid_t = X__int32_t /* ansi.h:43:19 */ // process id
  291. type X__sa_family_t = X__uint8_t /* ansi.h:44:19 */ // socket address family
  292. type X__socklen_t = uint32 /* ansi.h:45:22 */ // socket-related datum length
  293. type X__uid_t = X__uint32_t /* ansi.h:46:20 */ // user id
  294. type X__fsblkcnt_t = X__uint64_t /* ansi.h:47:20 */ // fs block count (statvfs)
  295. type X__fsfilcnt_t = X__uint64_t /* ansi.h:48:20 */
  296. type X__wctrans_t = uintptr /* ansi.h:51:32 */
  297. type X__wctype_t = uintptr /* ansi.h:54:31 */
  298. // mbstate_t is an opaque object to keep conversion state, during multibyte
  299. // stream conversions. The content must not be referenced by user programs.
  300. type X__mbstate_t = struct {
  301. F__mbstateL X__int64_t
  302. F__ccgo_pad1 [120]byte
  303. } /* ansi.h:63:3 */
  304. type X__va_list = X__builtin_va_list /* ansi.h:72:27 */
  305. type Sa_family_t = X__sa_family_t /* socket.h:78:23 */
  306. type Socklen_t = X__socklen_t /* socket.h:83:21 */
  307. type Ssize_t = int64 /* socket.h:95:23 */
  308. // $NetBSD: uio.h,v 1.36 2011/07/27 13:20:07 uebayasi Exp $
  309. // Copyright (c) 1982, 1986, 1993, 1994
  310. // The Regents of the University of California. All rights reserved.
  311. //
  312. // Redistribution and use in source and binary forms, with or without
  313. // modification, are permitted provided that the following conditions
  314. // are met:
  315. // 1. Redistributions of source code must retain the above copyright
  316. // notice, this list of conditions and the following disclaimer.
  317. // 2. Redistributions in binary form must reproduce the above copyright
  318. // notice, this list of conditions and the following disclaimer in the
  319. // documentation and/or other materials provided with the distribution.
  320. // 3. Neither the name of the University nor the names of its contributors
  321. // may be used to endorse or promote products derived from this software
  322. // without specific prior written permission.
  323. //
  324. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  325. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  326. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  327. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  328. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  329. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  330. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  331. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  332. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  333. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  334. // SUCH DAMAGE.
  335. //
  336. // @(#)uio.h 8.5 (Berkeley) 2/22/94
  337. // $NetBSD: ansi.h,v 1.11 2019/05/07 03:49:26 kamil Exp $
  338. // $NetBSD: common_ansi.h,v 1.1 2014/08/19 07:27:31 matt Exp $
  339. // -
  340. // Copyright (c) 2014 The NetBSD Foundation, Inc.
  341. // All rights reserved.
  342. //
  343. // This code is derived from software contributed to The NetBSD Foundation
  344. // by Matt Thomas of 3am Software Foundry.
  345. //
  346. // Redistribution and use in source and binary forms, with or without
  347. // modification, are permitted provided that the following conditions
  348. // are met:
  349. // 1. Redistributions of source code must retain the above copyright
  350. // notice, this list of conditions and the following disclaimer.
  351. // 2. Redistributions in binary form must reproduce the above copyright
  352. // notice, this list of conditions and the following disclaimer in the
  353. // documentation and/or other materials provided with the distribution.
  354. //
  355. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  356. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  357. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  358. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  359. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  360. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  361. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  362. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  363. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  364. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  365. // POSSIBILITY OF SUCH DAMAGE.
  366. // $NetBSD: featuretest.h,v 1.10 2013/04/26 18:29:06 christos Exp $
  367. // Written by Klaus Klein <kleink@NetBSD.org>, February 2, 1998.
  368. // Public domain.
  369. //
  370. // NOTE: Do not protect this header against multiple inclusion. Doing
  371. // so can have subtle side-effects due to header file inclusion order
  372. // and testing of e.g. _POSIX_SOURCE vs. _POSIX_C_SOURCE. Instead,
  373. // protect each CPP macro that we want to supply.
  374. // Feature-test macros are defined by several standards, and allow an
  375. // application to specify what symbols they want the system headers to
  376. // expose, and hence what standard they want them to conform to.
  377. // There are two classes of feature-test macros. The first class
  378. // specify complete standards, and if one of these is defined, header
  379. // files will try to conform to the relevant standard. They are:
  380. //
  381. // ANSI macros:
  382. // _ANSI_SOURCE ANSI C89
  383. //
  384. // POSIX macros:
  385. // _POSIX_SOURCE == 1 IEEE Std 1003.1 (version?)
  386. // _POSIX_C_SOURCE == 1 IEEE Std 1003.1-1990
  387. // _POSIX_C_SOURCE == 2 IEEE Std 1003.2-1992
  388. // _POSIX_C_SOURCE == 199309L IEEE Std 1003.1b-1993
  389. // _POSIX_C_SOURCE == 199506L ISO/IEC 9945-1:1996
  390. // _POSIX_C_SOURCE == 200112L IEEE Std 1003.1-2001
  391. // _POSIX_C_SOURCE == 200809L IEEE Std 1003.1-2008
  392. //
  393. // X/Open macros:
  394. // _XOPEN_SOURCE System Interfaces and Headers, Issue 4, Ver 2
  395. // _XOPEN_SOURCE_EXTENDED == 1 XSH4.2 UNIX extensions
  396. // _XOPEN_SOURCE == 500 System Interfaces and Headers, Issue 5
  397. // _XOPEN_SOURCE == 520 Networking Services (XNS), Issue 5.2
  398. // _XOPEN_SOURCE == 600 IEEE Std 1003.1-2001, XSI option
  399. // _XOPEN_SOURCE == 700 IEEE Std 1003.1-2008, XSI option
  400. //
  401. // NetBSD macros:
  402. // _NETBSD_SOURCE == 1 Make all NetBSD features available.
  403. //
  404. // If more than one of these "major" feature-test macros is defined,
  405. // then the set of facilities provided (and namespace used) is the
  406. // union of that specified by the relevant standards, and in case of
  407. // conflict, the earlier standard in the above list has precedence (so
  408. // if both _POSIX_C_SOURCE and _NETBSD_SOURCE are defined, the version
  409. // of rename() that's used is the POSIX one). If none of the "major"
  410. // feature-test macros is defined, _NETBSD_SOURCE is assumed.
  411. //
  412. // There are also "minor" feature-test macros, which enable extra
  413. // functionality in addition to some base standard. They should be
  414. // defined along with one of the "major" macros. The "minor" macros
  415. // are:
  416. //
  417. // _REENTRANT
  418. // _ISOC99_SOURCE
  419. // _ISOC11_SOURCE
  420. // _LARGEFILE_SOURCE Large File Support
  421. // <http://ftp.sas.com/standards/large.file/x_open.20Mar96.html>
  422. type Iovec = struct {
  423. Fiov_base uintptr
  424. Fiov_len Size_t
  425. } /* uio.h:56:1 */
  426. // $NetBSD: ansi.h,v 1.14 2011/07/17 20:54:54 joerg Exp $
  427. // -
  428. // Copyright (c) 2000, 2001, 2002 The NetBSD Foundation, Inc.
  429. // All rights reserved.
  430. //
  431. // This code is derived from software contributed to The NetBSD Foundation
  432. // by Jun-ichiro itojun Hagino and by Klaus Klein.
  433. //
  434. // Redistribution and use in source and binary forms, with or without
  435. // modification, are permitted provided that the following conditions
  436. // are met:
  437. // 1. Redistributions of source code must retain the above copyright
  438. // notice, this list of conditions and the following disclaimer.
  439. // 2. Redistributions in binary form must reproduce the above copyright
  440. // notice, this list of conditions and the following disclaimer in the
  441. // documentation and/or other materials provided with the distribution.
  442. //
  443. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  444. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  445. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  446. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  447. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  448. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  449. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  450. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  451. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  452. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  453. // POSSIBILITY OF SUCH DAMAGE.
  454. type Off_t = X__off_t /* uio.h:65:18 */
  455. // $NetBSD: sigtypes.h,v 1.11 2017/01/12 18:29:14 christos Exp $
  456. // Copyright (c) 1982, 1986, 1989, 1991, 1993
  457. // The Regents of the University of California. All rights reserved.
  458. // (c) UNIX System Laboratories, Inc.
  459. // All or some portions of this file are derived from material licensed
  460. // to the University of California by American Telephone and Telegraph
  461. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  462. // the permission of UNIX System Laboratories, Inc.
  463. //
  464. // Redistribution and use in source and binary forms, with or without
  465. // modification, are permitted provided that the following conditions
  466. // are met:
  467. // 1. Redistributions of source code must retain the above copyright
  468. // notice, this list of conditions and the following disclaimer.
  469. // 2. Redistributions in binary form must reproduce the above copyright
  470. // notice, this list of conditions and the following disclaimer in the
  471. // documentation and/or other materials provided with the distribution.
  472. // 3. Neither the name of the University nor the names of its contributors
  473. // may be used to endorse or promote products derived from this software
  474. // without specific prior written permission.
  475. //
  476. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  477. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  478. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  479. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  480. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  481. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  482. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  483. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  484. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  485. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  486. // SUCH DAMAGE.
  487. //
  488. // @(#)signal.h 8.4 (Berkeley) 5/4/95
  489. // This header file defines various signal-related types. We also keep
  490. // the macros to manipulate sigset_t here, to encapsulate knowledge of
  491. // its internals.
  492. // $NetBSD: featuretest.h,v 1.10 2013/04/26 18:29:06 christos Exp $
  493. // Written by Klaus Klein <kleink@NetBSD.org>, February 2, 1998.
  494. // Public domain.
  495. //
  496. // NOTE: Do not protect this header against multiple inclusion. Doing
  497. // so can have subtle side-effects due to header file inclusion order
  498. // and testing of e.g. _POSIX_SOURCE vs. _POSIX_C_SOURCE. Instead,
  499. // protect each CPP macro that we want to supply.
  500. // Feature-test macros are defined by several standards, and allow an
  501. // application to specify what symbols they want the system headers to
  502. // expose, and hence what standard they want them to conform to.
  503. // There are two classes of feature-test macros. The first class
  504. // specify complete standards, and if one of these is defined, header
  505. // files will try to conform to the relevant standard. They are:
  506. //
  507. // ANSI macros:
  508. // _ANSI_SOURCE ANSI C89
  509. //
  510. // POSIX macros:
  511. // _POSIX_SOURCE == 1 IEEE Std 1003.1 (version?)
  512. // _POSIX_C_SOURCE == 1 IEEE Std 1003.1-1990
  513. // _POSIX_C_SOURCE == 2 IEEE Std 1003.2-1992
  514. // _POSIX_C_SOURCE == 199309L IEEE Std 1003.1b-1993
  515. // _POSIX_C_SOURCE == 199506L ISO/IEC 9945-1:1996
  516. // _POSIX_C_SOURCE == 200112L IEEE Std 1003.1-2001
  517. // _POSIX_C_SOURCE == 200809L IEEE Std 1003.1-2008
  518. //
  519. // X/Open macros:
  520. // _XOPEN_SOURCE System Interfaces and Headers, Issue 4, Ver 2
  521. // _XOPEN_SOURCE_EXTENDED == 1 XSH4.2 UNIX extensions
  522. // _XOPEN_SOURCE == 500 System Interfaces and Headers, Issue 5
  523. // _XOPEN_SOURCE == 520 Networking Services (XNS), Issue 5.2
  524. // _XOPEN_SOURCE == 600 IEEE Std 1003.1-2001, XSI option
  525. // _XOPEN_SOURCE == 700 IEEE Std 1003.1-2008, XSI option
  526. //
  527. // NetBSD macros:
  528. // _NETBSD_SOURCE == 1 Make all NetBSD features available.
  529. //
  530. // If more than one of these "major" feature-test macros is defined,
  531. // then the set of facilities provided (and namespace used) is the
  532. // union of that specified by the relevant standards, and in case of
  533. // conflict, the earlier standard in the above list has precedence (so
  534. // if both _POSIX_C_SOURCE and _NETBSD_SOURCE are defined, the version
  535. // of rename() that's used is the POSIX one). If none of the "major"
  536. // feature-test macros is defined, _NETBSD_SOURCE is assumed.
  537. //
  538. // There are also "minor" feature-test macros, which enable extra
  539. // functionality in addition to some base standard. They should be
  540. // defined along with one of the "major" macros. The "minor" macros
  541. // are:
  542. //
  543. // _REENTRANT
  544. // _ISOC99_SOURCE
  545. // _ISOC11_SOURCE
  546. // _LARGEFILE_SOURCE Large File Support
  547. // <http://ftp.sas.com/standards/large.file/x_open.20Mar96.html>
  548. // $NetBSD: int_types.h,v 1.7 2014/07/25 21:43:13 joerg Exp $
  549. // -
  550. // Copyright (c) 1990 The Regents of the University of California.
  551. // All rights reserved.
  552. //
  553. // Redistribution and use in source and binary forms, with or without
  554. // modification, are permitted provided that the following conditions
  555. // are met:
  556. // 1. Redistributions of source code must retain the above copyright
  557. // notice, this list of conditions and the following disclaimer.
  558. // 2. Redistributions in binary form must reproduce the above copyright
  559. // notice, this list of conditions and the following disclaimer in the
  560. // documentation and/or other materials provided with the distribution.
  561. // 3. Neither the name of the University nor the names of its contributors
  562. // may be used to endorse or promote products derived from this software
  563. // without specific prior written permission.
  564. //
  565. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  566. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  567. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  568. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  569. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  570. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  571. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  572. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  573. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  574. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  575. // SUCH DAMAGE.
  576. //
  577. // from: @(#)types.h 7.5 (Berkeley) 3/9/91
  578. // $NetBSD: ansi.h,v 1.11 2019/05/07 03:49:26 kamil Exp $
  579. // $NetBSD: common_ansi.h,v 1.1 2014/08/19 07:27:31 matt Exp $
  580. // -
  581. // Copyright (c) 2014 The NetBSD Foundation, Inc.
  582. // All rights reserved.
  583. //
  584. // This code is derived from software contributed to The NetBSD Foundation
  585. // by Matt Thomas of 3am Software Foundry.
  586. //
  587. // Redistribution and use in source and binary forms, with or without
  588. // modification, are permitted provided that the following conditions
  589. // are met:
  590. // 1. Redistributions of source code must retain the above copyright
  591. // notice, this list of conditions and the following disclaimer.
  592. // 2. Redistributions in binary form must reproduce the above copyright
  593. // notice, this list of conditions and the following disclaimer in the
  594. // documentation and/or other materials provided with the distribution.
  595. //
  596. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  597. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  598. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  599. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  600. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  601. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  602. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  603. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  604. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  605. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  606. // POSSIBILITY OF SUCH DAMAGE.
  607. type Sigset_t = struct{ F__bits [4]X__uint32_t } /* sigtypes.h:62:3 */
  608. // Macro for manipulating signal masks.
  609. type Sigaltstack = struct {
  610. Fss_sp uintptr
  611. Fss_size Size_t
  612. Fss_flags int32
  613. F__ccgo_pad1 [4]byte
  614. } /* sigtypes.h:108:9 */
  615. // Macro for manipulating signal masks.
  616. type Stack_t = Sigaltstack /* sigtypes.h:116:3 */
  617. // Socket types.
  618. // Option flags per-socket.
  619. // SO_OTIMESTAMP 0x0400
  620. // Allowed default option flags
  621. // Additional options, not kept in so_options.
  622. // SO_OSNDTIMEO 0x1005
  623. // SO_ORCVTIMEO 0x1006
  624. // Structure used for manipulating linger option.
  625. type Linger = struct {
  626. Fl_onoff int32
  627. Fl_linger int32
  628. } /* socket.h:182:1 */
  629. type Accept_filter_arg = struct {
  630. Faf_name [16]int8
  631. Faf_arg [240]int8
  632. } /* socket.h:187:1 */
  633. // Level number for (get/set)sockopt() to apply to socket itself.
  634. // Address families.
  635. // Structure used by kernel to store most
  636. // addresses.
  637. type Sockaddr = struct {
  638. Fsa_len X__uint8_t
  639. Fsa_family X__sa_family_t
  640. Fsa_data [14]int8
  641. } /* socket.h:255:1 */
  642. // RFC 2553: protocol-independent placeholder for socket addresses
  643. type Sockaddr_storage = struct {
  644. Fss_len X__uint8_t
  645. Fss_family X__sa_family_t
  646. F__ss_pad1 [6]int8
  647. F__ss_align X__int64_t
  648. F__ss_pad2 [112]int8
  649. } /* socket.h:301:1 */
  650. // Protocol families, same as address families for now.
  651. type Pid_t = X__pid_t /* socket.h:366:18 */ // process id
  652. type Gid_t = X__gid_t /* socket.h:371:18 */ // group id
  653. type Uid_t = X__uid_t /* socket.h:376:18 */ // user id
  654. // Socket credentials.
  655. type Sockcred = struct {
  656. Fsc_pid X__pid_t
  657. Fsc_uid X__uid_t
  658. Fsc_euid X__uid_t
  659. Fsc_gid X__gid_t
  660. Fsc_egid X__gid_t
  661. Fsc_ngroups int32
  662. Fsc_groups [1]X__gid_t
  663. } /* socket.h:383:1 */
  664. // Compute size of a sockcred structure with groups.
  665. // Definition for CTL_NET PCB fetching sysctls
  666. type Kinfo_pcb = struct {
  667. Fki_pcbaddr X__uint64_t
  668. Fki_ppcbaddr X__uint64_t
  669. Fki_sockaddr X__uint64_t
  670. Fki_family X__uint32_t
  671. Fki_type X__uint32_t
  672. Fki_protocol X__uint32_t
  673. Fki_pflags X__uint32_t
  674. Fki_sostate X__uint32_t
  675. Fki_prstate X__uint32_t
  676. Fki_tstate X__int32_t
  677. Fki_tflags X__uint32_t
  678. Fki_rcvq X__uint64_t
  679. Fki_sndq X__uint64_t
  680. Fki_s struct {
  681. F_kis_src struct {
  682. Fsa_len X__uint8_t
  683. Fsa_family X__sa_family_t
  684. Fsa_data [14]int8
  685. }
  686. F__ccgo_pad1 [248]byte
  687. }
  688. Fki_d struct {
  689. F_kid_dst struct {
  690. Fsa_len X__uint8_t
  691. Fsa_family X__sa_family_t
  692. Fsa_data [14]int8
  693. }
  694. F__ccgo_pad1 [248]byte
  695. }
  696. Fki_inode X__uint64_t
  697. Fki_vnode X__uint64_t
  698. Fki_conn X__uint64_t
  699. Fki_refs X__uint64_t
  700. Fki_nextref X__uint64_t
  701. } /* socket.h:404:1 */
  702. // PF_ROUTE - Routing table
  703. //
  704. // Three additional levels are defined:
  705. // Fourth: address family, 0 is wildcard
  706. // Fifth: type of info, defined below
  707. // Sixth: flag(s) to mask with for NET_RT_FLAGS
  708. // Maximum queue length specifiable by listen(2).
  709. // $NetBSD: cdefs.h,v 1.141 2019/02/21 21:34:05 christos Exp $
  710. // * Copyright (c) 1991, 1993
  711. // The Regents of the University of California. All rights reserved.
  712. //
  713. // This code is derived from software contributed to Berkeley by
  714. // Berkeley Software Design, Inc.
  715. //
  716. // Redistribution and use in source and binary forms, with or without
  717. // modification, are permitted provided that the following conditions
  718. // are met:
  719. // 1. Redistributions of source code must retain the above copyright
  720. // notice, this list of conditions and the following disclaimer.
  721. // 2. Redistributions in binary form must reproduce the above copyright
  722. // notice, this list of conditions and the following disclaimer in the
  723. // documentation and/or other materials provided with the distribution.
  724. // 3. Neither the name of the University nor the names of its contributors
  725. // may be used to endorse or promote products derived from this software
  726. // without specific prior written permission.
  727. //
  728. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  729. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  730. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  731. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  732. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  733. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  734. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  735. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  736. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  737. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  738. // SUCH DAMAGE.
  739. //
  740. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  741. // Message header for recvmsg and sendmsg calls.
  742. // Used value-result for recvmsg, value only for sendmsg.
  743. type Msghdr = struct {
  744. Fmsg_name uintptr
  745. Fmsg_namelen X__socklen_t
  746. F__ccgo_pad1 [4]byte
  747. Fmsg_iov uintptr
  748. Fmsg_iovlen int32
  749. F__ccgo_pad2 [4]byte
  750. Fmsg_control uintptr
  751. Fmsg_controllen X__socklen_t
  752. Fmsg_flags int32
  753. } /* socket.h:479:1 */
  754. type Mmsghdr = struct {
  755. Fmsg_hdr struct {
  756. Fmsg_name uintptr
  757. Fmsg_namelen X__socklen_t
  758. F__ccgo_pad1 [4]byte
  759. Fmsg_iov uintptr
  760. Fmsg_iovlen int32
  761. F__ccgo_pad2 [4]byte
  762. Fmsg_control uintptr
  763. Fmsg_controllen X__socklen_t
  764. Fmsg_flags int32
  765. }
  766. Fmsg_len uint32
  767. F__ccgo_pad1 [4]byte
  768. } /* socket.h:506:1 */
  769. // Extra flags used internally only
  770. // Header for ancillary data objects in msg_control buffer.
  771. // Used for additional information with/about a datagram
  772. // not expressible by flags. The format is a sequence
  773. // of message elements headed by cmsghdr structures.
  774. type Cmsghdr = struct {
  775. Fcmsg_len X__socklen_t
  776. Fcmsg_level int32
  777. Fcmsg_type int32
  778. } /* socket.h:525:1 */
  779. var _ int8 /* gen.c:2:13: */