8 ** Extra stuff in some unixen, not in posix.
11 /*@unchecked@*/ int signgam;
13 typedef /*@integraltype@*/ clockid_t;
15 extern void bcopy (char *b1, /*@out@*/ char *b2, int length)
16 /*@modifies *b2@*/ ; /* Yes, the second parameter is the out param! */
18 extern int /*@alt lltX_bool@*/ bcmp (char *b1, char *b2, int length) /*@*/ ;
19 /* Return value is NOT like strcmp! */
21 extern void bzero (/*@out@*/ char *b1, int length) /*@modifies *b1@*/ ;
22 extern int ffs (int i) /*@*/ ;
23 extern int symlink (char *name1, char *name2) /*@modifies fileSystem@*/ ;
26 setvbuf_unlocked (FILE *stream, /*@null@*/ /*@exposed@*/ char *buf,
27 int mode, size_t size)
28 /*@modifies internalState@*/ ;
31 setbuffer (FILE *stream, /*@null@*/ /*@exposed@*/ char *buf, int size)
32 /*@modifies internalState@*/ ;
34 extern void setlinebuf (FILE *stream) /*@modifies internalState@*/ ;
36 extern int strerror_r (int errnum, /*@out@*/ char *strerrbuf, int buflen)
37 /*@modifies strerrbuf@*/ ;
40 fread_unlocked (/*@out@*/ void *ptr, size_t size, size_t nitems,
42 /*@modifies *stream, *ptr;@*/ ;
45 fwrite_unlocked (void *pointer, size_t size, size_t num_items, FILE *stream)
46 /*@modifies *stream;@*/ ;
48 extern void funlockfile (FILE *file) /*@modifies *file;@*/ ;
49 extern void flockfile (FILE *file) /*@modifies *file@*/ ;
51 extern void /*@alt void * @*/
52 memccpy (/*@returned@*/ /*@out@*/ void *s1,
53 /*@unique@*/ void *s2, int c, size_t n)
56 extern int strcasecmp (char *s1, char *s2) /*@*/ ;
57 extern int strncasecmp (char *s1, char *s2, int n) /*@*/ ;
58 extern char *strdup (char *s) /*@*/ ;
60 extern /*@null@*/ char *tempnam (char *dir, /*@null@*/ char *pfx)
61 /*@modifies internalState@*/ ;
63 extern /*@null@*/ /*@dependent@*/ char *
64 index (/*@returned@*/ char *s, char c) /*@*/ ;
66 extern /*@null@*/ /*@dependent@*/ char *
67 rindex (/*@returned@*/ char *s, char c) /*@*/ ;
69 extern /*@dependent@*/ /*@null@*/ FILE *popen (char *command, char *ttype)
70 /*@modifies fileSystem, errno@*/ ;
71 extern int pclose (FILE *stream) /*@modifies fileSystem, *stream, errno@*/ ;
73 extern double cbrt (double x) /*@modifies errno@*/ ;
74 extern double rint (double x) /*@*/ ;
75 extern double trunc (double x) /*@*/ ;
77 /*@constant int ENOTBLK@*/
78 /*@constant int ETXTBSY@*/
79 /*@constant int EWOULDBLOCK@*/
80 /*@constant int EINPROGRESS@*/
81 /*@constant int EALREADY@*/
82 /*@constant int ENOTSOCK@*/
83 /*@constant int EDESTADDRREQ@*/
84 /*@constant int EMSGSIZE@*/
85 /*@constant int EPROTOTYPE@*/
86 /*@constant int ENOPROTOOPT@*/
87 /*@constant int EPROTONOSUPPORT@*/
88 /*@constant int ESOCKTNOSUPPORT@*/
89 /*@constant int EOPNOTSUPP@*/
90 /*@constant int EPFNOSUPPORT@*/
91 /*@constant int EAFNOSUPPORT@*/
92 /*@constant int EADDRINUSE@*/
93 /*@constant int EADDRNOTAVAIL@*/
94 /*@constant int ENETDOWN@*/
95 /*@constant int ENETUNREACH@*/
96 /*@constant int ENETRESET@*/
97 /*@constant int ECONNABORTED@*/
98 /*@constant int ECONNRESET@*/
99 /*@constant int ENOBUFS@*/
100 /*@constant int EISCONN@*/
101 /*@constant int ENOTCONN@*/
102 /*@constant int ESHUTDOWN@*/
103 /*@constant int ETOOMANYREFS@*/
104 /*@constant int ETIMEDOUT@*/
105 /*@constant int ECONNREFUSED@*/
106 /*@constant int ENAMETOOLONG@*/
107 /*@constant int EHOSTDOWN@*/
108 /*@constant int EHOSTUNREACH@*/
109 /*@constant int ENOTEMPTY@*/
110 /*@constant int EPROCLIM@*/
111 /*@constant int EUSERS@*/
112 /*@constant int EDQUOT@*/
113 /*@constant int ESTALE@*/
114 /*@constant int EREMOTE@*/
115 /*@constant int ENOMSG@*/
116 /*@constant int EIDRM@*/
117 /*@constant int EALIGN@*/
118 /*@constant int EDEADLK@*/
119 /*@constant int ENOLCK@*/
120 /*@constant int ENOSYS@*/
121 /*@constant int EACTIVE@*/
122 /*@constant int ENOACTIVE@*/
123 /*@constant int ENORESOURCES@*/
124 /*@constant int ENOSYSTEM@*/
125 /*@constant int ENODUST@*/
126 /*@constant int EDUPNOCONN@*/
127 /*@constant int EDUPNODISCONN@*/
128 /*@constant int EDUPNOTCNTD@*/
129 /*@constant int EDUPNOTIDLE@*/
130 /*@constant int EDUPNOTWAIT@*/
131 /*@constant int EDUPNOTRUN@*/
132 /*@constant int EDUPBADOPCODE@*/
133 /*@constant int EDUPINTRANSIT@*/
134 /*@constant int EDUPTOOMANYCPUS@*/
135 /*@constant int ELOOP@*/
137 /*@constant int LOCK_MAX@*/
138 /*@constant int FCHR_MAX@*/
139 /*@constant int USI_MAX@*/
140 /*@constant int WORD_BIT@*/
141 /*@constant int LONG_BIT@*/
142 /*@constant long NAME_MAX@*/
143 /*@constant long NGROUPS_MAX@*/
144 /*@constant long MAX_INPUT@*/
145 /*@constant long MAX_CANON@*/
146 /*@constant int MAX_CHAR@*/
147 /*@constant long OPEN_MAX@*/
148 /*@constant int PASS_MAX@*/
149 /*@constant int PATH_MAX@*/
150 /*@constant int PID_MAX@*/
151 /*@constant int SYSPID_MAX@*/
152 /*@constant long PIPE_BUF@*/
153 /*@constant int PIPE_MAX@*/
154 /*@constant int PROC_MAX@*/
155 /*@constant int STD_BLK@*/
156 /*@constant int SYS_NMLN@*/
157 /*@constant int SYS_OPEN@*/
158 /*@constant int NZERO@*/
159 /*@constant int UID_MAX@*/
160 /*@constant long MB_LEN_MAX@*/
161 /*@constant int NL_ARGMAX@*/
162 /*@constant int NL_MSGMAX@*/
163 /*@constant int NL_NMAX@*/
164 /*@constant int NL_SETMAX@*/
165 /*@constant int NL_TEXTMAX@*/
166 /*@constant int NL_LBLMAX@*/
167 /*@constant int NL_LANGMAX @*/
169 /*@constant double M_E@*/
170 /*@constant double M_LOG2E@*/
171 /*@constant double M_LOG10E@*/
172 /*@constant double M_LN2@*/
173 /*@constant double M_LN10@*/
174 /*@constant double M_PI@*/
175 /*@constant double M_PI_2@*/
176 /*@constant double M_PI_4@*/
177 /*@constant double M_1_PI@*/
178 /*@constant double M_2_PI@*/
179 /*@constant double M_2_SQRTPI@*/
180 /*@constant double M_SQRT2@*/
181 /*@constant double M_SQRT1_2@*/
183 /*@constant double MAXFLOAT@*/
184 /*@constant double HUGE@*/
186 /*@constant int DOMAIN@*/
187 /*@constant int SING@*/
188 /*@constant int OVERFLOW@*/
189 /*@constant int UNDERFLOW@*/
190 /*@constant int TLOSS@*/
191 /*@constant int PLOSS@*/
193 extern /*@unchecked@*/ int daylight;
194 extern /*@unchecked@*/ long timezone;
195 extern /*@unchecked@*/ char *tzname[];
198 extern void tzset(void) /*@modifies daylight, timezone, tzname@*/ ;
201 typedef unsigned char uchar_t;
202 typedef unsigned short ushort_t;
203 typedef unsigned int uint_t;
204 typedef unsigned long ulong_t;
205 typedef volatile unsigned char vuchar_t;
206 typedef volatile unsigned short vushort_t;
207 typedef volatile unsigned int vuint_t;
208 typedef volatile unsigned long vulong_t;
209 typedef long label_t;
211 typedef /*@integraltype@*/ daddr_t;
212 typedef char *caddr_t;
213 typedef long *qaddr_t;
214 typedef char *addr_t;
215 typedef long physadr_t;
218 typedef unsigned long rlim_t;
220 typedef /*@integraltype@*/ key_t;
222 typedef char slab_t[12];
223 typedef ulong_t shmatt_t;
224 typedef ulong_t msgqnum_t;
225 typedef ulong_t msglen_t;
226 typedef long timer_t;
227 typedef uchar_t uchar;
228 typedef ushort_t ushort;
230 typedef ulong_t ulong;
231 typedef uchar_t u_char;
232 typedef ushort_t u_short;
233 typedef uint_t u_int;
234 typedef ulong_t u_long;
235 typedef vuchar_t vu_char;
236 typedef vushort_t vu_short;
237 typedef vuint_t vu_int;
238 typedef vulong_t vu_long;
239 typedef long swblk_t;
240 typedef u_long fixpt_t;
241 typedef long segsz_t;
242 typedef /*@abstract@*/ fd_set;
244 /* Check ISO C99 inttypes.h ... */
245 typedef unsigned int u_int32_t;
246 typedef unsigned int uint32_t;
248 typedef unsigned short int u_int16_t;
249 typedef unsigned short int uint16_t;
251 int ttyname_r (int fg, /*@out@*/ char *buffer, int len) /*@modifies buffer@*/ ;
252 int ioctl (int d, int /*@alt long@*/ request, /*@out@*/ void *arg)
253 /*@modifies *arg, errno@*/ ; /* depends on request! */
255 pid_t vfork (void) /*@modifies fileSystem@*/ ;
263 /*@constant int UIO_MAXIOV@*/ /* BSD */
264 /*@constant int IOV_MAX@*/ /* supposedly SVR4 */
267 readv (int fd, const struct iovec iov[], int iovcnt)
268 /*@modifies iov[].iov_base, fileSystem, errno@*/;
271 writev (int fd, const struct iovec iov[], int iovcnt)
272 /*@modifies errno@*/;
274 /*________________________________________________________________________
284 /*@constant short POLLIN@*/
285 /*@constant short POLLRDNORM@*/
286 /*@constant short POLLRDBAND@*/
287 /*@constant short POLLPRI@*/
288 /*@constant short POLLOUT@*/
289 /*@constant short POLLWRNORM@*/
290 /*@constant short POLLWRBAND@*/
291 /*@constant short POLLERR@*/
292 /*@constant short POLLHUP@*/
293 /*@constant short POLLNVAL@*/
295 extern int poll (struct poll pollfd[], unsigned long nfds, int timeout)
296 /*@modifies pollfd[].revents, errno@*/ ;
299 ** free does not take null
303 extern void free (/*@notnull@*/ /*@out@*/ /*@only@*/ void *p) /*@modifies *p@*/ ;
306 /*________________________________________________________________________
310 /*@constant int SOCK_STREAM@*/
311 /*@constant int SOCK_DGRAM@*/
312 /*@constant int SOCK_RAW@*/
313 /*@constant int SOCK_RDM@*/
314 /*@constant int SOCK_SEQPACKET@*/
315 /*@constant int SO_DEBUG@*/
316 /*@constant int SO_ACCEPTCONN@*/
317 /*@constant int SO_REUSEADDR@*/
318 /*@constant int SO_KEEPALIVE@*/
319 /*@constant int SO_DONTROUTE@*/
320 /*@constant int SO_BROADCAST@*/
321 /*@constant int SO_USELOOPBACK@*/
322 /*@constant int SO_LINGER@*/
323 /*@constant int SO_OOBINLINE@*/
324 /*@constant int SO_REUSEPORT@*/
325 /*@constant int SO_SNDBUF@*/
326 /*@constant int SO_RCVBUF@*/
327 /*@constant int SO_SNDLOWAT@*/
328 /*@constant int SO_RCVLOWAT@*/
329 /*@constant int SO_SNDTIMEO@*/
330 /*@constant int SO_RCVTIMEO@*/
331 /*@constant int SO_ERROR@*/
332 /*@constant int SO_TYPE@*/
333 /*@constant int SOL_SOCKET@*/
334 /*@constant int AF_UNSPEC@*/
335 /*@constant int AF_LOCAL@*/
336 /*@constant int AF_UNIX@*/
337 /*@constant int AF_INET@*/
338 /*@constant int AF_IMPLINK@*/
339 /*@constant int AF_PUP@*/
340 /*@constant int AF_CHAOS@*/
341 /*@constant int AF_NS@*/
342 /*@constant int AF_ISO@*/
343 /*@constant int AF_OSI@*/
344 /*@constant int AF_ECMA@*/
345 /*@constant int AF_DATAKIT@*/
346 /*@constant int AF_CCITT@*/
347 /*@constant int AF_SNA@*/
348 /*@constant int AF_DECnet@*/
349 /*@constant int AF_DLI@*/
350 /*@constant int AF_LAT@*/
351 /*@constant int AF_HYLINK@*/
352 /*@constant int AF_APPLETALK@*/
353 /*@constant int AF_ROUTE@*/
354 /*@constant int AF_LINK@*/
355 /*@constant int pseudo_AF_XTP@*/
356 /*@constant int AF_COIP@*/
357 /*@constant int AF_CNT@*/
358 /*@constant int pseudo_AF_RTIP@*/
359 /*@constant int AF_IPX@*/
360 /*@constant int AF_SIP@*/
361 /*@constant int pseudo_AF_PIP@*/
362 /*@constant int AF_ISDN@*/
363 /*@constant int AF_E164@*/
364 /*@constant int AF_MAX@*/
365 /*@constant int MSG_OOB@*/
366 /*@constant int MSG_PEEK@*/
367 /*@constant int MSG_DONTROUTE@*/
368 /*@constant int MSG_EOR@*/
369 /*@constant int MSG_TRUNC@*/
370 /*@constant int MSG_CTRUNC@*/
371 /*@constant int MSG_WAITALL@*/
372 /*@constant int MSG_DONTWAIT@*/
373 /*@constant int MSG_EOF@*/
374 /*@constant int MSG_COMPAT@*/
375 /*@constant int PF_UNSPEC@*/
376 /*@constant int PF_LOCAL@*/
377 /*@constant int PF_UNIX@*/
378 /*@constant int PF_INET@*/
379 /*@constant int PF_IMPLINK@*/
380 /*@constant int PF_PUP@*/
381 /*@constant int PF_CHAOS@*/
382 /*@constant int PF_NS@*/
383 /*@constant int PF_ISO@*/
384 /*@constant int PF_OSI@*/
385 /*@constant int PF_ECMA@*/
386 /*@constant int PF_DATAKIT@*/
387 /*@constant int PF_CCITT@*/
388 /*@constant int PF_SNA@*/
389 /*@constant int PF_DECnet@*/
390 /*@constant int PF_DLI@*/
391 /*@constant int PF_LAT@*/
392 /*@constant int PF_HYLINK@*/
393 /*@constant int PF_APPLETALK@*/
394 /*@constant int PF_ROUTE@*/
395 /*@constant int PF_LINK@*/
396 /*@constant int PF_XTP@*/
397 /*@constant int PF_COIP@*/
398 /*@constant int PF_CNT@*/
399 /*@constant int PF_SIP@*/
400 /*@constant int PF_IPX@*/
401 /*@constant int PF_RTIP@*/
402 /*@constant int PF_PIP@*/
403 /*@constant int PF_ISDN@*/
404 /*@constant int PF_MAX@*/
405 /*@constant int NET_MAXID@*/
406 /*@constant int NET_RT_DUMP@*/
407 /*@constant int NET_RT_FLAGS@*/
408 /*@constant int NET_RT_IFLIST@*/
409 /*@constant int NET_RT_MAXID@*/
410 /*@constant int SOMAXCONN@*/
411 /*@constant int SCM_RIGHTS@*/
414 u_char sa_len; /* total length */
415 u_char sa_family; /* address family */
416 char sa_data[14]; /* actually longer; address value */
420 int l_onoff; /* option on/off */
421 int l_linger; /* linger time */
425 u_short sp_family; /* address family */
426 u_short sp_protocol; /* protocol */
429 caddr_t msg_name; /* optional address */
430 u_int msg_namelen; /* size of address */
431 struct iovec *msg_iov; /* scatter/gather array */
432 u_int msg_iovlen; /* # elements in msg_iov */
433 caddr_t msg_control; /* ancillary data, see below */
434 u_int msg_controllen; /* ancillary data buffer len */
435 int msg_flags; /* flags on received message */
439 u_int cmsg_len; /* data byte count, including hdr */
440 int cmsg_level; /* originating protocol */
441 int cmsg_type; /* protocol-specific type */
442 /* followed by u_char cmsg_data[]; */
446 accept (int s, struct sockaddr *addr, int *addrlen)
447 /*@modifies *addrlen, errno@*/;
450 bind (int s, struct sockaddr *name, int namelen)
451 /*@modifies errno, fileSystem@*/;
454 connect (int s, struct sockaddr *name, int namelen)
455 /*@modifies errno, internalState@*/;
457 int getpeername (int s, /*@out@*/ struct sockaddr *name, size_t *namelen)
458 /*@modifies *name, *namelen, errno@*/;
460 int getsockname (int s, struct sockaddr *address, size_t *address_len)
461 /*?requires maxSet(address) > *address_len@*/
462 /*@modifies *address, *address_len, errno@*/;
464 int getsockopt (int s, int level, int optname, /*@out@*/ void *optval, size_t *optlen)
465 /*@modifies *optval, *optlen, errno@*/;
468 listen (int s, int backlog)
469 /*@modifies errno, internalState@*/;
472 recv (int s, /*@out@*/ void *buf, size_t len, int flags)
473 /*@modifies *buf, errno@*/;
476 recvfrom (int s, void *buf, size_t len, int flags, /*@null@*/ struct sockaddr *from, int *fromlen)
477 /*@modifies *buf, *from, *fromlen, errno@*/;
480 recvmsg (int s, struct msghdr *msg, int flags)
481 /*@modifies msg->msg_iov->iov_base[], errno@*/;
484 send (int s, const void *msg, size_t len, int flags)
485 /*@modifies errno@*/;
488 sendto (int s, const void *msg, size_t len, int flags, const struct sockaddr *to, int tolen)
489 /*@modifies errno@*/;
492 sendmsg (int s, const struct msghdr *msg, int flags)
493 /*@modifies errno@*/;
496 setsockopt (int s, int level, int optname, const void *optval, int optlen)
497 /*@modifies internalState, errno@*/;
500 shutdown (int s, int how)
501 /*@modifies errno@*/;
504 socket (int domain, int type, int protocol)
505 /*@modifies errno@*/;
508 socketpair (int d, int type, int protocol, /*@out@*/ int *sv)
509 /*@modifies errno@*/;
511 /*@constant int BADSIG@*/
512 /*@constant int SA_ONSTACK@*/
513 /*@constant int SA_RESTART@*/
514 /*@constant int SA_DISABLE@*/
515 /*@constant int SIGBUS@*/
516 /*@constant int SIGEMT@*/
517 /*@constant int SIGINFO@*/
518 /*@constant int SIGIO@*/
519 /*@constant int SIGIOT@*/
520 /*@constant int SIGPOLL@*/
521 /*@constant int SIGPROF@*/
522 /*@constant int SIGPWR@*/
523 /*@constant int SIGSYS@*/
524 /*@constant int SIGTRAP@*/
525 /*@constant int SIGURG@*/
526 /*@constant int SIGVTALRM@*/
527 /*@constant int SIGWINCH@*/
528 /*@constant int SIGXCPU@*/
529 /*@constant int SIGXFSZ@*/
531 extern void psignal (int sig, const char *msg)
532 /*@modifies fileSystem@*/;
534 /*@unchecked@*/ extern char *optarg;
535 /*@unchecked@*/ extern int optind;
536 /*@unchecked@*/ extern int optopt;
537 /*@unchecked@*/ extern int opterr;
538 /*@unchecked@*/ extern int optreset;
541 getopt (int argc, char * const *argv, const char *optstring)
542 /*@globals optarg, optind, optopt, opterr, optreset@*/
543 /*@modifies optarg, optind, optopt@*/;
546 setenv (const char *name, const char *value, int overwrite)
547 /*@globals environ@*/
548 /*@modifies *environ, errno@*/;
551 putenv (const char *string)
552 /*@globals environ@*/
553 /*@modifies *environ, errno@*/;
556 unsetenv (const char *name)
557 /*@globals environ@*/
558 /*@modifies *environ@*/;
560 /*________________________________________________________________________
569 W_EXITCODE (int ret, int sig)
576 /*@constant int WAIT_ANY@*/
577 /*@constant int WAIT_MYPGRP@*/
578 /*@constant int WSTOPPED@*/
581 wait3 (int *statloc, int options, /*@null@*/ /*@out@*/ struct rusage *rusage)
582 /*@modifies *statloc, *rusage, errno@*/;
585 wait4 (pid_t p, int *statloc, int opt, /*@null@*/ /*@out@*/ struct rusage *r)
586 /*@modifies *statloc, *r, errno@*/;
603 /*@constant int DST_NONE@*/
604 /*@constant int DST_USA@*/
605 /*@constant int DST_AUST@*/
606 /*@constant int DST_WET@*/
607 /*@constant int DST_MET@*/
608 /*@constant int DST_EET@*/
609 /*@constant int DST_CAN@*/
611 /*@constant int ITIMER_PROF@*/
612 /*@constant int ITIMER_REAL@*/
613 /*@constant int ITIMER_VIRTUAL@*/
616 struct timeval it_interval;
617 struct timeval it_value;
628 adjtime (const struct timeval *delta, /*@null@*/ /*@out@*/ struct timeval *olddelta)
629 /*@modifies internalState, *olddelta, errno@*/;
632 getitimer (int which, /*@out@*/ struct itimerval *value)
633 /*@modifies errno, *value*/;
636 gettimeofday (/*@null@*/ /*@out@*/ struct timeval *tp, /*@null@*/ /*@out@*/ struct timezone *tzp)
637 /*@modifies *tp, *tzp, errno@*/;
640 setitimer (int which, struct itimerval *val, /*@null@*/ /*@out@*/ struct itimerval *oval)
641 /*@modifies *oval, errno, internalState*/;
644 settimeofday (const struct timeval *t, const struct timezone *z)
645 /*@modifies internalState, errno@*/;
648 utimes (const char *file, /*@null@*/ const struct timeval *times)
649 /*@modifies fileSystem, errno*/;
651 /*________________________________________________________________________
655 /*@constant int PROT_READ@*/
656 /*@constant int PROT_WRITE@*/
657 /*@constant int PROT_EXEC@*/
658 /*@constant int MAP_SHARED@*/
659 /*@constant int MAP_PRIVATE@*/
660 /*@constant int MAP_COPY@*/
661 /*@constant int MAP_FIXED@*/
662 /*@constant int MAP_RENAME@*/
663 /*@constant int MAP_NORESERVE@*/
664 /*@constant int MAP_INHERIT@*/
665 /*@constant int MAP_NOEXTEND@*/
666 /*@constant int MAP_HASSEMAPHORE@*/
667 /*@constant int MS_ASYNC@*/
668 /*@constant int MS_INVALIDATE@*/
669 /*@constant int MAP_FILE@*/
670 /*@constant int MAP_ANON@*/
671 /*@constant int MADV_NORMAL@*/
672 /*@constant int MADV_RANDOM@*/
673 /*@constant int MADV_SEQUENTIAL@*/
674 /*@constant int MADV_WILLNEED@*/
675 /*@constant int MADV_DONTNEED@*/
678 mmap (/*@null@*/ /*@returned@*/ caddr_t addr, size_t len, int prot, int flags, int fd, off_t offset)
682 madvise (caddr_t addr, int len, int behav)
686 mprotect (caddr_t addr, int len, int prot)
690 munmap (caddr_t addr, size_t len)
694 msync (caddr_t addr, int len, int flags)
698 mlock (caddr_t addr, size_t len)
702 munlock (caddr_t addr, size_t len)
706 /*________________________________________________________________________
711 unsigned short ws_row;
712 unsigned short ws_col;
713 unsigned short ws_xpixel;
714 unsigned short ws_ypixel;
717 /*@constant int TIOCMODG@*/
718 /*@constant int TIOCMODS@*/
719 /*@constant int TIOCM_LE@*/
720 /*@constant int TIOCM_DTR@*/
721 /*@constant int TIOCM_RTS@*/
722 /*@constant int TIOCM_ST@*/
723 /*@constant int TIOCM_SR@*/
724 /*@constant int TIOCM_CTS@*/
725 /*@constant int TIOCM_CAR@*/
726 /*@constant int TIOCM_CD@*/
727 /*@constant int TIOCM_RNG@*/
728 /*@constant int TIOCM_RI@*/
729 /*@constant int TIOCM_DSR@*/
730 /*@constant int TIOCEXCL@*/
731 /*@constant int TIOCNXCL@*/
732 /*@constant int TIOCFLUSH@*/
733 /*@constant int TIOCGETA@*/
734 /*@constant int TIOCSETA@*/
735 /*@constant int TIOCSETAW@*/
736 /*@constant int TIOCSETAF@*/
737 /*@constant int TIOCGETD@*/
738 /*@constant int TIOCSETD@*/
739 /*@constant int TIOCSBRK@*/
740 /*@constant int TIOCCBRK@*/
741 /*@constant int TIOCSDTR@*/
742 /*@constant int TIOCCDTR@*/
743 /*@constant int TIOCGPGRP@*/
744 /*@constant int TIOCSPGRP@*/
745 /*@constant int TIOCOUTQ@*/
746 /*@constant int TIOCSTI@*/
747 /*@constant int TIOCNOTTY@*/
748 /*@constant int TIOCPKT@*/
749 /*@constant int TIOCPKT_DATA@*/
750 /*@constant int TIOCPKT_FLUSHREAD@*/
751 /*@constant int TIOCPKT_FLUSHWRITE@*/
752 /*@constant int TIOCPKT_STOP@*/
753 /*@constant int TIOCPKT_START@*/
754 /*@constant int TIOCPKT_NOSTOP@*/
755 /*@constant int TIOCPKT_DOSTOP@*/
756 /*@constant int TIOCPKT_IOCTL@*/
757 /*@constant int TIOCSTOP@*/
758 /*@constant int TIOCSTART@*/
759 /*@constant int TIOCMSET@*/
760 /*@constant int TIOCMBIS@*/
761 /*@constant int TIOCMBIC@*/
762 /*@constant int TIOCMGET@*/
763 /*@constant int TIOCREMOTE@*/
764 /*@constant int TIOCGWINSZ@*/
765 /*@constant int TIOCSWINSZ@*/
766 /*@constant int TIOCUCNTL@*/
767 /*@constant int TIOCSTAT@*/
768 /*@constant int TIOCCONS@*/
769 /*@constant int TIOCSCTTY@*/
770 /*@constant int TIOCEXT@*/
771 /*@constant int TIOCSIG@*/
772 /*@constant int TIOCDRAIN@*/
773 /*@constant int TIOCMSDTRWAIT@*/
774 /*@constant int TIOCMGDTRWAIT@*/
775 /*@constant int TIOCTIMESTAMP@*/
776 /*@constant int TIOCSDRAINWAIT@*/
777 /*@constant int TIOCGDRAINWAIT@*/
778 /*@constant int TTYDISC@*/
779 /*@constant int TABLDISC@*/
780 /*@constant int SLIPDISC@*/
781 /*@constant int PPPDISC@*/
783 /*@constant int MAXHOSTNAMELEN@*/
786 FD_CLR (int n, fd_set *p)
790 FD_COPY (fd_set *f, /*@out@*/ fd_set *t)
793 extern int /*@alt lltX_bool@*/
794 FD_ISSET (int n, fd_set *p)
798 FD_SET (int n, fd_set *p)
802 FD_ZERO (fd_set /*@out@*/ *p)
807 /*@modifies internalState, errno@*/;
810 fchown (int fd, uid_t owner, gid_t group)
811 /*@modifies errno, fileSystem@*/;
815 /*@modifies errno, fileSystem@*/;
818 ftruncate (int fd, off_t length)
819 /*@modifies errno, fileSystem@*/;
821 int gethostname (/*@out@*/ char *address, size_t address_len)
823 /*@modifies address@*/ ;
825 int initgroups (const char *name, int basegid)
826 /*@modifies internalState@*/;
829 lchown (const char *path, uid_t owner, gid_t group)
830 /*@modifies errno, fileSystem@*/;
833 readlink (const char *path, /*@out@*/ char *buf, int size)
834 /*@modifies *buf, errno@*/;
837 select (int mfd, fd_set /*@null@*/ *r, fd_set /*@null@*/ *w, fd_set /*@null@*/ *e, struct timeval *t)
838 /*@modifies *r, *w, *e, *t, errno@*/;
842 /*@modifies errno, internalState@*/;
846 /*@modifies errno, internalState@*/;
849 setgroups (int ngroups, const gid_t *gidset)
850 /*@modifies errno, internalState@*/;
853 setregid (gid_t rgid, gid_t egid)
854 /*@modifies errno, internalState@*/;
857 setreuid (gid_t ruid, gid_t euid)
858 /*@modifies errno, internalState@*/;
862 /*@modifies fileSystem@*/;
865 symlink (const char *path, const char *path2)
866 /*@modifies fileSystem@*/;
869 truncate (const char *name, off_t length)
870 /*@modifies errno, fileSystem@*/;
872 /*@constant int EBADRPC@*/
873 /*@constant int ERPCMISMATCH@*/
874 /*@constant int EPROGUNAVAIL@*/
875 /*@constant int EPROGMISMATCH@*/
876 /*@constant int EPROCUNAVAIL@*/
877 /*@constant int EFTYPE@*/
878 /*@constant int EAUTH@*/
879 /*@constant int ENEEDAUTH@*/
880 /*@constant int ELAST@*/
882 /*________________________________________________________________________
886 /*@unchecked@*/ extern char *TMAGIC;
887 /*@constant int TMAGLEN@*/
888 /*@unchecked@*/ extern char *TVERSION;
889 /*@constant int TVERSLEN@*/
891 /*@constant int REGTYPE@*/
892 /*@constant int AREGTYPE@*/
893 /*@constant int LNKTYPE@*/
894 /*@constant int SYMTYPE@*/
895 /*@constant int CHRTYPE@*/
896 /*@constant int BLKTYPE@*/
897 /*@constant int DIRTYPE@*/
898 /*@constant int FIFOTYPE@*/
899 /*@constant int CONTTYPE@*/
901 /*@constant int TSUID@*/
902 /*@constant int TSGID@*/
903 /*@constant int TSVTX@*/
905 /*@constant int TUREAD@*/
906 /*@constant int TUWRITE@*/
907 /*@constant int TUEXEC@*/
908 /*@constant int TGREAD@*/
909 /*@constant int TGWRITE@*/
910 /*@constant int TGEXEC@*/
911 /*@constant int TOREAD@*/
912 /*@constant int TOWRITE@*/
913 /*@constant int TOEXEC@*/
916 uid_t uid; /* user id */
917 gid_t gid; /* group id */
918 uid_t cuid; /* creator user id */
919 gid_t cgid; /* creator group id */
920 mode_t mode; /* r/w permission */
921 ulong seq; /* slot usage sequence number */
922 key_t key; /* user specified msg/sem/shm key */
925 /*@constant int IPC_R@*/
926 /*@constant int IPC_W@*/
927 /*@constant int IPC_M@*/
928 /*@constant int IPC_CREAT@*/
929 /*@constant int IPC_EXCL@*/
930 /*@constant int IPC_NOWAIT@*/
931 /*@constant key_t IPC_PRIVATE@*/
932 /*@constant int IPC_RMID@*/
933 /*@constant int IPC_SET@*/
934 /*@constant int IPC_STAT@*/
936 /*________________________________________________________________________
941 struct ipc_perm msg_perm; /* msg queue permission bits */
942 struct msg *msg_first; /* first message in the queue */
943 struct msg *msg_last; /* last message in the queue */
944 u_long msg_cbytes; /* number of bytes in use on the queue */
945 u_long msg_qnum; /* number of msgs in the queue */
946 u_long msg_qbytes; /* max # of bytes on the queue */
947 pid_t msg_lspid; /* pid of last msgsnd() */
948 pid_t msg_lrpid; /* pid of last msgrcv() */
949 time_t msg_stime; /* time of last msgsnd() */
950 time_t msg_rtime; /* time of last msgrcv() */
951 time_t msg_ctime; /* time of last msgctl() */
955 long mtype; /* message type (+ve integer) */
956 char mtext[]; /* message body */
959 /*@constant int MSG_NOERROR@*/
960 /*@constant int MSGMAX@*/
961 /*@constant int MSGMNB@*/
962 /*@constant int MSGMNI@*/
963 /*@constant int MSGTQL@*/
966 msgctl (int id , int cmd, /*@out@*/ struct msqid_ds *buf)
967 /*@modifies errno, *buf@*/;
970 msgget (key_t key, int flag)
971 /*@modifies errno@*/;
974 msgrcv (int id, /*@out@*/ void *ptr, size_t nbytes, long type, int flags)
975 /*@modifies errno, *ptr@*/;
978 msgsnd (int id, const void *ptr, size_t nbytes, int flag)
979 /*@modifies errno@*/;
981 /*________________________________________________________________________
986 struct ipc_perm sem_perm;
987 struct sem *sem_base;
1002 struct semid_ds *buf;
1012 /*@constant int SEM_A@*/
1013 /*@constant int SEMAEM@*/
1014 /*@constant int SEMMNI@*/
1015 /*@constant int SEMMNS@*/
1016 /*@constant int SEMMNU@*/
1017 /*@constant int SEMMSL@*/
1018 /*@constant int SEMOPN@*/
1019 /*@constant int SEM_R@*/
1020 /*@constant int SEMUME@*/
1021 /*@constant int SEM_UNDO@*/
1022 /*@constant int SEMVMX@*/
1023 /*@constant int GETVAL@*/
1024 /*@constant int SETVAL@*/
1025 /*@constant int GETPID@*/
1026 /*@constant int GETNCNT@*/
1027 /*@constant int GETZCNT@*/
1028 /*@constant int GETALL@*/
1029 /*@constant int SETALL@*/
1031 /*@constant int ERMID@*/
1034 semctl (int id, int semnum, int cmd, union semun arg)
1035 /*@modifies errno@*/;
1038 semget (key_t key, int nsems, int flag)
1039 /*@modifies errno@*/;
1042 semop (int id, struct sembuf *semoparray, size_t nops)
1043 /*@modifies errno@*/;
1045 /*________________________________________________________________________
1050 struct ipc_perm shm_perm;
1062 /*@constant int SHMLBA@*/
1063 /*@constant int SHM_LOCK@*/
1064 /*@constant int SHMMAX@*/
1065 /*@constant int SHMMIN@*/
1066 /*@constant int SHMMNI@*/
1067 /*@constant int SHM_R@*/
1068 /*@constant int SHM_RDONLY@*/
1069 /*@constant int SHM_RND@*/
1070 /*@constant int SHMSEG@*/
1071 /*@constant int SHM_W@*/
1072 /*@constant int SHM_UNLOCK@*/
1075 shmat (int id, /*@null@*/ void *addr, int flag)
1076 /*@modifies errno@*/;
1079 shmctl (int id, int cmd, /*@out@*/ struct shmid_ds *buf)
1080 /*@modifies errno, *buf@*/;
1084 /*@modifies errno@*/;
1087 shmget (key_t key, int size, int flag)
1088 /*@modifies errno@*/;
1090 /*________________________________________________________________________
1094 /*@constant int LOG_EMERG@*/
1095 /*@constant int LOG_ALERT@*/
1096 /*@constant int LOG_CRIT@*/
1097 /*@constant int LOG_ERR@*/
1098 /*@constant int LOG_WARNING@*/
1099 /*@constant int LOG_NOTICE@*/
1100 /*@constant int LOG_INFO@*/
1101 /*@constant int LOG_DEBUG@*/
1103 /*@constant int LOG_KERN@*/
1104 /*@constant int LOG_USER@*/
1105 /*@constant int LOG_MAIL@*/
1106 /*@constant int LOG_DAEMON@*/
1107 /*@constant int LOG_AUTH@*/
1108 /*@constant int LOG_SYSLOG@*/
1109 /*@constant int LOG_LPR@*/
1110 /*@constant int LOG_NEWS@*/
1111 /*@constant int LOG_UUCP@*/
1112 /*@constant int LOG_CRON@*/
1113 /*@constant int LOG_AUTHPRIV@*/
1114 /*@constant int LOG_FTP@*/
1115 /*@constant int LOG_LOCAL0@*/
1116 /*@constant int LOG_LOCAL1@*/
1117 /*@constant int LOG_LOCAL2@*/
1118 /*@constant int LOG_LOCAL3@*/
1119 /*@constant int LOG_LOCAL4@*/
1120 /*@constant int LOG_LOCAL5@*/
1121 /*@constant int LOG_LOCAL6@*/
1122 /*@constant int LOG_LOCAL7@*/
1124 /*@constant int LOG_PID@*/
1125 /*@constant int LOG_CONS@*/
1126 /*@constant int LOG_ODELAY@*/
1127 /*@constant int LOG_NDELAY@*/
1128 /*@constant int LOG_NOWAIT@*/
1129 /*@constant int LOG_PERROR@*/
1141 /*@modifies fileSystem@*/;
1144 openlog (const char *ident, int logopt, int facility)
1145 /*@modifies fileSystem@*/;
1148 setlogmask (int maskpri)
1149 /*@modifies internalState@*/;
1151 extern void /*@printflike@*/
1152 syslog (int priority, const char *message, ...)
1153 /*@modifies fileSystem@*/;
1156 vsyslog (int priority, const char *message, va_list args)
1157 /*@modifies fileSystem@*/;
1159 /*________________________________________________________________________
1165 /*@modifies internalState@*/;
1167 extern /*@null@*/ struct passwd *
1169 /*@modifies internalState@*/;
1172 setpassent (int stayopen)
1173 /*@modifies internalState@*/;
1177 /*@modifies internalState@*/;
1179 /*________________________________________________________________________
1185 /*@modifies internalState@*/;
1187 extern /*@null@*/ struct group *
1189 /*@modifies internalState@*/;
1193 /*@modifies internalState@*/;
1196 setgrfile (const char *name)
1197 /*@modifies internalState@*/;
1200 setgroupent (int stayopen)
1201 /*@modifies internalState@*/;
1203 /*________________________________________________________________________
1207 /*@constant int S_ISTXT@*/
1208 /*@constant int S_IREAD@*/
1209 /*@constant int S_IWRITE@*/
1210 /*@constant int S_IEXEC@*/
1211 /*@constant int S_IFMT@*/
1212 /*@constant int S_IFIFO@*/
1213 /*@constant int S_IFCHR@*/
1214 /*@constant int S_IFDIR@*/
1215 /*@constant int S_IFBLK@*/
1216 /*@constant int S_IFREG@*/
1217 /*@constant int S_IFLNK@*/
1218 /*@constant int S_IFSOCK@*/
1219 /*@constant int S_ISVTX@*/
1220 /*@constant int S_ISVTX@*/
1221 /*@constant int SF_SETTABLE@*/
1222 /*@constant int SF_ARCHIVED@*/
1223 /*@constant int ACCESSPERMS@*/
1224 /*@constant int ALLPERMS@*/
1225 /*@constant int DEFFILEMODE@*/
1226 /*@constant int S_BLKSIZE@*/
1227 /*@constant int SF_IMMUTABLE@*/
1228 /*@constant int SF_APPEND@*/
1229 /*@constant int UF_NODUMP@*/
1230 /*@constant int UF_IMMUTABLE@*/
1231 /*@constant int UF_APPEND@*/
1233 extern int /*@alt lltX_bool@*/
1234 S_ISLNK (/*@sef@*/ mode_t m)
1237 extern int /*@alt lltX_bool@*/
1238 S_ISSOCK (/*@sef@*/ mode_t m)
1242 chflags (const char *path, u_long flags)
1243 /*@modifies fileSystem, errno@*/;
1246 fchflags (int fd, u_long flags)
1247 /*@modifies fileSystem, errno@*/;
1250 fchmod (int fd, mode_t mode)
1251 /*@modifies fileSystem, errno@*/;
1254 lstat (const char *path, /*@out@*/ struct stat *buf)
1255 /*@modifies errno, *buf@*/;
1257 /*________________________________________________________________________
1261 /*@constant int FMNAMESZ@*/
1262 /*@constant int MSG_BAND@*/
1263 /*@constant int MSG_HIPRI@*/
1264 /*@constant int RS_HIPRI@*/
1265 /*@constant int S_INPUT@*/
1266 /*@constant int S_RDNORM@*/
1267 /*@constant int S_RDBAND@*/
1268 /*@constant int S_BANDURG@*/
1269 /*@constant int S_HIPRI@*/
1270 /*@constant int S_OUTPUT@*/
1271 /*@constant int S_WRNORM@*/
1272 /*@constant int S_WRBAND@*/
1273 /*@constant int S_MSG@*/
1274 /*@constant int S_ERROR@*/
1275 /*@constant int S_HANGUP@*/
1289 struct str_mlist *sl_modlist;
1293 getmsg (int fd, /*@out@*/ struct strbuf *c, /*@out@*/ struct strbuf *d, int *f)
1294 /*@modifies *c, *d, errno@*/;
1297 getpmsg (int fd, /*@out@*/ struct strbuf *c, /*@out@*/ struct strbuf *d, int *b, int *f)
1298 /*@modifies *b, *c, *d, errno@*/;
1301 putmsg (int fd, const struct strbuf *c, const struct strbuf *d, int *f)
1302 /*@modifies internalState, errno@*/;
1305 putpmsg (int fd, const struct strbuf *c, const struct strbuf *d, int b, int *f)
1306 /*@modifies internalState, errno@*/;
1308 /*________________________________________________________________________
1312 /*@constant int RLIMIT_CPU@*/
1313 /*@constant int RLIMIT_FSIZE@*/
1314 /*@constant int RLIMIT_DATA@*/
1315 /*@constant int RLIMIT_STACK@*/
1316 /*@constant int RLIMIT_CORE@*/
1317 /*@constant int RLIMIT_RSS@*/
1318 /*@constant int RLIMIT_MEMLOCK@*/
1319 /*@constant int RLIMIT_NPROC@*/
1320 /*@constant int RLIMIT_NOFILE@*/
1321 /*@constant int RLIM_NLIMITS@*/
1322 /*@constant int RLIM_INFINITY@*/
1323 /*@constant int PRIO_MIN@*/
1324 /*@constant int PRIO_MAX@*/
1325 /*@constant int PRIO_PROCESS@*/
1326 /*@constant int PRIO_PGRP@*/
1327 /*@constant int PRIO_USER@*/
1328 /*@constant int RUSAGE_SELF@*/
1329 /*@constant int RUSAGE_CHILDREN@*/
1332 struct timeval ru_utime; /* user time used */
1333 struct timeval ru_stime; /* system time used */
1334 long ru_maxrss; /* max resident set size */
1335 long ru_ixrss; /* integral shared memory size */
1336 long ru_idrss; /* integral unshared data " */
1337 long ru_isrss; /* integral unshared stack " */
1338 long ru_minflt; /* page reclaims */
1339 long ru_majflt; /* page faults */
1340 long ru_nswap; /* swaps */
1341 long ru_inblock; /* block input operations */
1342 long ru_oublock; /* block output operations */
1343 long ru_msgsnd; /* messages sent */
1344 long ru_msgrcv; /* messages received */
1345 long ru_nsignals; /* signals received */
1346 long ru_nvcsw; /* voluntary context switches */
1347 long ru_nivcsw; /* involuntary " */
1356 unsigned long ldavg[3];
1361 getpriority (int which, int who)
1362 /*@modifies errno@*/;
1365 getrlimit (int res, /*@out@*/ struct rlimit *rlp)
1366 /*@modifies *rlp, errno@*/;
1369 getrusage (int who, /*@out@*/ struct rusage *rusage)
1370 /*@modifies *rusage, errno@*/;
1373 setpriority (int which, int who, int prio)
1374 /*@modifies errno, internalState@*/;
1377 setrlimit (int resource, const struct rlimit *rlp)
1378 /*@modifies errno, internalState@*/;
1387 /*@observer@*/ char *s_name; /* Official service name. */
1388 /*@observer@*/ char **s_aliases; /* Alias list. */
1389 int s_port; /* Port number. */
1390 /*@observer@*/ char *s_proto; /* Protocol to use. */
1393 /*@observer@*/ /*@dependent@*/ /*@null@*/ struct servent *getservbyname (const char *name, /*@null@*/ const char *proto)
1394 /*@warn multithreaded "Unsafe in multithreaded applications, use getsrvbyname_r instead"@*/ ;
1396 struct servent *getservbyname_r (const char *name, /*@null@*/ const char *proto, /*@out@*/ /*@returned@*/ struct servent *result, /*@out@*/ char *buffer, int buflen)
1397 /*@requires maxSet (buffer) >= buflen@*/ ;
1400 /*@observer@*/ /*@dependent@*/ struct servent *getservbyport (int port, /*@null@*/ const char *proto)
1401 /*@warn multithreaded "Unsafe in multithreaded applications, use getservbyport_r instead"@*/ ;
1403 struct servent *getservbyport_r (int port, /*@null@*/ const char *proto, /*@out@*/ /*@returned@*/ struct servent *result, /*@out@*/ char *buffer, int buflen)
1404 /*@requires maxSet (buffer) >= buflen@*/ ;
1406 /*@null@*/ struct servent *getservent (void);
1408 /*@null@*/ struct servent *getservent_r (struct servent *result, char *buffer, int buflen);
1410 int setservent (int stayopen);
1412 int endservent (void);
1417 /*@null@*/ /*@observer@*/ struct hostent *gethostbyname (/*@nullterminated@*/ /*@notnull@*/ const char *name)
1418 /*@warn multithreaded "Unsafe in multithreaded applications, use gethostbyname_r instead"@*/
1419 /*@modifies h_errno@*/ ;
1421 struct hostent *gethostbyname_r (/*@nullterminated@*/ const char *name, /*@notnull@*/ /*@returned@*/ struct hostent *hent, /*@out@*/ /*@exposed@*/ char *buffer, int bufsize, /*@out@*/ int *h_errnop)
1422 /*@requires maxSet(buffer) >= bufsize@*/ ;
1424 /*@null@*/ /*@observer@*/ struct hostent *gethostbyaddr (/*@notnull@*/ const void *addr, size_t addrlen, int type)
1425 /*@requires maxRead(addr) == addrlen@*/ /*@i534 ??? is this right? */
1426 /*@warn multithreaded "Unsafe in multithreaded applications, use gethostbyaddr_r instead"@*/
1427 /*@modifies h_errno@*/ ;
1429 struct hostent *gethostbyaddr_r (/*@notnull@*/ const void *addr, size_t addrlen, int type,
1430 /*@returned@*/ /*@out@*/ struct hostent *hent,
1431 /*@exposed@*/ /*@out@*/ char *buffer, int bufsize, /*@out@*/ int *h_errnop)
1432 /*@requires maxRead(addr) == addrlen
1433 /\ maxSet(buffer) >= bufsize@*/ /*@i534 ??? is this right? */ ;
1435 /*@observer@*/ /*@null@*/ struct hostent *gethostent (void)
1436 /*@warn multithreaded "Unsafe in multithreaded applications, use gethostent_r instead"@*/ ;
1438 struct hostent *gethostent_r (/*@out@*/ /*@returned@*/ struct hostent *hent, /*@exposed@*/ /*@out@*/ char *buffer, int bufsize)
1439 /*@requires maxSet(buffer) >= bufsize@*/ ;
1441 /*@i534 need to annotate these: */
1442 struct hostent *fgethostent(FILE *f);
1444 struct hostent *fgethostent_r(FILE*f, struct hostent *hent, char buffer, int bufsize);
1446 void sethostent(int stayopen);
1448 void endhostent(void);
1450 void herror(const char *string);
1452 char *hstrerror(int err);
1455 /*@observer@*/ /*@nullterminated@*/ char *h_name; /* official name of host */
1456 /*@observer@*/ /*@nullterminated@*/ char * /*:observer@*/ /*:nullterminated@*/ *h_aliases; /* alias list */
1457 int h_addrtype; /* host address type*/
1458 int h_length; /* length ofaddress*/
1459 /*@observer@*/ /*@nullterminated@*/ char * /*:observer@*/ /*:nullterminated@*/ *h_addr_list; /* list of addressesfrom name server */
1460 /*@observer@*/ /*@nullterminated@*/ char *h_addr; /* first address in list (backward compatibility) */
1467 typedef uint32_t in_addr_t;
1474 typedef uint16_t in_port_t;
1476 in_addr_t htonl (in_addr_t hostlong) /*@*/ ;
1477 in_port_t htons (in_port_t hostshort) /*@*/ ;
1478 in_addr_t ntohl (in_addr_t netlong) /*@*/ ;
1479 in_port_t ntohs (in_port_t netshort) /*@*/ ;
1485 int chroot (/*@notnull@*/ /*@nullterminated@*/ const char *path)
1487 /*@warn superuser "Only super-user processes may call chroot."@*/
1488 /*: other wanings? */ ;
1490 int fchroot (int fildes)
1492 /*@warn superuser "Only super-user processes may call fchroot."@*/ ;