45 #define HAVE_PLIBC_FD 0
55 #include <sys/types.h>
58 #include <sys/types.h>
64 #define __BYTE_ORDER BYTE_ORDER
65 #define __BIG_ENDIAN BIG_ENDIAN
71 #define Li2Double(x) ((double)((x).HighPart) * 4.294967296E9 + \
72 (double)((x).LowPart))
89 typedef unsigned int sa_family_t;
105 #define WEXITSTATUS(status) (((status) & 0xff00) >> 8)
109 #define MSG_DONTWAIT 0
134 #define EDEADLOCK EDEADLK
169 #define ENAMETOOLONG 91
172 #define EOPNOTSUPP 95
173 #define EPFNOSUPPORT 96
174 #define ECONNRESET 104
176 #define EAFNOSUPPORT 106
177 #define EPROTOTYPE 107
179 #define ENOPROTOOPT 109
180 #define ESHUTDOWN 110
181 #define ECONNREFUSED 111
182 #define EADDRINUSE 112
183 #define ECONNABORTED 113
184 #define ENETUNREACH 114
187 #define ETIMEDOUT 116
189 #define EHOSTDOWN 117
190 #define EHOSTUNREACH 118
191 #define EINPROGRESS 119
193 #define EDESTADDRREQ 121
195 #define EPROTONOSUPPORT 123
196 #define ESOCKTNOSUPPORT 124
197 #define EADDRNOTAVAIL 125
198 #define ENETRESET 126
201 #define ETOOMANYREFS 129
209 #define ENOMEDIUM 135
211 #define ECASECLASH 137
212 #define EWOULDBLOCK EAGAIN
213 #define EOVERFLOW 139
215 #undef HOST_NOT_FOUND
216 #define HOST_NOT_FOUND 1
220 #define NO_RECOVERY 3
224 #define PROT_READ 0x1
225 #define PROT_WRITE 0x2
226 #define MAP_SHARED 0x1
227 #define MAP_PRIVATE 0x2
228 #define MAP_FIXED 0x10
229 #define MAP_ANONYMOUS 0x20
230 #define MAP_FAILED ((void *)-1)
233 #define MS_INVALIDATE 2
250 extern const struct in6_addr in6addr_any;
251 extern const struct in6_addr in6addr_loopback;
255 enum SYSTEM_INFORMATION_CLASS
257 SystemBasicInformation = 0,
259 SystemPerformanceInformation = 2,
260 SystemTimeOfDayInformation = 3,
262 SystemProcessInformation = 5,
265 SystemProcessorPerformanceInformation = 8,
268 SystemDriverInformation,
278 SystemCacheInformation,
280 SystemInterruptInformation = 23,
281 SystemExceptionInformation = 33,
282 SystemRegistryQuotaInformation = 37,
283 SystemLookasideInformation = 45
288 LARGE_INTEGER IdleTime;
289 LARGE_INTEGER KernelTime;
290 LARGE_INTEGER UserTime;
291 LARGE_INTEGER Reserved1[2];
293 } SYSTEM_PROCESSOR_PERFORMANCE_INFORMATION;
295 #define sleep(secs) (Sleep(secs * 1000))
299 #define FAKED_BLOCK_SIZE 512
302 #define MSDOS_SUPER_MAGIC 0x4d44
303 #define NTFS_SUPER_MAGIC 0x5346544E
307 #define SHUT_RDWR SD_BOTH
329 #define SHUT_WR SD_SEND
330 #define SHUT_RD SD_RECEIVE
331 #define SHUT_RDWR SD_BOTH
336 #define SetErrnoFromWinError(e) _SetErrnoFromWinError(e, __FILE__, __LINE__)
338 BOOL _plibc_CreateShortcut(
const char *pszSrc,
const char *pszDest);
339 BOOL _plibc_CreateShortcutW(
const wchar_t *pwszSrc,
const wchar_t *pwszDest);
340 BOOL _plibc_DereferenceShortcut(
char *pszShortcut);
341 BOOL _plibc_DereferenceShortcutW(
wchar_t *pwszShortcut);
342 char *plibc_ChooseDir(
char *pszTitle,
unsigned long ulFlags);
343 wchar_t *plibc_ChooseDirW(
wchar_t *pwszTitle,
unsigned long ulFlags);
344 char *plibc_ChooseFile(
char *pszTitle,
unsigned long ulFlags);
345 wchar_t *plibc_ChooseFileW(
wchar_t *pwszTitle,
unsigned long ulFlags);
347 long QueryRegistry(HKEY hMainKey,
const char *pszKey,
const char *pszSubKey,
348 char *pszBuffer,
long *pdLength);
349 long QueryRegistryW(HKEY hMainKey,
const wchar_t *pszKey,
const wchar_t *pszSubKey,
350 wchar_t *pszBuffer,
long *pdLength);
352 BOOL __win_IsHandleMarkedAsBlocking(
int hHandle);
353 void __win_SetHandleBlockingMode(
int s, BOOL bBlocking);
354 void __win_DiscardHandleBlockingMode(
int s);
355 int _win_isSocketValid(
int s);
356 int plibc_conv_to_win_path(
const char *pszUnix,
char *pszWindows);
357 int plibc_conv_to_win_pathw(
const wchar_t *pszUnix,
wchar_t *pwszWindows);
359 int plibc_conv_to_win_pathwconv(
const char *pszUnix,
wchar_t *pwszWindows);
360 int plibc_conv_to_win_pathwconv_ex(
const char *pszUnix,
wchar_t *pszWindows,
int derefLinks);
362 unsigned plibc_get_handle_count();
364 typedef void (*TPanicProc) (int,
char *);
365 void plibc_set_panic_proc(TPanicProc proc);
367 int flock(
int fd,
int operation);
368 int fsync(
int fildes);
369 int inet_pton(
int af,
const char *src,
void *dst);
370 int inet_pton4(
const char *src, u_char *dst,
int pton);
372 int inet_pton6(
const char *src, u_char *dst);
374 int truncate(
const char *fname,
int distance);
375 int statfs(
const char *path,
struct statfs *buf);
376 const char *hstrerror(
int err);
377 int mkstemp(
char *tmplate);
378 char *strptime (
const char *buf,
const char *format,
struct tm *tm);
379 const char *inet_ntop(
int af,
const void *src,
char *dst,
size_t size);
381 struct tm *gmtime_r(
const time_t *clock,
struct tm *result);
384 int plibc_init(
char *pszOrg,
char *pszApp);
385 int plibc_init_utf8(
char *pszOrg,
char *pszApp,
int utf8_mode);
386 void plibc_shutdown();
387 int plibc_initialized();
389 void _SetErrnoFromWinError(
long lWinError,
char *pszCaller,
int iLine);
390 void SetErrnoFromWinsockError(
long lWinError);
391 void SetHErrnoFromWinError(
long lWinError);
392 void SetErrnoFromHRESULT(HRESULT hRes);
393 int GetErrnoFromWinsockError(
long lWinError);
394 FILE *_win_fopen(
const char *filename,
const char *mode);
395 int _win_fclose(FILE *);
396 DIR *_win_opendir(
const char *dirname);
397 struct dirent *_win_readdir(DIR *dirp);
398 int _win_closedir(DIR *dirp);
399 int _win_open(
const char *filename,
int oflag, ...);
401 char *_win_bindtextdomain(
const char *domainname,
const char *dirname);
403 int _win_chdir(
const char *path);
404 int _win_close(
int fd);
405 int _win_creat(
const char *path, mode_t mode);
406 char *_win_ctime(
const time_t *clock);
407 char *_win_ctime_r(
const time_t *clock,
char *buf);
408 int _win_fstat(
int handle,
struct stat *buffer);
409 int _win_ftruncate(
int fildes, off_t length);
410 void _win_gettimeofday(
struct timeval *tp,
void *tzp);
411 int _win_kill(pid_t pid,
int sig);
412 int _win_pipe(
int *phandles);
413 int _win_rmdir(
const char *path);
414 int _win_access(
const char *path,
int mode );
415 int _win_chmod(
const char *filename,
int pmode);
416 char *realpath(
const char *file_name,
char *resolved_name);
417 long _win_random(
void);
418 void _win_srandom(
unsigned int seed);
419 int _win_remove(
const char *path);
420 int _win_rename(
const char *oldname,
const char *newname);
421 int _win_stat(
const char *path,
struct stat *buffer);
422 int _win_stat64(
const char *path,
struct stat64 *buffer);
423 long _win_sysconf(
int name);
424 int _win_unlink(
const char *filename);
425 int _win_write(
int fildes,
const void *buf,
size_t nbyte);
426 int _win_read(
int fildes,
void *buf,
size_t nbyte);
427 size_t _win_fwrite(
const void *buffer,
size_t size,
size_t count, FILE *stream);
428 size_t _win_fread(
void *buffer,
size_t size,
size_t count, FILE *stream );
429 int _win_symlink(
const char *path1,
const char *path2);
430 void *_win_mmap(
void *start,
size_t len,
int access,
int flags,
int fd,
431 unsigned long long offset);
432 int _win_msync(
void *start,
size_t length,
int flags);
433 int _win_munmap(
void *start,
size_t length);
434 int _win_lstat(
const char *path,
struct stat *buf);
435 int _win_lstat64(
const char *path,
struct stat64 *buf);
436 int _win_readlink(
const char *path,
char *buf,
size_t bufsize);
437 int _win_accept(
int s,
struct sockaddr *addr,
int *addrlen);
439 int _win_printf(
const char *format,...);
440 int _win_wprintf(
const wchar_t *format, ...);
442 int _win_fprintf(FILE *f,
const char *format,...);
443 int _win_fwprintf(FILE *f,
const wchar_t *format, ...);
445 int _win_vprintf(
const char *format, va_list ap);
446 int _win_vfwprintf(FILE *stream,
const wchar_t *format, va_list arg_ptr);
448 int _win_vfprintf(FILE *stream,
const char *format, va_list arg_ptr);
449 int _win_vwprintf(
const wchar_t *format, va_list ap);
451 int _win_vsprintf(
char *dest,
const char *format, va_list arg_ptr);
452 int _win_vswprintf(
wchar_t *dest,
const wchar_t *format, va_list arg_ptr);
454 int _win_vsnprintf(
char* str,
size_t size,
const char *format, va_list arg_ptr);
455 int _win_vsnwprintf(
wchar_t* wstr,
size_t size,
const wchar_t *format, va_list arg_ptr);
457 int _win_snprintf(
char *str,
size_t size,
const char *format,...);
458 int _win_snwprintf(
wchar_t *str,
size_t size,
const wchar_t *format, ...);
460 int _win_sprintf(
char *dest,
const char *format,...);
461 int _win_swprintf(
wchar_t *dest,
const wchar_t *format, ...);
463 int _win_vsscanf(
const char* str,
const char* format, va_list arg_ptr);
464 int _win_vswscanf(
const wchar_t* wstr,
const wchar_t* format, va_list arg_ptr);
466 int _win_sscanf(
const char *str,
const char *format, ...);
467 int _win_swscanf(
const wchar_t *wstr,
const wchar_t *format, ...);
469 int _win_vfscanf(FILE *stream,
const char *format, va_list arg_ptr);
470 int _win_vfwscanf(FILE *stream,
const wchar_t *format, va_list arg_ptr);
472 int _win_vscanf(
const char *format, va_list arg_ptr);
473 int _win_vwscanf(
const wchar_t *format, va_list arg_ptr);
475 int _win_scanf(
const char *format, ...);
476 int _win_wscanf(
const wchar_t *format, ...);
478 int _win_fscanf(FILE *stream,
const char *format, ...);
479 int _win_fwscanf(FILE *stream,
const wchar_t *format, ...);
482 pid_t _win_waitpid(pid_t pid,
int *stat_loc,
int options);
483 int _win_bind(
int s,
const struct sockaddr *name,
int namelen);
484 int _win_connect(
int s,
const struct sockaddr *name,
int namelen);
485 int _win_getpeername(
int s,
struct sockaddr *name,
487 int _win_getsockname(
int s,
struct sockaddr *name,
489 int _win_getsockopt(
int s,
int level,
int optname,
char *optval,
491 int _win_listen(
int s,
int backlog);
492 int _win_recv(
int s,
char *buf,
int len,
int flags);
493 int _win_recvfrom(
int s,
void *buf,
int len,
int flags,
494 struct sockaddr *from,
int *fromlen);
495 int _win_select(
int max_fd, fd_set * rfds, fd_set * wfds, fd_set * efds,
496 const struct timeval *tv);
497 int _win_send(
int s,
const char *buf,
int len,
int flags);
498 int _win_sendto(
int s,
const char *buf,
int len,
int flags,
499 const struct sockaddr *to,
int tolen);
500 int _win_setsockopt(
int s,
int level,
int optname,
const void *optval,
502 int _win_shutdown(
int s,
int how);
503 int _win_socket(
int af,
int type,
int protocol);
504 struct hostent *_win_gethostbyaddr(
const char *addr,
int len,
int type);
505 struct hostent *_win_gethostbyname(
const char *name);
506 struct hostent *gethostbyname2(
const char *name,
int af);
507 char *_win_strerror(
int errnum);
509 char *index(
const char *s,
int c);
512 char *strndup (
const char *s,
size_t n);
515 size_t strnlen (
const char *str,
size_t maxlen);
517 char *stpcpy(
char *dest,
const char *src);
518 char *strcasestr(
const char *haystack_start,
const char *needle_start);
520 #define strcasecmp(a, b) stricmp(a, b)
521 #define wcscasecmp(a, b) wcsicmp(a, b)
522 #define strncasecmp(a, b, c) strnicmp(a, b, c)
523 #define wcsncasecmp(a, b, c) wcsnicmp(a, b, c)
528 #define DIR_SEPARATOR '/'
529 #define DIR_SEPARATOR_STR "/"
530 #define PATH_SEPARATOR ':'
531 #define PATH_SEPARATOR_STR ":"
535 #define BINDTEXTDOMAIN(d, n) bindtextdomain(d, n)
537 #define CREAT(p, m) creat(p, m)
538 #define PLIBC_CTIME(c) ctime(c)
539 #define CTIME_R(c, b) ctime_r(c, b)
541 #define FOPEN(f, m) fopen(f, m)
542 #define FCLOSE(f) fclose(f)
543 #define FTRUNCATE(f, l) ftruncate(f, l)
544 #define OPENDIR(d) opendir(d)
545 #define CLOSEDIR(d) closedir(d)
546 #define READDIR(d) readdir(d)
548 #define CHDIR(d) chdir(d)
549 #define CLOSE(f) close(f)
550 #define LSEEK(f, o, w) lseek(f, o, w)
551 #define RMDIR(f) rmdir(f)
552 #define ACCESS(p, m) access(p, m)
553 #define CHMOD(f, p) chmod(f, p)
554 #define FSTAT(h, b) fstat(h, b)
555 #define PLIBC_KILL(p, s) kill(p, s)
556 #define PIPE(h) pipe(h)
557 #define REMOVE(p) remove(p)
558 #define RENAME(o, n) rename(o, n)
559 #define STAT(p, b) stat(p, b)
560 #define STAT64(p, b) stat64(p, b)
561 #define SYSCONF(n) sysconf(n)
562 #define UNLINK(f) unlink(f)
563 #define WRITE(f, b, n) write(f, b, n)
564 #define READ(f, b, n) read(f, b, n)
565 #define GN_FREAD(b, s, c, f) fread(b, s, c, f)
566 #define GN_FWRITE(b, s, c, f) fwrite(b, s, c, f)
567 #define SYMLINK(a, b) symlink(a, b)
568 #define MMAP(s, l, p, f, d, o) mmap(s, l, p, f, d, o)
569 #define MKFIFO(p, m) mkfifo(p, m)
570 #define MSYNC(s, l, f) msync(s, l, f)
571 #define MUNMAP(s, l) munmap(s, l)
572 #define STRERROR(i) strerror(i)
573 #define RANDOM() random()
574 #define SRANDOM(s) srandom(s)
575 #define READLINK(p, b, s) readlink(p, b, s)
576 #define LSTAT(p, b) lstat(p, b)
577 #define LSTAT64(p, b) lstat64(p, b)
578 #define PRINTF printf
579 #define FPRINTF fprintf
580 #define VPRINTF(f, a) vprintf(f, a)
581 #define VFPRINTF(s, f, a) vfprintf(s, f, a)
582 #define VSPRINTF(d, f, a) vsprintf(d, f, a)
583 #define VSNPRINTF(str, size, fmt, a) vsnprintf(str, size, fmt, a)
584 #define _REAL_SNPRINTF snprintf
585 #define SPRINTF sprintf
586 #define VSSCANF(s, f, a) vsscanf(s, f, a)
587 #define SSCANF sscanf
588 #define VFSCANF(s, f, a) vfscanf(s, f, a)
589 #define VSCANF(f, a) vscanf(f, a)
591 #define FSCANF fscanf
592 #define WAITPID(p, s, o) waitpid(p, s, o)
593 #define ACCEPT(s, a, l) accept(s, a, l)
594 #define BIND(s, n, l) bind(s, n, l)
595 #define CONNECT(s, n, l) connect(s, n, l)
596 #define GETPEERNAME(s, n, l) getpeername(s, n, l)
597 #define GETSOCKNAME(s, n, l) getsockname(s, n, l)
598 #define GETSOCKOPT(s, l, o, v, p) getsockopt(s, l, o, v, p)
599 #define LISTEN(s, b) listen(s, b)
600 #define RECV(s, b, l, f) recv(s, b, l, f)
601 #define RECVFROM(s, b, l, f, r, o) recvfrom(s, b, l, f, r, o)
602 #define SELECT(n, r, w, e, t) select(n, r, w, e, t)
603 #define SEND(s, b, l, f) send(s, b, l, f)
604 #define SENDTO(s, b, l, f, o, n) sendto(s, b, l, f, o, n)
605 #define SETSOCKOPT(s, l, o, v, n) setsockopt(s, l, o, v, n)
606 #define SHUTDOWN(s, h) shutdown(s, h)
607 #define SOCKET(a, t, p) socket(a, t, p)
608 #define GETHOSTBYADDR(a, l, t) gethostbyname(a, l, t)
609 #define GETHOSTBYNAME(n) gethostbyname(n)
610 #define GETTIMEOFDAY(t, n) gettimeofday(t, n)
611 #define INSQUE(e, p) insque(e, p)
612 #define REMQUE(e) remque(e)
613 #define HSEARCH(i, a) hsearch(i, a)
614 #define HCREATE(n) hcreate(n)
615 #define HDESTROY() hdestroy()
616 #define HSEARCH_R(i, a, r, h) hsearch_r(i, a, r, h)
617 #define HCREATE_R(n, h) hcreate_r(n, h)
618 #define HDESTROY_R(h) hdestroy_r(h)
619 #define TSEARCH(k, r, c) tsearch(k, r, c)
620 #define TFIND(k, r, c) tfind(k, r, c)
621 #define TDELETE(k, r, c) tdelete(k, r, c)
622 #define TWALK(r, a) twalk(r, a)
623 #define TDESTROY(r, f) tdestroy(r, f)
624 #define LFIND(k, b, n, s, c) lfind(k, b, n, s, c)
625 #define LSEARCH(k, b, n, s, c) lsearch(k, b, n, s, c)
627 #define DIR_SEPARATOR '\\'
628 #define DIR_SEPARATOR_STR "\\"
629 #define PATH_SEPARATOR ';'
630 #define PATH_SEPARATOR_STR ";"
631 #define NEWLINE "\r\n"
634 #define BINDTEXTDOMAIN(d, n) _win_bindtextdomain(d, n)
636 #define CREAT(p, m) _win_creat(p, m)
637 #define PLIBC_CTIME(c) _win_ctime(c)
638 #define CTIME_R(c, b) _win_ctime_r(c, b)
639 #define FOPEN(f, m) _win_fopen(f, m)
640 #define FCLOSE(f) _win_fclose(f)
641 #define FTRUNCATE(f, l) _win_ftruncate(f, l)
642 #define OPENDIR(d) _win_opendir(d)
643 #define CLOSEDIR(d) _win_closedir(d)
644 #define READDIR(d) _win_readdir(d)
645 #define OPEN _win_open
646 #define CHDIR(d) _win_chdir(d)
647 #define CLOSE(f) _win_close(f)
648 #define PLIBC_KILL(p, s) _win_kill(p, s)
649 #define LSEEK(f, o, w) _win_lseek(f, o, w)
650 #define FSTAT(h, b) _win_fstat(h, b)
651 #define RMDIR(f) _win_rmdir(f)
652 #define ACCESS(p, m) _win_access(p, m)
653 #define CHMOD(f, p) _win_chmod(f, p)
654 #define PIPE(h) _win_pipe(h)
655 #define RANDOM() _win_random()
656 #define SRANDOM(s) _win_srandom(s)
657 #define REMOVE(p) _win_remove(p)
658 #define RENAME(o, n) _win_rename(o, n)
659 #define STAT(p, b) _win_stat(p, b)
660 #define STAT64(p, b) _win_stat64(p, b)
661 #define SYSCONF(n) _win_sysconf(n)
662 #define UNLINK(f) _win_unlink(f)
663 #define WRITE(f, b, n) _win_write(f, b, n)
664 #define READ(f, b, n) _win_read(f, b, n)
665 #define GN_FREAD(b, s, c, f) _win_fread(b, s, c, f)
666 #define GN_FWRITE(b, s, c, f) _win_fwrite(b, s, c, f)
667 #define SYMLINK(a, b) _win_symlink(a, b)
668 #define MMAP(s, l, p, f, d, o) _win_mmap(s, l, p, f, d, o)
669 #define MKFIFO(p, m) _win_mkfifo(p, m)
670 #define MSYNC(s, l, f) _win_msync(s, l, f)
671 #define MUNMAP(s, l) _win_munmap(s, l)
672 #define STRERROR(i) _win_strerror(i)
673 #define READLINK(p, b, s) _win_readlink(p, b, s)
674 #define LSTAT(p, b) _win_lstat(p, b)
675 #define LSTAT64(p, b) _win_lstat64(p, b)
676 #define PRINTF(f, ...) _win_printf(f , __VA_ARGS__)
677 #define FPRINTF(fil, fmt, ...) _win_fprintf(fil, fmt, __VA_ARGS__)
678 #define VPRINTF(f, a) _win_vprintf(f, a)
679 #define VFPRINTF(s, f, a) _win_vfprintf(s, f, a)
680 #define VSPRINTF(d, f, a) _win_vsprintf(d, f, a)
681 #define VSNPRINTF(str, size, fmt, a) _win_vsnprintf(str, size, fmt, a)
682 #define _REAL_SNPRINTF(str, size, fmt, ...) _win_snprintf(str, size, fmt, __VA_ARGS__)
683 #define SPRINTF(d, f, ...) _win_sprintf(d, f, __VA_ARGS__)
684 #define VSSCANF(s, f, a) _win_vsscanf(s, f, a)
685 #define SSCANF(s, f, ...) _win_sscanf(s, f, __VA_ARGS__)
686 #define VFSCANF(s, f, a) _win_vfscanf(s, f, a)
687 #define VSCANF(f, a) _win_vscanf(f, a)
688 #define SCANF(f, ...) _win_scanf(f, __VA_ARGS__)
689 #define FSCANF(s, f, ...) _win_fscanf(s, f, __VA_ARGS__)
690 #define WAITPID(p, s, o) _win_waitpid(p, s, o)
691 #define ACCEPT(s, a, l) _win_accept(s, a, l)
692 #define BIND(s, n, l) _win_bind(s, n, l)
693 #define CONNECT(s, n, l) _win_connect(s, n, l)
694 #define GETPEERNAME(s, n, l) _win_getpeername(s, n, l)
695 #define GETSOCKNAME(s, n, l) _win_getsockname(s, n, l)
696 #define GETSOCKOPT(s, l, o, v, p) _win_getsockopt(s, l, o, v, p)
697 #define LISTEN(s, b) _win_listen(s, b)
698 #define RECV(s, b, l, f) _win_recv(s, b, l, f)
699 #define RECVFROM(s, b, l, f, r, o) _win_recvfrom(s, b, l, f, r, o)
700 #define SELECT(n, r, w, e, t) _win_select(n, r, w, e, t)
701 #define SEND(s, b, l, f) _win_send(s, b, l, f)
702 #define SENDTO(s, b, l, f, o, n) _win_sendto(s, b, l, f, o, n)
703 #define SETSOCKOPT(s, l, o, v, n) _win_setsockopt(s, l, o, v, n)
704 #define SHUTDOWN(s, h) _win_shutdown(s, h)
705 #define SOCKET(a, t, p) _win_socket(a, t, p)
706 #define GETHOSTBYADDR(a, l, t) _win_gethostbyname(a, l, t)
707 #define GETHOSTBYNAME(n) _win_gethostbyname(n)
708 #define GETTIMEOFDAY(t, n) _win_gettimeofday(t, n)
709 #define INSQUE(e, p) _win_insque(e, p)
710 #define REMQUE(e) _win_remque(e)
711 #define HSEARCH(i, a) _win_hsearch(i, a)
712 #define HCREATE(n) _win_hcreate(n)
713 #define HDESTROY() _win_hdestroy()
714 #define HSEARCH_R(i, a, r, h) _win_hsearch_r(i, a, r, h)
715 #define HCREATE_R(n, h) _win_hcreate_r(n, h)
716 #define HDESTROY_R(h) _win_hdestroy_r(h)
717 #define TSEARCH(k, r, c) _win_tsearch(k, r, c)
718 #define TFIND(k, r, c) _win_tfind(k, r, c)
719 #define TDELETE(k, r, c) _win_tdelete(k, r, c)
720 #define TWALK(r, a) _win_twalk(r, a)
721 #define TDESTROY(r, f) _win_tdestroy(r, f)
722 #define LFIND(k, b, n, s, c) _win_lfind(k, b, n, s, c)
723 #define LSEARCH(k, b, n, s, c) _win_lsearch(k, b, n, s, c)
825 void *
_win_tsearch (__const
void *__key,
void **__rootp,
830 void *
_win_tfind (__const
void *__key,
void *__const *__rootp,
835 void **__restrict __rootp,
855 void *
_win_lfind (__const
void *__key, __const
void *__base,