% Librarian A09-32ԗ,SIGNALaSOCKET,INPWDTIMESWCTYPE`r REENTRANCYv RESOLVRESOURCE SCTPSCTP_UIO^SEM SEMAPHORE"SETJMP.SIGINFO>,SIGNALaSOCKETSTATSTATVFSSTDARGSTDBOOLSTDDEFvSTDIOA@STDLIBfSTRINGSTRINGSSTROPTSTCPTGMATHTIMElTIMEBTIMERSNTIMES&TYPES3TZFILE5UIO@UNISTDpUNIXIO~UNIXLIBtUTIMEUTSNAME VARARGSVMSWAITWCHAR&TYPES3TZFILE5UIO@UNISTDpUNIXIO~UNIXLIBtUTIMEUTSNAME VARARGSVMSWAITWCHAR`WCTYPE 6%ԗ VMS_V84-005ww)\%ԗ#ifndef __ASSERT_LOADED#define __ASSERT_LOADEDM/******************************************************************************$** - Program Diagnostics**M*****************************************************************************,** Header introduced by the ANSI C StandardM*****************************************************************************I**  I** Copyright 2006 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subjec t to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*K** If the user has used /pointer_size=short or /pointer_size=long, we will5** allow long pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endif/*** Function prototypes*/Cvoid __assert (const char *__expr, const char *__file, int __line);/*7** Define an assert macro based on NDEBUG and __STDC__*/ #undef assert #ifdef NDEBUG$# define assert(ignore) ((void) 0)#else4# if !defined (__STDC__) && !defined (__cplusplus)Q# define assert(expr) ((expr)?(void)0:(__assert("expr",__FILE__,__LINE__)))# elseP# define assert(expr) ((expr)?(void)0:(__assert(#expr,__FILE__,__LINE__))) # endif#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __ASSERT_LOADED */ww N%ԗ#ifndef __BITYPES_LOADED#define __BITYPES_LOADED 1M/******************************************************************************&** - basic integral types**M******************************************************************************* Header is nonstandardM*****************************************************************************I** I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP p roducts I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M*******************************************************************************?** Copyright (c) 1993 Regents of the University of California.** All rights reserved.**L** Redistribution and use in source and binary forms are permitted providedJ** that: (1) source distributions retain this entire copyright notice andK** comment, and (2) distributions including binaries display the followingG** acknowledgement: ``This product includes software developed by theD** University of California, Berkeley and its contributors'' in theJ** documentation or other materials provided with the distribution and inJ** all advertising materials mentioning features or use of this  software.L** Neither the name of the University nor the names of its contributors mayM** be used to endorse or promote products derived from this software without&** specific prior written permission.J** THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIEDH** WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF9** MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.**N*******************************************************************************/#pragma __nostandard/*B** Most of these definitions are in which we include1** first and then add those missing definitions.*/#include /*E** Ensure that the compiler will not emit diagnostics about "signed"J** keyword usage when in /STAND=VAXC mode (the reason for the diagnostics7** is that VAX C does not support the signed keyword).*/4#if ((__DECC_VER >= 50600000) && !defined(__DECCXX))# pragma __message __save.# pragma __message __disable (__SIGNEDKNOWN)#endif/*<** Basic integral types which are not defined in inttypes.h*/typedef signed char int8m_t;typedef unsigned char u_int8_t; typedef unsigned char u_int8m_t;typedef short int int16m_t;%typedef unsigned short int u_int16_t;&typedef unsigned short int u_int16m_t;typedef int int32m_t;typedef unsigned int u_int32_t; typedef unsigned int u_int32m_t;/*K** The VAX implementation is just a placeholder until the C9X work is done*/#if !defined(__VAX) typedef __int64 int64m_t;& typedef unsigned __int64 u_int64_t;& typedef unsigned __int64 uint64m_t;#else/*7** Set __nomember_alignment to avoid internal and tail2** padding in structures; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment3 typedef struct { int __p1; int __p2; } int64m_t;F typedef struct { unsigned int __p1; unsigned int __p2; } u_int64_t;F  typedef struct { unsigned int __p1; unsigned int __p2; } uint64m_t;$#pragma __member_alignment __restore#endif/*** Restore messages*/4#if ((__DECC_VER >= 50600000) && !defined(__DECCXX))# pragma __message __restore#endif#pragma __standard#endif /* __BITYPES_LOADED */wws%ԗ#ifndef __BUILTINS_LOADED#define __BUILTINS_LOADED 1M/******************************************************************************<** - Prototypes for platfo rm specific builtins**M******************************************************************************* Header is nonstandardM*****************************************************************************I** I** Copyright 2008 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I**  I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additiona!l warranty. I** M******************************************************************************/#pragma __nostandard #include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*A** This header file is divided into the following four sections:**8 "** OpenVMS IA64 - Just those builtins unique to ia64H** OpenVMS AXP and ia64 (some produce diagnostics on ia64 as marked)*** OpenVMS AXP and ia64 with __X_FLOAT*** OpenVMS VAX DEC C Only (No DEC C++)*/J/************************************************************************/%#if defined(__ia64) && defined(__VMS)J/************************************************************************//*H** Parameters that must be specified as compile-time integer constants.C** Alth#ough this typedef does not actually behave differently fromE** "plain int" for a parameter, it suggests the intent - the builtin?** functions themselves will enforce the use of a compile-time,** constant for parameters that require it.*/) typedef const int __Integer_Constant;/*K** Selected OS Related Itanium Built-ins defined by Intel's *//*A** The __whichReg and __whichIndReg parameters are values defined ** below.*//**D*** Copyright (C) 1985-2001 Inte$l Corporation. All rights reserved.***E*** The information and source code contained herein is the exclusiveD*** property of Intel Corporation and may not be disclosed, examinedL*** or reproduced in whole or in part without explicit written authorization*** from the company.*****/#ifndef _IA64REGS_H_INCLUDED#define _IA64REGS_H_INCLUDED /* */2 /* Register Names for getReg() and setReg() */ /* */ /* Special Registers */,#define _IA64_REG_IP 1016 /* ge%tReg only */$#define _IA64_REG_PSR_UM 1017#define _IA64_REG_PSR 1019#define _IA64_REG_PSR_L 1019# /* General Integer Registers */"#define _IA64_REG_GP 1025 /* R1 */##define _IA64_REG_SP 1036 /* R12 */##define _IA64_REG_TP 1037 /* R13 */ /* Application Registers */#define _IA64_REG_AR_KR0 3072#define _IA64_REG_AR_KR1 3073#define _IA64_REG_AR_KR2 3074#define _IA64_REG_AR_KR3 3075#define _IA64_REG_AR_KR4 3076#define _IA64_REG_AR_KR5 3077#define &_IA64_REG_AR_KR6 3078#define _IA64_REG_AR_KR7 3079#define _IA64_REG_AR_RSC 3088#define _IA64_REG_AR_BSP 3089"#define _IA64_REG_AR_BSPSTORE 3090#define _IA64_REG_AR_RNAT 3091#define _IA64_REG_AR_FCR 3093#define _IA64_REG_AR_EFLAG 3096#define _IA64_REG_AR_CSD 3097#define _IA64_REG_AR_SSD 3098#define _IA64_REG_AR_CFLAG 3099#define _IA64_REG_AR_FSR 3100#define _IA64_REG_AR_FIR 3101#define _IA64_REG_AR_FDR 3102#define _IA64_REG_AR_CCV 3104#define _IA64_REG_AR_UNAT '3108#define _IA64_REG_AR_FPSR 3112#define _IA64_REG_AR_ITC 3116#define _IA64_REG_AR_RUC 3117#define _IA64_REG_AR_PFS 3136#define _IA64_REG_AR_LC 3137#define _IA64_REG_AR_EC 3138 /* Control Registers */#define _IA64_REG_CR_DCR 4096#define _IA64_REG_CR_ITM 4097#define _IA64_REG_CR_IVA 4098#define _IA64_REG_CR_PTA 4104#define _IA64_REG_CR_IPSR 4112#define _IA64_REG_CR_ISR 4113#define _IA64_REG_CR_IIP 4115#define _IA64_REG_CR_IFA 4116#define _IA64_REG_CR_I(TIR 4117#define _IA64_REG_CR_IIPA 4118#define _IA64_REG_CR_IFS 4119#define _IA64_REG_CR_IIM 4120#define _IA64_REG_CR_IHA 4121#define _IA64_REG_CR_IIB0 4122#define _IA64_REG_CR_IIB1 4123#define _IA64_REG_CR_LID 4160/#define _IA64_REG_CR_IVR 4161 /* getReg only */#define _IA64_REG_CR_TPR 4162#define _IA64_REG_CR_EOI 41630#define _IA64_REG_CR_IRR0 4164 /* getReg only */0#define _IA64_REG_CR_IRR1 4165 /* getReg only */0#define _IA64_REG_CR_IRR2 4166 /* getReg only */0#define )_IA64_REG_CR_IRR3 4167 /* getReg only */#define _IA64_REG_CR_ITV 4168#define _IA64_REG_CR_PMV 4169#define _IA64_REG_CR_CMCV 4170#define _IA64_REG_CR_LRR0 4176#define _IA64_REG_CR_LRR1 4177< /* Indirect Registers for getIndReg() and setIndReg() */6#define _IA64_REG_INDR_CPUID 9000 /* getIndReg only */#define _IA64_REG_INDR_DBR 9001#define _IA64_REG_INDR_IBR 9002#define _IA64_REG_INDR_PKR 9003#define _IA64_REG_INDR_PMC 9004#define _IA64_REG_INDR_PMD 9005#define _IA6*4_REG_INDR_RR 9006!#endif /* _IA64REGS_H_INCLUDED */= unsigned __int64 __getReg(__Integer_Constant __whichReg);1 void __setReg(__Integer_Constant __whichReg,! unsigned __int64 __value);B unsigned __int64 __getIndReg(__Integer_Constant __whichIndReg,@ __int64 __index);7 void __setIndReg(__Integer_Constant __whichIndReg,? __int64 __index,$ unsigned __int64 __val+ue);O void __break(__Integer_Constant __break_arg); /* Native ia64, arg as-is */ void __dsrlz(void);! void __fc(__int64 __address);" void __fci(__int64 __address); void __fwb(void); void __invalat(void);> void __invala(void); /* alternate spelling of __invalat */ void __isrlz(void);# void __itcd(__int64 __address);# void __itci(__int64 __address);/*E** The __whichTransReg param selects an Address Translation Register,<** GEM_TS_REG_K_AR[0 ,..127] and is an integer from 0-127 like=** whichFloatReg (GEM_TS_REG_K_F[0..127]) and whichGeneralReg** (GEM_TS_REG_K_R[0..127]).** K** GEM engineering says that the number of Address Translation Registers isB** processor dependent - a small integer <= 31 would probably work** on most any processor.*/< void __itrd(__int64 __whichTransReg, __int64 __address);< void __itri(__int64 __whichTransReg, __int64 __address);# void __ptce(__int64 __address);5 void __ptcl(__int6 -4 __address, __int64 __pagesz);5 void __ptcg(__int64 __address, __int64 __pagesz);6 void __ptcga(__int64 __address, __int64 __pagesz);5 void __ptri(__int64 __address, __int64 __pagesz);5 void __ptrd(__int64 __address, __int64 __pagesz);* void __rsm(__Integer_Constant __mask);* void __rum(__Integer_Constant __mask);* void __ssm(__Integer_Constant __mask);* void __sum(__Integer_Constant __mask); void __synci(void);3 __int64 /*address*/ __thash(__int64 __ad.dress);2 __int64 /*address*/ __ttag(__int64 __address);/* GEM IA64 built-ins*/2 void __break2(__Integer_Constant __break_code," unsigned __int64 __r17_value); void __flushrs(void); void __loadrs(void);9 int __prober(__int64 __address, unsigned int __mode);9 int __probew(__int64 __address, unsigned int __mode);* unsigned int __tak(__int64 __address);1 __int64 /*address*/ __tpa(__int64 __address);J/*********************************************/***************************/#endif /* __ia64 && __VMS */J/************************************************************************//*E** Certain OpenVMS header files expect the __PAL builtins to accept D** 64-bit pointers regardless of whether the /POINTER_SIZE is used E** or not. To allow this, we will define a typedef to be used with ** those prototypes.*/%#if defined __ALPHA || defined __ia64# ifndef ___VOID__PTR64# define ___VOID__PTR64 1## ifdef __INITIAL0_POINTER_SIZE## if __INITIAL_POINTER_SIZE)# pragma __pointer_size __save%# pragma __pointer_size 64# else2# pragma __required_pointer_size __save.# pragma __required_pointer_size 64# endif( typedef void * ___void__ptr64;3 typedef const void * __const_void__ptr64;## if __INITIAL_POINTER_SIZE,# pragma __pointer_size __restore# else5# pragma __required_p1ointer_size __restore# endif # else2 typedef unsigned __int64 ___void__ptr64; # endif # endif#endif#if defined(__VMS)H/***********************************************************************H** typedefs for return values of built-ins common for VAX and Alpha **H***********************************************************************/>typedef enum {_bbcci_oldval_1, _bbcci_oldval_0} _BBCCI_STATUS;>typedef enum {_bbssi_oldval_0, _bbssi_oldval_1 2} _BBSSI_STATUS;Otypedef enum {_insqi_inserted_many, _insqi_not_inserted, _insqi_inserted_only}  _INSQI_STATUS;Ktypedef enum {_insque_inserted_only, _insque_inserted_many} _INSQUE_STATUS;Ftypedef enum {_probe_not_accessible, _probe_accessible} _PROBE_STATUS;itypedef enum {_remqi_removed_more, _remqi_not_removed, _remqi_removed_empty, _remqi_empty} _REMQI_STATUS;Ytypedef enum {_remque_removed_more, _remque_removed_empty, _remque_empty} _REMQUE_STATUS;#endif /* defined(__VMS) */ 3J/************************************************************************/%#if !defined(__VAX) && defined(__VMS)J/************************************************************************//*2** The following builtins were added in DEC C V5.2*/:#if (__DECC_VER >= 50200000) || (__DECCXX_VER >= 50200000)A /************************************************************8 ** DEC C builtins for atomic/interlocked operationsA ********************************************************** 4*** **K ** These functions are not easily/efficiently implemented using inlineO ** assembly code, and so the compiler has builtin knowledge of their namesO ** and signatures in order to generate fast and reliable code (e.g. it mayF ** generate loops with tests arranged for branch prediction using6 ** out-of-line branch targets for failure paths). **N ** The _RETRY variants store a non-zero status if the operation completesJ ** successfully within the sp 5ecified number of retries. The variants8 ** without _RETRY do not return until they succeed.N ** Note: On ia64, all of the _RETRY variants other than __LOCK_LONG_RETRYL ** and __ACQUIRE_SEM_LONG_RETRY evaluate the retry count expression butH ** do not otherwise use it as the ia64 instructions underlying them2 ** cannot complete until they have succeeded. **O ** The following operations do not in themselves generate Memory Barriers.I ** The user is expected to 6code explicitly any Memory Barriers whereI ** needed using inline assembly code, e.g. asm("mb"), or asm("wmb"). **O ** Many of these builtins perform essentially the same operations as otherH ** builtins having similar names but with the ATOMIC or INTERLOCKEDO ** appearing in a different position. The following group with the ATOMICJ ** or INTERLOCKED first offer several usability improvements over theL ** older versions with the ATOMIC or INTERLOCKED appearing 7later in theF ** name. The older versions are retained for compatibility only. **M ** Usability problems with the older builtins that are addressed by this+ ** newer set introduced in DEC C V5.2: **C ** Old versions did not provide the pre-updated value, and N ** provided status even with infinite retry, in which case the builtinH ** does not return until it succeeds. New versions provide theO ** old value, and only provide status when the 8 limited-retry variant is ** used. **M ** Older versions generated memory barriers both before and after theK ** update. Newer versions allow the user to control memory barrier2 ** placement for the low-level primitives. **K ** Older versions did not provide for efficient spinlock or countedM ** semaphore implementation. There are new higher-level spinlock andO ** counted semaphore operations that include a test of the stored va9lueM ** to control success, and generate memory barriers just after a lockB ** or resource is acquired, and just before it is release. */ /*> ** The following set of functions may pass long pointers. */# if __INITIAL_POINTER_SIZE# pragma __pointer_size 64 # endif /*L ** Atomic update of location with integer operation, returning previous ** contents.L ** Note: _RETRY variants produce a warning on ia64, and always succeed. : */ int __ATOMIC_ADD_LONG3 (volatile void *__addr, int __expr);# int __ATOMIC_ADD_LONG_RETRYL (volatile void *__addr, int __expr, int __retry, int *__sts); __int64 __ATOMIC_ADD_QUAD7 (volatile void *__addr, __int64 __expr);# __int64 __ATOMIC_ADD_QUAD_RETRYP (volatile void *__addr, __int64 __expr, int __retry, int *__sts); int __ATOMIC_AND_LONG3 (volatile void *__addr, int __expr); ;# int __ATOMIC_AND_LONG_RETRYL (volatile void *__addr, int __expr, int __retry, int *__sts); __int64 __ATOMIC_AND_QUAD7 (volatile void *__addr, __int64 __expr);# __int64 __ATOMIC_AND_QUAD_RETRYP (volatile void *__addr, __int64 __expr, int __retry, int *__sts); int __ATOMIC_OR_LONG3 (volatile void *__addr, int __expr);" int __ATOMIC_OR_LONG_RETRYL (volatile void *__addr, int __expr, int< __retry, int *__sts); __int64 __ATOMIC_OR_QUAD7 (volatile void *__addr, __int64 __expr);" __int64 __ATOMIC_OR_QUAD_RETRYP (volatile void *__addr, __int64 __expr, int __retry, int *__sts); /*> ** Just like __ATOMIC_ADD, but using +1 or -1 implicitly. */# int __ATOMIC_INCREMENT_LONG' (volatile void *__addr);) int __ATOMIC_INCREMENT_LONG_RETRY@ (volatile void *__addr, int __retry, int *__sts);# = __int64 __ATOMIC_INCREMENT_QUAD' (volatile void *__addr);) __int64 __ATOMIC_INCREMENT_QUAD_RETRY@ (volatile void *__addr, int __retry, int *__sts);# int __ATOMIC_DECREMENT_LONG' (volatile void *__addr);) int __ATOMIC_DECREMENT_LONG_RETRY@ (volatile void *__addr, int __retry, int *__sts);# __int64 __ATOMIC_DECREMENT_QUAD' (volatile void *__addr);) __int64 __ATOMIC_DECREMENT_QUAD_RETRY>@ (volatile void *__addr, int __retry, int *__sts); /*O ** Atomic replacement of location's contents, returning previous contents. */ int __ATOMIC_EXCH_LONG3 (volatile void *__addr, int __expr);$ int __ATOMIC_EXCH_LONG_RETRYL (volatile void *__addr, int __expr, int __retry, int *__sts); __int64 __ATOMIC_EXCH_QUAD7 (volatile void *__addr, __int64 __expr);$ __int64 __ATOMIC_EXCH_QUAD_RETRYP ? (volatile void *__addr, __int64 __expr, int __retry, int *__sts); /*M ** Interlocked "test for bit clear and then clear". Returns non-zero if ** bit was already clear. */( int __INTERLOCKED_TESTBITCC_QUAD5 (volatile void *__addr, int __bitpos);. int __INTERLOCKED_TESTBITCC_QUAD_RETRYN (volatile void *__addr, int __bitpos, int __retry, int *__sts); /*M ** Interlocked "test for bit set and then set". Returns no @n-zero if bit ** was already set. */( int __INTERLOCKED_TESTBITSS_QUAD5 (volatile void *__addr, int __bitpos);. int __INTERLOCKED_TESTBITSS_QUAD_RETRYN (volatile void *__addr, int __bitpos, int __retry, int *__sts); /*M ** Acquire/release binary spinlock based on low-order bit of a longword.I ** NOTE: Memory barrier generated after lock, before unlock. _RETRYB ** variant returns non-zero on success within retry attemptAs.L ** Note: On ia64, the _RETRY forms of__LOCK_LONG and __ACQUIRE_SEM_LONG" ** are fully supported. */ void __LOCK_LONG' (volatile void *__addr); int __LOCK_LONG_RETRY4 (volatile void *__addr, int __retry); void __UNLOCK_LONG' (volatile void *__addr); /*M ** Acquire/release counted semaphore based on positive value of longword1 ** indicating number of resources available. **I **B NOTE: Memory barrier generated after acquisition, before release.I ** _RETRY variant returns non-zero on success within retry attempts. */ void __ACQUIRE_SEM_LONG' (volatile void *__addr);$ int __ACQUIRE_SEM_LONG_RETRY4 (volatile void *__addr, int __retry); void __RELEASE_SEM_LONG' (volatile void *__addr); /*D ** Done with the set of functions which may pass long pointers. */# if __INITIAL_POINTERC_SIZE# pragma __pointer_size 32 # endifD#endif /* (__DECC_VER >= 50200000) || (__DECCXX_VER >= 50200000) *//*** xxxQUE Mapping TablesI** These tables map the _PAL returned values into VAX C expected values.*/8#define __xxxQUE_MAP_ALPHA_TO_VAX(z) ((0x12 >> (z)) & 3)>#define __REMQxI_MAP_ALPHA_TO_VAX(z) (((0x0c >> (z)) + 1) & 3)/*7** All longword queue operations take 32-bit pointers.*/#ifdef __INITIAL_POINTER_SIZE)# pragma __required_pointer_size __save%D# pragma __required_pointer_size 32#endif/*E** All 24 queue manipulation "PAL calls" are supported on both AlphaG** and ia64 platforms, using the same names and interfaces shown here.F** It just happens that the code generated is a PAL call on Alpha and+** a call to a VMS system service on ia64.*//* "** Insertion into longword queues*/Nint __PAL_INSQHIL (void *__head, void *__new); /* At head, interlocked */Nint __PAL_INSQTIL (void *__head, void *__new); /* A Et tail, interlocked */Oint __PAL_INSQUEL (void *__pred, void *__new); /* At pred, interlocked */ Nint __PAL_INSQUEL_D (void **__pred, void *__new); /* At pred, indirectly */Nint __PAL_INSQHILR (void *__head, void *__new); /* At head, interlocked */Nint __PAL_INSQTILR (void *__head, void *__new); /* At tail, interlocked *//* %** Removal from from longword queues*/Nint __PAL_REMQHIL (void *__head, void **__rem); /* At head, interlocked */Nint __PAL_REMQTIL (void F *__head, void **__rem); /* At tail, interlocked */Nint __PAL_REMQUEL (void *__entr, void **__rem); /* At entr, interlocked */Nint __PAL_REMQUEL_D (void **__entr, void **__rem); /* At entr, indirectly */Nint __PAL_REMQHILR (void *__head, void **__rem); /* At head, interlocked */Nint __PAL_REMQTILR (void *__head, void **__rem); /* At tail, interlocked *//*7** All quadword queue operations take 64-bit pointers.*/#ifdef __INITIAL_POINTER_SIZE%# pragma __required_pointer_ Gsize 64#endif/* "** Insertion into quadword queues*/Nint __PAL_INSQHIQ (void *__head, void *__new); /* At head, interlocked */Nint __PAL_INSQTIQ (void *__head, void *__new); /* At tail, interlocked */Nint __PAL_INSQUEQ (void *__pred, void *__new); /* At pred, interlocked */Nint __PAL_INSQUEQ_D (void **__pred, void *__new); /* At pred, indirectly */Nint __PAL_INSQHIQR (void *__head, void *__new); /* At head, interlocked */Nint __PAL_INSQTIQR (void *__head, vo Hid *__new); /* At tail, interlocked *//* ** Removal from quadword queues*/Nint __PAL_REMQHIQ (void *__head, void **__rem); /* At head, interlocked */Nint __PAL_REMQTIQ (void *__head, void **__rem); /* At tail, interlocked */Nint __PAL_REMQUEQ (void *__entr, void **__rem); /* At entr, interlocked */Nint __PAL_REMQUEQ_D (void **__entr, void **__rem); /* At entr, indirectly */Nint __PAL_REMQHIQR (void *__head, void **__rem); /* At head, interlocked */Nint __PAL_REMQTIIQR (void *__head, void **__rem); /* At tail, interlocked */ /*.** Restore the original required_pointer_size*/#ifdef __INITIAL_POINTER_SIZE,# pragma __required_pointer_size __restore#endif/*:** The following set of functions may pass long pointers.*/#if __INITIAL_POINTER_SIZE#pragma __pointer_size 64#endif/* ** Move from Processor RegisterL** Note: None of these MFPR PAL calls are implemented in the ia64 compiler.4** Some may be overridden in */Punsigned int __PAL_MFPR_ASTEN (void); /* AST Enable */Punsigned int __PAL_MFPR_ASTSR (void); /* AST Summary Register */Pvoid * __PAL_MFPR_ESP (void); /* Executive Stack Pointer */Pint __PAL_MFPR_FEN (void); /* Floating Point Enable */Pint __PAL_MFPR_IPL (void); /* Interrupt Priority Level */P__int64 __PAL_MFPR_MCES (void); /* Machine Check Error Summary K*/Pvoid * __PAL_MFPR_PCBB (void); /* Priv Context Block Base */P__int64 __PAL_MFPR_PRBR (void); /* Processor Base Register */Pint __PAL_MFPR_PTBR (void); /* Page Table Base Register */Pvoid * __PAL_MFPR_SCBB (void); /* System Control Block Base */Punsigned int __PAL_MFPR_SISR (void); /* Software Int Summ Register */Pvoid * __PAL_MFPR_SSP (void); /* Supervisor Stack Pointer */P__int64 L __PAL_MFPR_TBCHK (void *__addr); /* Translation Buffer Check */Pvoid * __PAL_MFPR_USP (void); /* User Stack Pointer */Pvoid * __PAL_MFPR_VPTB (void); /* Virtual Page Table */P__int64 __PAL_MFPR_WHAMI (void); /* Who Am I *//*** Move to Processor RegisterL** Note: None of these MTPR PAL calls are implemented in the ia64 compiler.4** Some may be overridden in */Pvoid __PAL_MTPMR_ASTEN (unsigned int __mask); /* AST Enable */Pvoid __PAL_MTPR_ASTSR (unsigned int __mask); /* AST Summary Register */Pvoid __PAL_MTPR_DATFX (int __value); /* Data Alignment Trap Fixup */Pvoid __PAL_MTPR_ESP (void *__addr); /* Executive Stack Pointer */Pvoid __PAL_MTPR_FEN (int __value); /* Floating Point Enable */Pvoid __PAL_MTPR_IPIR (__int64 __number); /* Interprocessor Inter Req */Pint __PAL_MTPR_IPL (int _N_value); /* Interrupt Priority Level */Pvoid __PAL_MTPR_MCES (__int64 __value); /* Machine Check Error Summary */Pvoid __PAL_MTPR_PRBR (__int64 __value); /* Processor Base Register */Pvoid __PAL_MTPR_SCBB (void *__addr); /* System Control Block Base */Pvoid __PAL_MTPR_SIRR (int __level); /* Software Inter Req Register */Pvoid __PAL_MTPR_SSP (int *__addr); /* Supervisor Stack Pointer */Pvoid __PAL_MTPR_TBIA (void); O /* User Stack Pointer */Pvoid __PAL_MTPR_TBIAP (void); /* T Buffer Inval All Process */Pvoid __PAL_MTPR_TBIS (___void__ptr64 __addr); /* T Buffer Inval Single */Pvoid __PAL_MTPR_TBISD (___void__ptr64 __addr); /* T Buffer Inval Single Data */Pvoid __PAL_MTPR_TBISI (___void__ptr64 __addr); /* T Buffer Inval Single Instr */Gvoid __PAL_MTPR_USP (void *__addr); /* User Stack Pointer */Gvoid __PAL_MTPR_VPTB (void *__addr); /* Virtual Page TPable *//*"** Probe Read/Write AccessibilityN** Note: Not a builtin in ia64 compiler, to be overridden in @** See also ia64-specific __prober and __probew builtins.*/Hint __PAL_PROBER(const void *__base_address, int __offset, char __mode);Hint __PAL_PROBEW(const void *__base_address, int __offset, char __mode);/*** Change Mode O** Note: Not a builtin in ia64 compiler, may be overridden in */?void __PAL_CHME(void); Q /* Executive */?void __PAL_CHMK(void); /* Kernel */?void __PAL_CHMS(void); /* Supervisor */?void __PAL_CHMU(void); /* User *//* ** Load/Store Quadword PhysicalN** Note: Not a builtin in ia64 compiler, to be overridden in */Iunsigned __int64 __PAL_LDQP(void *__addr); /* Load */Ivoid __PAL_STQP(void *__addr, unsigned __int64 __value); /* Store *//*@** DoRne with the set of functions which may pass long pointers.*/#if __INITIAL_POINTER_SIZE#pragma __pointer_size 32#endif/*** Cache FlushN** Note: Not a builtin in ia64 compiler, to be overridden in */void __PAL_CFLUSH(int __value);/*** Drain Aborts** Note: Not on ia64*/void __PAL_DRAINA(void);/*** Read Processor StatusN** Note: Not a builtin in ia64 compiler, to be overridden in */#unsigned __int64 __PAL_RD_PS(void);S/*** Swap AST EnableN** Note: Not a builtin in ia64 compiler, to be overridden in */1unsigned int __PAL_SWASTEN(int __new_state_mask);/*)** Write Processor Status Software FieldN** Note: Not a builtin in ia64 compiler, to be overridden in */ void __PAL_WR_PS_SW(int __mask);/*'** Convert from G-Floating to Quadword** Note: Not on ia64*/#__int64 __CVTGQ(double __operand1);/*1** Convert from G-Floating to F-Floating Chopped** TNote: Not on ia64*/#float __CVTGF_C(double __operand1);/*** Add Floating Point Chopped** Note: Not on ia64*/6float __ADDF_C(float __operand1, float __operand2);6double __ADDG_C(double __operand1, double __operand2);/*#** Subtract Floating Point Chopped** Note: Not on ia64*/6float __SUBF_C(float __operand1, float __operand2);6double __SUBG_C(double __operand1, double __operand2);/*#** Multiply Floating Point Chopped** Note: Not on ia64*/6float __MUULF_C(float __operand1, float __operand2);6double __MULG_C(double __operand1, double __operand2);/*!** Divide Floating Point Chopped** Note: Not on ia64*/6float __DIVF_C(float __operand1, float __operand2);6double __DIVG_C(double __operand1, double __operand2);/*=** Macros for translation from VAX C to DEC C ALPHA builtins*/E#define _BBCCI(position, address) __TESTBITCCI((address), (position))E#define _BBSSI(position, address) __TESTBITSSI((address), (position)):#d Vefine _INSQHI(new_entry, head) \> ((0x12 >> (__PAL_INSQHIL((head), (new_entry))+2)) & 3):#define _INSQTI(new_entry, head) \> ((0x12 >> (__PAL_INSQTIL((head), (new_entry))+2)) & 3)A#define _INSQUE(new_entry, predecessor) \E ((0x12 >> (__PAL_INSQUEL((predecessor), (new_entry))+1)) & 3)>#define _REMQHI(head, removed_entry) \O (((0x0c >> (__PAL_REMQHIL((head), (void ** W)(removed_entry))+1))+1) & 3)>#define _REMQTI(head, removed_entry) \O (((0x0c >> (__PAL_REMQTIL((head), (void **)(removed_entry))+1))+1) & 3)?#define _REMQUE(entry, removed_entry) \L ((0x12 >> (__PAL_REMQUEL((entry), (void **)(removed_entry))+1)) & 3)P#define _PROBER(mode, offset, address) __PAL_PROBER((address), (offset), (mode))P#define _PROBEW(mode, offset, address) __PAL_PROBEW((address), (offset), (mode))/*6** __ALLOXCA builtin - allocate n-bytes from the stack*/"void * __ALLOCA(unsigned int __x);/*?** The remaining functions can handle accepting long pointers.*/#if __INITIAL_POINTER_SIZE#pragma __pointer_size 64#endif/*3** UMULH Builtin - Unsigned Quadword Multiply High*/Munsigned __int64 __UMULH(unsigned __int64 __oper1, unsigned __int64 __oper2);/*** op_ATOMIC_size Builtins**5** Note: There is one optional retry count parameter ** Note: Retry form not on ia64*/ Y5int __ADD_ATOMIC_LONG(void *__addr, int __expr, ...);5int __ADD_ATOMIC_QUAD(void *__addr, int __expr, ...);5int __AND_ATOMIC_LONG(void *__addr, int __expr, ...);5int __AND_ATOMIC_QUAD(void *__addr, int __expr, ...);4int __OR_ATOMIC_LONG(void *__addr, int __expr, ...);4int __OR_ATOMIC_QUAD(void *__addr, int __expr, ...);/*** TESTBITxxI**5** Note: There is one optional retry count parameter ** Note: Retry form not on ia64*/4int __TESTBITCCI(void *__addr, int __position, .Z..);4int __TESTBITSSI(void *__addr, int __position, ...);/* ** Add Aligned Word Interlocked*/1int __ADAWI(short __src, volatile short *__dest);/*** Trap Barrier Instruction** Note: Not on ia64*/void __TRAPB(void);/*** Read Cycle CounterN** Note: Not a builtin in ia64 compiler, to be overridden in */unsigned __int64 __RPCC(void);/*$** Halt the Processor. (Privileged)N** Note: Not a builtin in ia64 compiler, to be overridden in */void _HALT(void);void __PAL_HALT(void);/*** Generate TrapN** Note: Not a builtin in ia64 compiler, to be overridden in 1** Note: argument must be compile-time constant.*/=void __PAL_GENTRAP(unsigned __int64 __encoded_software_trap);/*** BreakpointN** Note: Not a builtin in ia64 compiler, to be overridden in */void __PAL_BPT(void);/* ** BugcheckN** Note: Not a builtin in ia64 compiler, to be overridden in */L#if defined __ia64 || (__DECC_VER >= 70130074) || (__DECCXX_VER >= 70130074))void __PAL_BUGCHK(unsigned __int64 code);#elsevoid __PAL_BUGCHK(void);#endif/*** Swap Privileged Context** Note: Not on ia64*/ void __PAL_SWPCTX(void *__addr);/* ** Copy Sign** Note: Not on ia64*/6float __CPYSF (float __operand1, float __operand2);6double __CPYS (double __operand1, double __operand2);/*** Copy Sign Negate** Note: Not on ia64*/6float __CPYSNF(floa]t __operand1, float __operand2);6double __CPYSN (double __operand1, double __operand2);/*** Copy Sign Exponent** Note: Not on ia64*/6float __CPYSEF(float __operand1, float __operand2);6double __CPYSE (double __operand1, double __operand2);/*'** Convert from T-Floating to Quadword** Note: Not on ia64*/#__int64 __CVTTQ(double __operand1);/*1** Convert from T-Floating to S-Floating Chopped** Note: Not on ia64*/#float __CVTTS_C(double __operand1);/*^** Add Floating Point Chopped** Note: Not on ia64*/6float __ADDS_C(float __operand1, float __operand2);6double __ADDT_C(double __operand1, double __operand2);/*#** Subtract Floating Point Chopped** Note: Not on ia64*/6float __SUBS_C(float __operand1, float __operand2);6double __SUBT_C(double __operand1, double __operand2);/*#** Multiply Floating Point Chopped** Note: Not on ia64*/6float __MULS_C(float __operand1, float __operand2);6double __MULT_C(double_ __operand1, double __operand2);/*!** Divide Floating Point Chopped** Note: Not on ia64*/6float __DIVS_C(float __operand1, float __operand2);6double __DIVT_C(double __operand1, double __operand2);/*** Memory Barrier*/void __MB(void);/*** Instruction Memory BarrierN** Note: Not a builtin in ia64 compiler, to be overridden in */#if defined(__ia64): void __PAL_IMB(void * instr, unsigned __int64 length);#else void __PAL_IMB(void);`#endif /* __ia64 *//*** Compare, Store Long/QuadE** Note: On ia64, these produce a warning if the compiler can verifyF** that the source and destination addresses are the same, elseE** they produce an error. These builtins should be consideredK** deprecated, to be replaced by __CMP_SWAP_LONG and __CMP_SWAP_QUAD.** when they become available on Alpha.*/int __CMP_STORE_LONG= (volatile void *__src, int __oldval, int __newval, ! a volatile void *__dst);int __CMP_STORE_QUADE (volatile void *__src, __int64 __oldval, __int64 __newval, ! volatile void *__dst);/*8** Compare and swap (__CMP_SWAP* and _Interlocked*), and:** __RETURN_ADDRESS - IA64 and Alpha compilers after V6.5.*/4#if defined(__ia64) || \4 (defined(__alpha) && (__DECC_VER >= 60600000 || \! __DECCXX_VER >= 60600000) ) /*2 ** Compare and swap returning status (1 or 0). */ b int __CMP_SWAP_LONG8 (volatile void *__addr, int __comparand, int __newval); int __CMP_SWAP_QUAD@ (volatile void *__addr, __int64 __comparand, __int64 __newval); /*E ** OS Related Itanium Built-ins defined by Intel's ? ** for compare and swap returning old value with acquire or ** release semantics.  ** M ** Unordered data accesses may become visible in any order. Acquire dataL ** accesses quarantee that they are made visible prior to all csubsequentM ** data accesses. Release data accesses guarantee that all previous dataH ** accesses are made visible prior to being made visible themselves. **7 ** See also __CMP_SWAP_[LONG|QUAD]_[ACQ|REL] below. */4 unsigned __int64 _InterlockedCompareExchange_acq$ (unsigned int *__Destination, unsigned __int64 __Newval,$ unsigned __int64 __Comparand);6 unsigned __int64 _InterlockedCompareExchange64_acq% (unsigned __int64 *__Destination, udnsigned __int64 __Newval,$ unsigned __int64 __Comparand);4 unsigned __int64 _InterlockedCompareExchange_rel% (unsigned int *__Destination, unsigned __int64 __Newval,$ unsigned __int64 __Comparand);6 unsigned __int64 _InterlockedCompareExchange64_rel% (unsigned __int64 *__Destination, unsigned __int64 __Newval,$ unsigned __int64 __Comparand); /*A ** Compare and swap returning status (1 or 0) with acquire or ** release semantics. e **  ** Nota Bene:B ** _Interlocked* built-ins return the old value and have theA ** newval and comparand arguments in a different order than@ ** __CMP_SWAP* built-ins that return the status (1 or 0).  */ int __CMP_SWAP_LONG_ACQ8 (volatile void *__addr, int __comparand, int __newval); int __CMP_SWAP_QUAD_ACQ@ (volatile void *__addr, __int64 __comparand, __int64 __newval); int __CMP_SWAP_LONG_REL8 (volatile void *__addr, int __comparand, int __fnewval); int __CMP_SWAP_QUAD_REL@ (volatile void *__addr, __int64 __comparand, __int64 __newval); /*E ** Produce the value of R26 (Alpha) or B0 (IA64) on entry to theF ** function containing a call to this builtin. Cannot be invoked2 ** from a function with non-standard linkage. */# __int64 __RETURN_ADDRESS(void);#endif/*J** The following intrinsics were added in DEC C V5.7 and DIGITAL C++ V6.0*/:#if (__DECC_VER >= 50700000) || (__DECCXX_VER >= 600g00000)' __int64 _popcnt (unsigned __int64);' __int64 _poppar (unsigned __int64);' __int64 _leadz (unsigned __int64);' __int64 _trailz (unsigned __int64);8# pragma intrinsic (_popcnt, _poppar, _leadz, _trailz)D#endif /* (__DECC_VER >= 50700000) || (__DECCXX_VER >= 60000000) *//*8** Reset the pointer size prior to leaving this section*/#if __INITIAL_POINTER_SIZE#pragma __pointer_size 32#endifJ/*************************************************************h***********/*#endif /* (__ALPHA || __ia64) && __VMS */J/************************************************************************/J/************************************************************************/;#if !defined(__VAX) && defined(__VMS) && defined(__X_FLOAT)J/************************************************************************//*'** Convert from X-Floating to Quadword** Note: Not on ia64*/(__int64 __CVTXQ(long double __operand1);/*1** Convert from X-Floatinig to T-Floating Chopped** Note: Not on ia64*/)double __CVTXT_C(long double __operand1);/*** Add Floating Point Chopped** Note: Not on ia64*/Elong double __ADDX_C(long double __operand1, long double __operand2);/*#** Subtract Floating Point Chopped** Note: Not on ia64*/Elong double __SUBX_C(long double __operand1, long double __operand2);/*#** Multiply Floating Point Chopped** Note: Not on ia64*/Elong double __MULX_C(long double __operand1, long doubjle __operand2);/*!** Divide Floating Point Chopped** Note: Not on ia64*/Elong double __DIVX_C(long double __operand1, long double __operand2);J/************************************************************************/7#endif /* (__ALPHA || __ia64) && __VMS && __X_FLOAT */J/************************************************************************/J/************************************************************************/7#if defined(__VAX) && defined(__VMS) && defined(__DEkCC)J/************************************************************************//*0** The following builtin was added in DEC C V6.0*/#if (__DECC_VER >= 60000000)& void * __ALLOCA(unsigned int __x);#endif/*2** The following builtins were added in DEC C V5.2*/#if (__DECC_VER >= 50200000) /*$ ** Processor Register Management */E typedef enum {_value_replaced, _value_not_replaced} _MTPR_STATUS;8 void _MFPR(int __register_num, void *__destination);< l_MTPR_STATUS _MTPR(int __new_value, int __register_num); /* ** Processor control */ void _HALT(void); /* ** General Register query */; typedef enum {_R0, _R1, _R2, _R3, _R4, _R5, _R6, _R7,M _R8, _R9, _R10, _R11, _AP, _FP, _SP, _PC} _REGISTER_NUMBER;> int _READ_GPR(_REGISTER_NUMBER __general_register_number);$#endif /* __DECC_VER >= 50200000 *//* ** Add Aligned Word Interlocked*/Ntypedef enum {_adawi_sum_neg=-1,_adawim_sum_zero,_adawi_sum_pos} _ADAWI_STATUS;1_ADAWI_STATUS _ADAWI(short __src, short *__dest);/*** Interlocked branch group*/3_BBCCI_STATUS _BBCCI(int __position, void *__addr);3_BBSSI_STATUS _BBSSI(int __position, void *__addr);/*** Find First bit group*/;typedef enum {_ff_bit_not_found, _ff_bit_found} _FF_STATUS;O_FF_STATUS _FFC(int __start, char __size, const void *__base, int *__position);O_FF_STATUS _FFS(int __start, char __size, const void *__base, int *__position);n/*** Insert into a queue group*/7_INSQI_STATUS _INSQHI(void *__new_entry, void *__head);7_INSQI_STATUS _INSQTI(void *__new_entry, void *__head);?_INSQUE_STATUS _INSQUE(void *__new_entry, void *__predecessor);/*** Character processing group*/Xunsigned short _LOCC(char __target, unsigned short __length, const char *__string, ...);Kvoid _MOVC3(unsigned short __length, const char *__src, char *__dest, ...);rvoid _MOVC5(unsigned short __srclen, const char *__src, char __fill, uonsigned short __destlen, char *__dest, ...);lunsigned short _SCANC(unsigned short __length, const char *__string, const char *__table, char __mask, ...);Xunsigned short _SKPC(char __target, unsigned short __length, const char *__string, ...);lunsigned short _SPANC(unsigned short __length, const char *__string, const char *__table, char __mask, ...);/*&** Obtain the program status longword*/void _MOVPSL(void *__psl);/*** Probe memory group*/P_PROBE_STATUS _PROBER(char __mode, u pnsigned short __length, const void *__addr);P_PROBE_STATUS _PROBEW(char __mode, unsigned short __length, const void *__addr);/*** Remove from a queue group*/;_REMQI_STATUS _REMQHI(void *__head, void *__removed_entry);;_REMQI_STATUS _REMQTI(void *__head, void *__removed_entry);=_REMQUE_STATUS _REMQUE(void *__entry, void *__removed_entry);J/************************************************************************/#endif /* __VAX && __VMS */J/*************************************q***********************************//*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif%#if defined(__ia64) && defined(__VMS)# include #endif /* __ia64 && __VMS */#ifdef __cplusplus }#endif#pragma __standard #endif /* __BUILTINS_LOADED */wwv&ԗ#ifndef __COMPLEX_LOADED#define __COMPLEX_LOADED 1M/*********************************************************** r*******************'** - C99 complex data type**M*****************************************************************************)** Header introduced by the C99 StandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Csonfidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. t I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing huerein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include (#if defined(__DECCXX) && defined(__ia64)?#error "The complex package has been retired on this platform."#endifE#if !( !defined(__VAX) && defined(__DECC) && __DECC_vVER >= 60400000 )E# error "C99 header is not supported by this compiler."#elif __D_FLOATE# error "The complex data type is not supported in D_FLOAT format."#else#define complex _Complex/*= * Because the _Complex_I define is recursive, we avoid it inA * vaxc mode - the compiler message saying the complex data typesB * are not supported in this language mode is what we want to see,' * not the recursive expansion message. */#if !defined(__VAXC)!# define _wComplex_I _Complex_I #endif#define I _Complex_I2extern double complex cacos (double complex __z);1extern float complex cacosf (float complex __z);<extern long double complex cacosl (long double complex __z);2extern double complex casin (double complex __z);1extern float complex casinf (float complex __z);<extern long double complex casinl (long double complex __z);2extern double complex catan (double complex __z);1extern float complex catanf (float complex __z);<extern long xdouble complex catanl (long double complex __z);1extern double complex ccos (double complex __z);0extern float complex ccosf (float complex __z);;extern long double complex ccosl (long double complex __z);1extern double complex csin (double complex __z);0extern float complex csinf (float complex __z);;extern long double complex csinl (long double complex __z);1extern double complex ctan (double complex __z);0extern float complex ctanf (float complex __z);;extern long double complex y ctanl (long double complex __z);3extern double complex cacosh (double complex __z);2extern float complex cacoshf (float complex __z);=extern long double complex cacoshl (long double complex __z);3extern double complex casinh (double complex __z);2extern float complex casinhf (float complex __z);=extern long double complex casinhl (long double complex __z);3extern double complex catanh (double complex __z);2extern float complex catanhf (float complex __z);=extern long double compl zex catanhl (long double complex __z);2extern double complex ccosh (double complex __z);1extern float complex ccoshf (float complex __z);<extern long double complex ccoshl (long double complex __z);2extern double complex csinh (double complex __z);1extern float complex csinhf (float complex __z);<extern long double complex csinhl (long double complex __z);2extern double complex ctanh (double complex __z);1extern float complex ctanhf (float complex __z);<extern long double complex cta {nhl (long double complex __z);1extern double complex cexp (double complex __z);0extern float complex cexpf (float complex __z);;extern long double complex cexpl (long double complex __z);1extern double complex clog (double complex __z);0extern float complex clogf (float complex __z);;extern long double complex clogl (long double complex __z);!#if defined(_MATH_H_DEFINED_CABS)1# pragma __message ("Compaq C Restriction: " \9 " defined incompatible declarations " |\= "for cabs(), cabsf(), and cabsl() using struct types. " \9 "To get correct c99 declarations for these " \= "functions, you must #include before the " \9 "#include of , or compile using /STAND=C99.")#else# if (__DECC_VER < 60500000)# define cabsl MATH$CABS_X# if __IEEE_FLOAT!# define cabs MATH$HYPOT_T!# define cabsf MATH$HYPOT_S# else!# define cabs MATH$HYPOT_G!# define cabsf MATH$HYPOT_F # endif }# endif- extern double cabs (double complex __z);, extern float cabsf (float complex __z);8 extern long double cabsl (long double complex __z);#endifEextern double complex cpow (double complex __x, double complex __y);Cextern float complex cpowf (float complex __x, float complex __y);;extern long double complex cpowl (long double complex __x,$ long double complex __y);2extern double complex csqrt (double complex __z);1extern float complex csqrtf (float co ~mplex __z);<extern long double complex csqrtl (long double complex __z);*extern double carg (double complex __z);)extern float cargf (float complex __z);4extern long double cargl (long double complex __z);+extern double cimag (double complex __z);*extern float cimagf (float complex __z);5extern long double cimagl (long double complex __z);1extern double complex conj (double complex __z);0extern float complex conjf (float complex __z);;extern long double complex conjl (long double complex __z);2extern double complex cproj (double complex __z);1extern float complex cprojf (float complex __z);<extern long double complex cprojl (long double complex __z);+extern double creal (double complex __z);*extern float crealf (float complex __z);5extern long double creall (long double complex __z);W#endif /* !defined(__VAX) && defined(__DECC) && __DECC_VER >= 60400000 && !__D_FLOAT */#pragma __standard#endif /* __COMPLEX_LOADED */ww&ԗ#ifndef __CTYPE_LOADED#define __CTYPE_LOADED#ifndef __CTYPE_PROCESSED#define __CTYPE_PROCESSEDM/******************************************************************************=** - Character Type Classification Macros/Routines**M*****************************************************************************,** Header introduced by the ANSI C StandardM*****************************************************************************I**  I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*K** If the user has used /pointer_size=short or /pointer_size=long, we will+** begin in a 32-bit pointer size context.*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*%** 4.3.1 Character Testing Functions*/#ifdef __NAMESPACE_STD # pragma __extern_prefix __save!# pragma __extern_prefix "CXXL$"#endifint isalnum (int);int isalpha (int);int iscntrl (int);int isdigit (int);int isgraph (int);int islower (int);int isprint (int);int ispunct (int);int isspace (int);int isupper (int);int isxdigit (int);#ifdef __NAMESPACE_STD## pragma __extern_prefix __restore#endif/**** 4.3.2 Character Case Mapping Functions*/int tolower (int);int toupper (int);#ifdef __NAMESPACE_STD} /* namespace std */#endifO/********************************************************************************** OpenVMS V6.2 and later**O******************************************************************************/#if __CRTL_VER >= 60200000*# define __ctypet (decc$$ga___ctypet)*# define __ctypea (decc$$gl___ctypea)-# define __isclocale (decc$$gl___isclocale) # pragma __extern_model __save)# pragma __extern_model __strict_refdef /*A ** Classmask array __ctypet is declared as a pointer in order? ** to prevent BADSUBSCRIPT message which otherwise would beE ** issued by the compiler when one of the is* functions is calledB ** with EOF and, accordingly, __ISFUNCTION macro below expands ** into __ctypet[-1] */+ extern const unsigned int * __ctypet ; extern int __ctypea ; extern int __isclocale ;## pragma __extern_model __restore# define __UPPER 0x1# define __LOWER 0x2# define __DIGIT 0x4# define __SPACE 0x8# define __PUNCT  0x10# define __CNTRL 0x20# define __XDIGIT 0x40# define __PRINT 0x80# define __ALPHABET 0x100# define __ALNUM 0x104# define __GRAPH 0x200# define __BLANK 0X400"# define __ISALPHABET (isalpha)"# define __ISCNTRL (iscntrl)"# define __ISUPPER (isupper)"# define __ISLOWER (islower)"# define __ISDIGIT (isdigit)"# define __ISSPACE (isspace)"# define __ISPUNCT (ispunct)## define __ISXDIGIT (isxdigit)"# define __ISPRINT (isprint)"# define __ISGRAPH (isgraph)"# define __ISALNUM (isalnum)/*J** Throughout this header file, for a C++ compilation with __NAMESPACE_STDM** enabled, functions from ANSI C standard that are defined as macros in thisB** header file, are defined as inline functions instead of macros.**J** This is to comply with clause 17.4.1.2 Headers [lib.headers] of the C++&** standard which says, in particular:J-6- Names that are defined as functions in C shall be defined as functions" in the C++ Standard Library.*)L*) This disallows the practice, allowed in C, of providing a "masking macro"L in addition to the function prototype. The only way to achieve equivalentJ "inline" behavior in C++ is to provide a definition as an extern inline function.*/#ifndef __NAMESPACE_STD/*** Macro definitions*/L# define __ISFUNCTION(c,p) (__ctypea?__ctypet[(int)(c)]&__##p:__IS##p(c))-# define iscntrl(c) __ISFUNCTION(c, CNTRL)-# define isalnum(c) __ISFUNCTION(c, ALNUM)0# define isalpha(c) __ISFUNCTION(c, ALPHABET)-# define isdigit(c) __ISFUNCTION(c, DIGIT)-# define isgraph(c) __ISFUNCTION(c, GRAPH)-# define islower(c) __ISFUNCTION(c, LOWER)-# define isprint(c) __ISFUNCTION(c, PRINT)-# define ispunct(c) __ISFUNCTION(c, PUNCT)-# define isspace(c) __ISFUNCTION(c, SPACE).# define isxdigit(c) __ISFUNCTION(c, XDIGIT)-# define isupper(c) __ISFUNCTION(c, UPPER)#else/*** Inline functions*/namespace std {$#define __INLINE_ISFUNCTION(c,p) { \9 /* no need to check __ctypea on VMS V6.2 and above */ \D return (c == __EOF ? 0 : __ctypet[(unsigned) c & 0xff] & __##p); \}8inline int iscntrl(int c) __INLINE_ISFUNCTION(c, CNTRL)8inline int isalnum(int c) __INLINE_ISFUNCTION(c, ALNUM);inline int isalpha(int c) __INLINE_ISFUNCTION(c, ALPHABET)8inline int isdigit(int c) __INLINE_ISFUNCTION(c, DIGIT)8inline int isgraph(int c) __INLINE_ISFUNCTION(c, GRAPH)8inline int islower(int c) __INLINE_ISFUNCTION(c, LOWER)8inline int isprint(int c) __INLINE_ISFUNCTION(c, PRINT)8inline int ispunct(int c) __INLINE_ISFUNCTION(c, PUNCT)8inline int isspace(int c) __INLINE_ISFUNCTION(c, SPACE)9inline int isxdigit(int c) __INLINE_ISFUNCTION(c, XDIGIT)8inline int isupper(int c) __INLINE_ISFUNCTION(c, UPPER)} /* namespace std */#endif /* __NAMESPACE_STD */9# define __IS_LOWER(c) (((c) >= 'a' && (c) <= 'z')?1:0)9# define __IS_UPPER(c) (((c) >= 'A' && (c) <= 'Z')?1:0)/* ** X/Open extensions*/ 9# if defined(_XOPEN_SOURCE) || !defined(_ANSI_C_SOURCE)# if defined(_FAST_TOUPPER)< /* Note - these evaluate macro parameters multiple times */Z# define _toupper(c) (__isclocale? (__IS_LOWER(c) ? (c) & 0xDF: (c)): (toupper)(c))Z# define _tolower(c) (__isclocale? (__IS_UPPER(c) ? (c) | 0x20: (c)): (tolower)(c)) # else"# define _toupper(c) (toupper)(c)"# define _tolower(c) (tolower)(c) # endif int isascii (int); int toascii (int);1# define isascii(c) ((unsigned)(c) <= 0x7F)&# define toascii(c) ((c) & 0x7F) # endif#endifO/********************************************************************************** Prior to OpenVMS V6.2**O******************************************************************************/#if __CRTL_VER < 60200000%# define __ctype (*decc$ga___ctype) # pragma __extern_model __save)# pragma __extern_model __strict_refdef! extern const char __ctype [];## pragma __extern_model __restore# define _U 0x1# define _L 0x2# define _D 0x4# define _S 0x8# define _P 0x10# define _C 0x20# define _X 0x40# define _B 0x80# ifdef __DECC# pragma __message __save(# pragma __message __disable (__CHECK) # endif$ static int __iscntrl (int __c) {% /* Check explicitly for EOF */6 return __c < 0 ? 0 : __ctype [__c & 0xFF] & _C; }# define iscntrl __iscntrl# ifdef __DECC# pragma __message __restore # endif># define isalnum(c) (__ctype [(c) & 0xFF] & (_U | _L | _D))9# define isalpha(c) (__ctype [(c) & 0xFF] & (_U | _L))2# define isdigit(c) (__ctype [(c) & 0xFF] & _D)C# define isgraph(c) (__ctype [(c) & 0xFF] & (_P | _U | _L | _D))2# define islower(c) (__ctype [(c) & 0xFF] & _L)H# define isprint(c) (__ctype [(c) & 0xFF] & (_P | _U | _L | _D | _B))2# define ispunct(c) (__ctype [(c) & 0xFF] & _P)2# define isspace(c) (__ctype [(c) & 0xFF] & _S)2# define isupper(c) (__ctype [(c) & 0xFF] & _U)2# define isxdigit(c) (__ctype [(c) & 0xFF] & _X)/* ** X/Open extensions*/ 9# if defined(_XOPEN_SOURCE) || !defined(_ANSI_C_SOURCE)# define _ctype_ __ctype int isascii (int);0# define isascii(c) ((unsigned)(c) <= 0x7F)%# define toascii(c) ((c) & 0x7F)I# define _toupper(c) (((c) >= 'a' && (c) <= 'z') ? (c) & 0xDF : (c))I# define _tolower(c) (((c) >= 'A' && (c) <= 'Z') ? (c) | 0x20 : (c)) # endif#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __CTYPE_PROCESSED */>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_CTYPE_NAMES# define __USING_CTYPE_NAMES using std::isalnum; using std::isalpha; using std::iscntrl; using std::isdigit; using std::isgraph; using std::islower; using std::isprint; using std::ispunct; using std::isspace; using std::isupper; using std::isxdigit; using std::tolower; using std::toupper;# endif#endif#endif /* __CTYPE_LOADED */ww%'ԗ#ifndef __CURSES_LOADED#define __CURSES_LOADED 1M/******************************************************************************3** - Curses screen management functions**M******************************************************************************* Header is nonstandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I**  I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*+** Using __VMS_CURSES implies _VMS_CURSES */2#if defined(__VMS_CURSES) && !defined(_VMS_CURSES)# define _VMS_CURSES 1#endif/*/** Using __BSD44_CURSES implies _BSD44_CURSES */6#if defined(__BSD44_CURSES) && !defined(_BSD44_CURSES)# define _BSD44_CURSES 1#endif/*** Default to _VMS_CURSES*/4#if !defined(_BSD44_CURSES) && !defined(_VMS_CURSES)# define _VMS_CURSES 1#endif/*E** BSD Curses is only available on OpenVMS Alpha as of OpenVMS V7.0.**E** While this may appear to be an incompatible change, the number ofL** problems discovered in the BSD Curses package shipped as part of the DECL** C RTL in versions of OpenVMS prior to V7.0 has led us to conclude that aE** correct program could not be built using it. We have changed theI** default to be _VMS_CURSES for those applications which are targettingD** systems prior to OpenVMS V7.0 and also utilize curses functions.***/,#if defined(_BSD44_CURSES) && defined(__VAX)D# error " BSD 4.4 Curses package not yet available on OpenVMS VAX"#endif5#if defined(_BSD44_CURSES) && (__CRTL_VER < 70000000)N# error " BSD 4.4 Curses package not available on OpenVMS Alpha before V7.0"#endif/*G** Disable the following messages prior to including the header files.*/#pragma __message __save-#pragma __message __disable (__MISALGNDSTRCT)+#pragma __message __disable (__MISALGNDMEM)(#pragma __message __disable (__MACROEXT)/*M** Perform includes necessary for each of the curses packages. This is doneJ** here because we do not want to use any #pragmas prior to the includes.*/#ifdef _VMS_CURSES # include # include 5# if !(__DECC_MODE_COMMON) && !(__DECC_MODE_STRICT)# include # endif#else# include # include # include #endif/*A** All structures should be member aligned on natural boundaries*/!#pragma __member_alignment __save#pragma __member_alignment/*<** Definitions common to both _VMS_CURSES and _BSD44_CURSES*/*#define ERR (0) /* Error return */*#define OK (1) /* Success return */ #ifndef TRUE# define TRUE (1)#endif #ifndef FALSE# define FALSE (0)#endif/*I** Define macros which give the user the correct dereferencing of global&** variables defined in the DEC C RTL*/ #ifndef __VAX$# define LINES decc$ga_LINES## define COLS decc$ga_COLS%# define stdscr decc$ga_stdscr%# define curscr decc$ga_curscr#else'# define LINES (*decc$ga_LINES)&# define COLS (*decc$ga_COLS)(# define stdscr (*decc$ga_stdscr)(# define curscr (*decc$ga_curscr)#endif#ifdef _VMS_CURSES# ifndef __VAX$# define stdkb decc$ga_stdkb$# define stdpb decc$ga_stdpb# else'# define stdkb (*decc$ga_stdkb)'# define stdpb (*decc$ga_stdpb) # endif#endif #ifdef _VMS_CURSES </**********************************************************/</* Header file for _VMS_CURSES (VAX and Alpha) */</**********************************************************//*** */#define reg register/*** */#define _SUBWIN 0001#define _ENDLINE 0002#define _FULLWIN 0004#define _SCROLLWIN 0010#define _FLUSH 0020#define _STANDOUT 0200/*=** Values used in lower byte of the _win_st _flags structure*//#define _BLINK 4 /* SMG$M_BLINK *//#define _BOLD 1 /* SMG$M_BOLD  *//#define _REVERSE 2 /* SMG$M_REVERSE *//#define _UNDERLINE 8 /* SMG$M_UNDERLINE *//*;** Values used in the _flags field in the _kb_st structure*/#define _NOECHO 001#define _NONL 002#define _NOCRMODE 004#define _NORAW 010/*$** Buffer size used by SMG routines*/#define SMG_BUFSIZ 512/*** Define a _win_st structure*/!#pragma __member_alignment __save##pragma __nomember_alignment __wordstruct _win_st { int _cur_y, _cur_x; int _max_y, _max_x; int _beg_y, _beg_x; /*D ** Low byte of _flags contains rendition and the upper byte are; ** values such as _ENDLINE, _SCROLLWIN etc (see above) */ short _flags;* char _clear, _leave, _scroll, _wrap; char **_y; short *_firstch, *_lastch;- struct _win_st *_next, *_parent, *_child; int _id;};$#pragma __member_alignment __restore/*** Define a _kb_st structure*/struct _kb_st { /*3 ** Identifier of the keyboard. Passed to SMG. */ int _id; /*' ** Flags can be raw, break etc...  */ unsigned char _flags;  /* ** Descriptor use for input */ struct { unsigned short length; unsigned char type;# ifdef __cplusplus! unsigned char _class; # else unsigned char class; # endif char *address; } _buffer_desc; /*? ** The number of bytes read in but not yet returned to the@ ** application. An example of this is using RAW mode whereA ** several characters are read in on a single getch, but theB ** application must call getch several times to get each one. */ int _count; /*G ** Pointer to next byte to return to user. This may or may not beE ** equal to the address field in the above descriptor when input ** is buffered. */ char *_ptr;};/*** Define a _pb_st structure*/2#if !(__DECC_MODE_COMMON) && !(__DECC_MODE_STRICT) struct _pb_st { int _id; int _rows, _cols; union smgdef *_attr; int _attr_size; };#endif!#define _KEYBOARD struct _kb_st"#define WINDOW struct _win_st!#define _PASTEBOARD struct _pb_st/* ** Curses external declarations*/#pragma __extern_model __save&#pragma __extern_model __strict_refdef<extern WINDOW * curscr; /* Current scr een */<extern WINDOW * stdscr; /* Standard screen */<extern int COLS; /* Columns on the screen */<extern int LINES; /* Lines on the screen */<extern _KEYBOARD * stdkb; /* Standard keyboard */<extern _PASTEBOARD * stdpb; /* Standard pasteboard */ #pragma __extern_model __restore/*L** The following non-stdscr functions are defined as macros which use the w@** form of the functions, passing stdscr as the first arg ument.*/2#define addch(ch) waddch (stdscr,ch)2#define addstr(s) waddstr (stdscr,s)/#define clear() wclear (stdscr)3#define clrattr(a) wclrattr (stdscr,a)2#define clrtobot() wclrtobot (stdscr)2#define clrtoeol() wclrtoeol (stdscr)/#define delch() wdelch (stdscr)2#define deleteln() wdeleteln (stdscr)/#define erase() werase (stdscr)/#define getch() wgetch (stdscr)2#define getstr(s) wgetstr (stdscr,s).#define inch() winch (stdscr)1#define insch(c) winsch (stdscr,c)2#define insertln() winsertln (stdscr)2#define insstr(s) winsstr (stdscr,s)2#define move(y,x) wmove (stdscr,y,x)1#define refresh() wrefresh (stdscr)3#define setattr(a) wsetattr (stdscr,a)2#define standout() wstandout (stdscr)2#define standend() wstandend (stdscr) 8#define mvaddch(y,x,ch) mvwaddch (stdscr,y,x,ch)5#define mvgetch(y,x) mvwgetch (stdscr,y,x):#define mvaddstr(y,x,str) mvwaddstr (stdscr,y,x,str):#define mvinsstr(y,x,str) mvwinsstr (stdscr,y,x,str):#define mvgetstr(y,x,str) mvwgetstr (stdscr,y,x,str)4#define mvinch(y,x) mvwinch (stdscr,y,x)5#define mvdelch(y,x) mvwdelch (stdscr,y,x)8#define mvinsch(y,x,ch) mvwinsch (stdscr,y,x,ch)8#define mvdeleteln(y,x) mvwdeleteln (stdscr,y,x)4#define mvcur(ly,lx,ny,nx) wmove (stdscr,ny,nx)L#define mvwaddch(win,y,x,ch) (wmove(win,y,x)==ERR ? ERR : waddch(win,ch))I#define mvwgetch(win,y,x) (wmove(win,y,x)==ERR ? ERR : wgetch(win))N#define mvwinsstr(win,y,x,str) (wmove(win,y,x)==ERR ? ERR : winsstr(win,str))N#define mvwgetstr(win,y,x,str) (wmove(win,y,x)==ERR ? ERR : wgetstr(win,str))H#define mvwinch(win,y,x) (wmove(win,y,x)==ERR ? ERR : winch(win))I#define mvw delch(win,y,x) (wmove(win,y,x)==ERR ? ERR : wdelch(win))L#define mvwinsch(win,y,x,ch) (wmove(win,y,x)==ERR ? ERR : winsch(win,ch))L#define mvwdeleteln(win,y,x) (wmove(win,y,x)==ERR ? ERR : wdeleteln(win))2#define clearok(win,bf) (win->_clear = bf)2#define leaveok(win,bf) (win->_leave = bf)3#define scrollok(win,bf) (win->_scroll = bf)1#define wrapok(win,bf) (win->_wrap = bf)W#define flushok(win,bf) (bf ? win->_flags |= _FLUSH : (win->_flags &= ~_FLUSH))@#define getyx(win,y,x) y = win->_cur_y, x = win->_cur_x/*** Terminal input mode macros*//#define echo() (stdkb->_flags &= ~_NOECHO)/#define noecho() (stdkb->_flags |= _NOECHO).#define raw() (stdkb->_flags &= ~_NORAW).#define noraw() (stdkb->_flags |= _NORAW)-#define nl() (stdkb->_flags &= ~_NONL)-#define nonl() (stdkb->_flags |= _NONL);#define crmode() ((stdkb->_flags &= ~_NOCRMODE), nonl())2#define nocrmode() (stdkb->_flags |= _NOCRMODE)/*I** Create 'private' typedefs that are sensitive to pointer size and mustG** use short pointers. These typedefs are used when refering to these)** types when in 64 bit pointer context.*/$ typedef WINDOW * __WINDOW_ptr32;/*H** We are done defining things which must always be short pointers. IfH** the user has used /pointer_size=short or /pointer_size=long, we will5** allow long pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64$ typedef WINDOW * __WINDOW_ptr64;#endif/*E** The DEC C RTL always allocates WINDOW structure in 32 bit memory.*/__WINDOW_ptr32 initscr (void);U__WINDOW_ptr32 newwin (int __numlines, int __numcols, int __begin_y, int __begin_x);d__WINDOW_ptr32 subwin (WINDOW *__win, int __numlines, int __numcols, int __begin_y, int __begin_x);/*N** The following functions have two interfaces, one for 32 and one for 64 bit ** pointers.*/ #if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32#endif1 char *longname (char *termbuf, char *__name);#if __INITIAL_POINTER_SIZE# pragma __pointer_size 324 char *_longname32 (char *termbuf, char *__name);# pragma __pointer_size 644 char *_longname64 (char *termbuf, char *__name);#endif/*** Function prototypes*/=int box (WINDOW *__win, char __vert, char __hor);$int delwin (WINDOW *__win);int endwin (void); Jint mvwaddstr (WINDOW *__win, int __vert, int __horz, char *__str );@int mvwin (WINDOW *__win, int __st_row, int __st_col);5int overlay (WINDOW *__win1, WINDOW *__win2);5int overwrite (WINDOW *__win1, WINDOW *__win2);/int printw (char *__format_spec, ...);/int scanw (char *__format_spec, ...);$int scroll (WINDOW *__win);$int touchwin (WINDOW *__win);/int waddch (WINDOW *__win, char __ch);1int waddstr (WIN DOW *__win, char *__str);$int wclear (WINDOW *__win);0int wclrattr (WINDOW *__win, int __attr);$int wclrtobot (WINDOW *__win);$int wclrtoeol (WINDOW *__win);$int wdelch (WINDOW *__win);$int wdeleteln (WINDOW *__win);$int werase (WINDOW *__win);$int wgetch (WINDOW *__win);1int wgetstr (WINDOW *__win, char *__str);$char winch (WINDOW *__win);/int winsch (WINDOW *__win, char __ch);$int winsertln (WINDOW *__win);Iint winsstr (WINDOW *, const char *); /* OpenVMS extension */6int wmove (WINDOW *__win, int __y, int __x);>int wprintw (WINDOW *__win, char *__format_spec, ...);$int wrefresh (WINDOW *__win);>int wscanw (WINDOW *__win, char *__format_spec, ...);0int wsetattr (WINDOW *__win, int __attr);$int wstandend (WINDOW *__win);$int wstandout (WINDOW *__win);#endif /* _VMS_CURSES */ #ifdef _BSD44_CURSES</***** *****************************************************/</* Header file for _BSD44_CURSES (Alpha Only) */</**********************************************************/</* */</* Documentation on the 4.4BSD curses package can be */</* found in: */</* */</* "Screen Updating and Cursor Movement */</* Optimization: A Library Package" */</* */</* by Kenneth C.R.C. Arnold */</* */</**********************************************************//*8** Pointers to termcap fields used by BSD curses package*/#define AE decc$ga_bsd_ae#define AL decc$ga_bsd_al #define al decc$ga_bsd_al2#define AS decc$ga_bsd_as#define AM decc$ga_bsd_am #define BC decc$ga_bsd_bc #define BS decc$ga_bsd_bs #define BT decc$ga_bsd_bt #define CA decc$ga_bsd_ca #define CD decc$ga_bsd_cd #define CE decc$ga_bsd_ce #define CL decc$ga_bsd_cl #define CM decc$ga_bsd_cm #define CR decc$ga_bsd_cr #define CS decc$ga_bsd_cs #define DA decc$ga_bsd_da #define DB decc$ga_bsd_db #define DC decc$ga_bsd_dc #define DL decc$ga_bsd_dl #define dl decc$ga_bsd_dl2#define DM decc$ga_bsd_dm #define DO decc$ga_bsd_do #define ED decc$ga_bsd_ed #define EI decc$ga_bsd_ei #define EO decc$ga_bsd_eo #define GT decc$ga_bsd_gt #define HC decc$ga_bsd_hc #define HO decc$ga_bsd_ho #define HZ decc$ga_bsd_hz #define IC decc$ga_bsd_ic #define IM decc$ga_bsd_im #define IN decc$ga_bsd_in #define IP decc$ga_bsd_ip #define K0 decc$ga_bsd_k0 #define K1 decc$ga_bsd_k1 #define K2 decc$ga_bsd_k2 #define  K3 decc$ga_bsd_k3 #define K4 decc$ga_bsd_k4 #define K5 decc$ga_bsd_k5 #define K6 decc$ga_bsd_k6 #define K7 decc$ga_bsd_k7 #define K8 decc$ga_bsd_k8 #define K9 decc$ga_bsd_k9 #define KD decc$ga_bsd_kd #define KE decc$ga_bsd_ke #define KH decc$ga_bsd_kh #define KL decc$ga_bsd_kl #define KR decc$ga_bsd_kr #define KS decc$ga_bsd_ks #define KU decc$ga_bsd_ku #define LL decc$ga_bsd_ll #define MA decc$ga_bsd_ma #define MB decc$ga_bsd_mb #define MD decc$ga_bsd_md#define ME decc$ga_bsd_me#define MI decc$ga_bsd_mi #define MR decc$ga_bsd_mr#define MS decc$ga_bsd_ms #define NC decc$ga_bsd_nc #define ND decc$ga_bsd_nd #define NL decc$ga_bsd_nl #define NS decc$ga_bsd_ns #define OS decc$ga_bsd_os #define PC decc$ga_bsd_pc #define RC decc$ga_bsd_rc #define SC decc$ga_bsd_sc #define SE decc$ga_bsd_se #define SF decc$ga_bsd_sf #define sf decc$ga_bsd_sf2#define SO decc$ga_bsd_so #define SR decc$ga_bsd_sr #define sr decc$ga_bsd_sr2#define TA decc$ga_bsd_ta #define TE decc$ga_bsd_te #define TI decc$ga_bsd_ti #define UC decc$ga_bsd_uc #define UE decc$ga_bsd_ue #define UL decc$ga_bsd_ul #define UP decc$ga_bsd_up #define US decc$ga_bsd_us #define VB decc$ga_bsd_vb #define VE decc$ga_bsd_ve #define VS decc$ga_bsd_vs #define XB decc$ga_bsd_xb #define XN decc$ga_bsd_xn #define XS decc$ga_bsd_xs #define XT decc$ga_bsd_xt #define XX decc$ga_bsd_xx /*.** Possible params to specific termcap fields*/*#define AL_PARM decc$ga_bsd_al_parm *#define DL_PARM decc$ga_bsd_dl_parm ,#define DOWN_PARM decc$ga_bsd_down_parm ,#define LEFT_PARM decc$ga_bsd_left_parm -#define RIGHT_PARM decc$ga_bsd_right_parm *#define UP_PARM decc$ga_bsd_up_parm /*** BSD boolean fields*/,#define UPPERCASE decc$ga_bsd_uppercase '#define NONL decc$ga_bsd_nonl +#define Def_term decc$ga_bsd_def_term )#define My_term decc$ga_bsd_my_term)#define __unctrl decc$ga_bsd__unctrl,#define __unctrllen decc$ga_bsd__unctrllen)#define ttytype decc$ga_bsd_ttytype/*A** The following #defines and #includes are present for backward@** compatibility only. They should not be used in future code.**&** START BACKWARD COMPATIBILITY ONLY.*/#ifndef _CURSES_PRIVATE# define bool char# define reg register# define _BSD_VA_LIST_ ...*# define _puts(s) tputs(s,0,__cputchar)%# define _putchar(c) __cputchar(c)# define crmode() cbreak()!# define nocrmode() nocbreak()3# if !defined __U_INT && !defined _DECC_V4_SOURCE# define __U_INT typedef __u_int u_int; # endif#endif>extern char GT; /* Gtty indicates tabs */>extern char NONL; /* Term can't hack LF doing a CR */>extern char UPPERCASE; /* Terminal is uppercase only */>extern int My_term; /* Use Def_term regardless */>extern char *Def_term; /* Default terminal type *//*** Termcap capabilities*/Fextern char AM,BS,CA,DA,EO,HC,IN,MI,MS,NC,NS,OS,PC,UL,XB,XN,XT,XS,XX;Pextern char *AE,*AL,*AS,*BC,*BT,*CD,*CE,*CL,*CM,*CR,*CS,*DC,*DL,*DM,*DO,*ED,*EI,P *K0,*K1,*K2,*K3,*K4,*K5,*K6,*K7,*K8,*K9,*HO,*IC,*IM,*IP,*KD,*KE,*KH,P *KL,*KR,*KS,*KU,*LL,*MA,*MB,*MD,*ME,*MR,*ND,*NL,*RC,*SC,*SE,*SF,*SO,H *SR,*TA,*TE,*TI,*UC,*UE,*UP,*US,*VB,*VS,*VE,*al,*dl,*sf,*sr,I *AL_PARM,*DL_PARM,*UP_PARM,*DOWN_PARM,*LEFT_PARM,*RIGHT_PARM;&/* END BACKWARD COMPATIBILITY ONLY. *//*** 8-bit ASCII characters*/+#define unctrl(c) __unctrl[(c) & 0xff]/#define unctrllen(ch) __unctrllen[(ch) & 0xff]>extern char *__unctrl[256]; /* Control strings */>extern char __unctrllen[256]; /* Control strings length */ /*G** A window is an array of __LINE structures pointed to by the 'lines'D** pointer. A line is an array of __LDATA structures pointed to by** the 'line' pointer.**D** IMPORTANT: the __LDATA structure must NOT induce any padding,soD** if new fields are added -- padding fields with *constant values*F** should ensure that the compiler will not generate any padding when>** storing an array of __LDATA structures. This is to enableA** consistent use of memcmp,and memcpy for comparing and copying ** arrays.*/typedef struct {. char ch; /* the actual character */. char attr; /* attributes of character */ } __LDATA;%#define __LDATASIZE (sizeof(__LDATA))H#define A_STANDOUT 0x01 /* For wattron,wattroff,wattrset */#define A_UNDERLINE 0x02#define A_REVERSE 0x04#define A_BLINK 0x08#define A_BOLD 0x10H#define A_DIM A_BOLD /* dim not avaiable, make it bold */H#define A_ALTCHARSET 0x20 /* Use alternate character set */#define A_NORMAL 0x00H#define __STANDOUT A_STANDOUT /* Added characters are standout. */typedef struct {J __size_t *firstchp, *lastchp; /* First and last chngd columns ptrs */J __LDATA *line; /* Pointer to the line text. */J __size_t firstch, lastch; /* First and last changed columns. */ __u_int flags;J __u_int hash; /* Hash value for the line. */ } __LINE;H#define __ISDIRTY 0x01 /* Line is dirty. */H#define __ISPASTEOL 0x02 /* Cursor is past end of line */H#define __FORCEPAINT 0x04 /* Force a repaint of the line *//* G** Although fields within the window structure should never be changedG** by application code, some of the fields are useful for applications** to have read access to.**C** BSD 4.4 code removed the "_" from structure member names so forG** upward compatability, defines of the names including the underscore** have been made.*/typedef struct __window {I struct __window *nextp; /* Subwindows list and parent */I struct __window *orig; /* */I __LINE **lines; /* Array of pointers to the lines */I __LINE *lspace; /* line space (for cleanup) */I __LDATA *wspace; /* window space (for cleanup) */I __size_t begy, begx; /* Window home */I __size_t cury, curx; /* Current y, x coordinates */I __size_t maxy, maxx; /* Maximum values for cury, curx */ __u_int flags;I __u_int w_nodelay; /* non-blocking used with nodelay routine */I short ch_off; /* x offset for firstch/lastch. */I char attrs; /* character attributes for new char */I /* See __LDATA section for valid values */ } WINDOW;/****/#define _begy begy#define _begx begx#define _cury cury#define _curx curx#define _maxy maxy#define _maxx maxx#define _flags flags#define _attrs attrs/* ** Curses external declarations*/<extern WINDOW * curscr; /* Current screen */<extern WINDOW * stdscr; /* Standard screen */<extern int COLS; /* Columns o n the screen */<extern int LINES; /* Lines on the screen */<extern char * ttytype; /* Full name of terminal *//****/D#define __ENDLINE 0x001 /* End of screen */D#define __FLUSH 0x002 /* Fflush(stdout) after refresh */D#define __FULLLINE 0x004 /* Line width = terminal width */D#define __FULLWIN 0x008 /* Window is a screen */D#define __IDLINE 0x010 /* Insert/delete sequences */ D#define __SCROLLWIN 0x020 /* Last char will scroll window */D#define __SCROLLOK 0x040 /* Scrolling ok */D#define __CLEAROK 0x080 /* Clear on next refresh */D#define __WSTANDOUT 0x100 /* Standout (attributes) window */E#define __LEAVEOK 0x200 /* If curser left */ /*$** Standard screen pseudo functions**D** Original BSD 4.4 sources with a check for decc$$scr_is_tty added**L** The following non-stdscr functions are defined as macros which use the w@** form of the functions, passing stdscr as the first argument.*/!extern unsigned decc$$scr_is_tty;x#define addbytes(s,n) (!decc$$scr_is_tty ? ERR : __waddbytes(stdscr,s,n,(stdscr->attrs == A_NORMAL) ? 0 : 1))N#define addch(ch) (!decc$$scr_is_tty ? ERR : waddch(stdscr,ch))Q#define addnstr(s,n) (!decc$$scr_is_tty ? ERR : waddnstr(stdscr,s,n))#define addstr(s) (!decc$$scr_is_tty ? ERR : __waddbytes(stdscr,s,strlen(s),(stdscr->attrs == A_NORMAL) ? 0 : 1))O#define attron(at) (!decc$$scr_is_tty ? ERR : wattron(stdscr,at))P#define attroff(at) (!decc$$scr_is_tty ? ERR : wattroff(stdscr,at))P#define attrset(at) (!decc$$scr_is_tty ? ERR : wattrset(stdscr,at))K#define clear() (!decc$$scr_is_tty ? ERR : wclear(stdscr))P#define clrattr(at) (!decc$$scr_is_tty ? ERR : wclrattr(stdscr,at))N#define clrtobot()  (!decc$$scr_is_tty ? ERR : wclrtobot(stdscr))N#define clrtoeol() (!decc$$scr_is_tty ? ERR : wclrtoeol(stdscr))K#define delch() (!decc$$scr_is_tty ? ERR : wdelch(stdscr))N#define deleteln() (!decc$$scr_is_tty ? ERR : wdeleteln(stdscr))K#define erase() (!decc$$scr_is_tty ? ERR : werase(stdscr))/#define getch() wgetch(stdscr)2#define getstr(s) wgetstr(stdscr,s)J#define inch() (!decc$ $scr_is_tty ? ERR : winch(stdscr))N#define insch(ch) (!decc$$scr_is_tty ? ERR : winsch(stdscr,ch))/*!** Digital only extension to BSD*/O#define insstr(s) (!decc$$scr_is_tty ? ERR : winsstr (stdscr,s))N#define insertln() (!decc$$scr_is_tty ? ERR : winsertln(stdscr))N#define move(y,x) (!decc$$scr_is_tty ? ERR : wmove(stdscr,y,x))M#define refresh() (!decc$$scr_is_tty ? ERR : wrefresh(stdscr))P#define setattr(at) (!decc$$scr_is_tty ? ERR : wsetattr(stdscr,at))N#define standend() (!decc$$scr_is_tty ? ERR : wstandend(stdscr))N#define standout() (!decc$$scr_is_tty ? ERR : wstandout(stdscr))n#define waddbytes(w,s,n) (!decc$$scr_is_tty ? ERR : __waddbytes(w,s,n,(w->attrs == A_NORMAL) ? 0 : 1))v#define waddstr(w,s) (!decc$$scr_is_tty ? ERR : __waddbytes(w,s,strlen(s),(w->attrs == A_NORMAL) ? 0 : 1))/*2** Standard screen plus movement pseudo functions*/X#define mvaddbytes(y,x,s,n) (!decc$$scr_is_tty ? ERR : mvwaddbytes(stdscr,y,x,s,n))T#define mvaddch(y,x,ch) (!decc$$scr_is_tty ? ERR : mvwaddch(stdscr,y,x,ch))W#define mvaddnstr(y,x,s,n) (!decc$$scr_is_tty ? ERR : mvwaddnstr(stdscr,y,x,s,n))T#define mvaddstr(y,x,s) (!decc$$scr_is_tty ? ERR : mvwaddstr(stdscr,y,x,s))Q#define mvdelch(y,x) (!decc$$scr_is_tty ? ERR : mvwdelch(stdscr,y,x))Q#define mvgetch(y,x) (!decc$$scr_is_tty ? ERR : mvwgetch(stdscr,y,x))T#define mvgetstr(y,x,s) (!decc$$scr_is_tty ? ERR : mvwgetstr(stdscr,y,x,s))P#define mvinch(y,x) (!decc$$scr_is_tty ? ERR : mvwinch(stdscr,y,x))S#define mvinsch(y,x,c) (!decc$$scr_is_tty ? ERR : mvwinsch(stdscr,y,x,c))/*!** Digital only extension to BSD*/U#define mvinsstr(y,x,s) (!decc$$scr_is_tty ? ERR : mvwinsstr (stdscr,y,x,s))p#define mvwaddbytes(w,y,x,s,n) (wmove(w,y,x) == ERR ? ERR : __waddbytes(w,s,n,(w->attrs == A_NORMAL) ? 0 : 1))K#define mvwaddch(w,y,x,ch) (wmove(w,y,x) == ERR ? ERR : waddch(w,ch))N#define mvwaddnstr(w,y,x,s,n) (wmove(w,y,x) == ERR ? ERR : waddnstr(w,s,n))x#define mvwaddstr(w,y,x,s) (wmove(w,y,x) == ERR ? ERR : __waddbytes(w,s,strlen(s),(w->attrs == A_NORMAL) ? 0 : 1))H#define mvwdelch(w,y,x) (wmove(w,y,x) == ERR ? ERR : wdelch(w))H#define mvwgetch(w,y,x) (wmove(w,y,x) == ERR ? ERR : wgetch(w))K#define mvwgetstr(w,y,x,s) (wmove(w,y,x) == ERR ? ERR : wgetstr(w,s))G#define mvwinch(w,y,x) (wmove(w,y,x) == ERR ? ERR : winch(w))J#define mvwinsch(w,y,x,c) (wmove(w,y,x) == ERR ? ERR : winsch(w,c))/*!** Digital only extension to BSD*/I#define mvwinsstr(w,y,x,s) (wmove(w,y,x)==ERR ? ERR : winsstr(w,s))/*** Psuedo functions*/`#define clearok(w,bf) ((bf) ? ((w)->flags |= __CLEAROK) : ((w)->flags &= ~__CLEAROK))\#define flushok(w,bf) ((bf) ? ((w)->flags |= __FLUSH) : ((w)->fla gs &= ~__FLUSH))@#define getyx(w,y,x) (y) = (w)->cury,(x) = (w)->curx`#define leaveok(w,bf) ((bf) ? ((w)->flags |= __LEAVEOK) : ((w)->flags &= ~__LEAVEOK))b#define scrollok(w,bf) ((bf) ? ((w)->flags |= __SCROLLOK) : ((w)->flags &= ~__SCROLLOK))S#define winch(w) ((w)->lines[(w)->cury]->line[(w)->curx].ch & 0177)/*I** Create 'private' typedefs that are sensitive to pointer size and mustG** use short pointers. These typedefs are used when refering to these)** types when in 64 bit pointer context.*/$ typedef WINDOW * __WINDOW_ptr32;/*F** Switch back to 32-bit pointer size to define those functions which%** are resticted to 32-bit pointers.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 32#endif/*?** The callback routines for tputs is always a 32 bit address.*/'typedef void (*__tputs_callback) (int);/*3** Define macros for mapping to decc$ entry points*/3#define fullname(p1,p2) decc$bsd_fullname(p1,p2).#define getcap(p1) decc$bsd_getcap(p1)3#define longname(p1,p2) decc$bsd_longname(p1,p2)2#define tgetstr(p1,p2) decc$bsd_tgetstr(p1,p2)/*F** The following functions are restricted to 32 bit pointers. If youH** have a need to use the 64 bit interface, the names of the proceduresB** to call are function prototyped in the 64 bit section and have+** names of the form decc$_bsd_fullname64.*/!char *fullname (char *, char *);char *getcap  (char *);!char *longname (char *, char *);(char *tgetstr (__char_ptr64, char **);/*H** We are done defining things which must always be short pointers. IfH** the user has used /pointer_size=short or /pointer_size=long, we will5** allow long pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*K** Define the 64 bit specific interfaces for those users needing access toI** them. There is no "transparent" way to access these. Compiling withE** the /pointer_size=64 qualifier does not automatically call these.*/#if __INITIAL_POINTER_SIZE$ typedef WINDOW * __WINDOW_ptr64;2 char *decc$_bsd_fullname64 (char *, char *);* char *decc$_bsd_getcap64 (char *);2 char *decc$_bsd_longname64 (char *, char *);3 char *decc$_bsd_tgetstr64 (char *, char **);#endif/*3** Define macros for mapping to decc$ entry points*/5#define __cputchar decc$bsd__cputcharC#d efine __waddbytes(p1,p2,p3,p4) decc$bsd__waddbytes(p1,p2,p3,p4)8#define baudrate(p1) decc$bsd_baudrate(p1)9#define box(p1,p2,p3) decc$bsd_box(p1,p2,p3)7#define cbreak(_p1) decc$bsd_cbreak(_p1)6#define delwin(p1) decc$bsd_delwin(p1)5#define echo(_p1) decc$bsd_echo(_p1)2#define endwin decc$bsd_endwin:#define erasechar(_p1) decc$bsd_erasechar(_p1)9#define gettmode(_p1) dec c$bsd_gettmode(_p1)8#define idlok(p1,p2) decc$bsd_idlok(p1,p2)8#define initscr(_p1) decc$bsd_initscr(_p1)9#define killchar(_p1) decc$bsd_killchar(_p1);#define mvwin(p1,p2,p3) decc$bsd_mvwin(p1,p2,p3)3#define nl(_p1) decc$bsd_nl(_p1)9#define nocbreak(_p1) decc$bsd_nocbreak(_p1):#define nodelay(p1,p2) decc$bsd_nodelay(p1,p2)7#define noecho(_p1) decc$bsd_noecho(_p1)5#define nonl( _p1) decc$bsd_nonl(_p1)6#define noraw(_p1) decc$bsd_noraw(_p1):#define overlay(p1,p2) decc$bsd_overlay(p1,p2)<#define overwrite(p1,p2) decc$bsd_overwrite(p1,p2)4#define raw(_p1) decc$bsd_raw(_p1)8#define resetty(_p1) decc$bsd_resetty(_p1)8#define savetty(_p1) decc$bsd_savetty(_p1)6#define scroll(p1) decc$bsd_scroll(p1)7#define setterm(p1) decc$bsd_setterm(p1):#d efine tgetent(p1,p2) decc$bsd_tgetent(p1,p2)8#define tgetflag(p1) decc$bsd_tgetflag(p1)7#define tgetnum(p1) decc$bsd_tgetnum(p1);#define tgoto(p1,p2,p3) decc$bsd_tgoto(p1,p2,p3)8#define touchwin(p1) decc$bsd_touchwin(p1);#define tputs(p1,p2,p3) decc$bsd_tputs(p1,p2,p3)9#define waddch(p1,p2) decc$bsd_waddch(p1,p2);#define wattroff(p1,p2) decc$bsd_wattroff(p1,p2):#define wattron(p1,p2) decc$bsd_wattron(p1,p2);#define wattrset(p1,p2) decc$bsd_wattrset(p1,p2)6#define wclear(p1) decc$bsd_wclear(p1);#define wclrattr(p1,p2) decc$bsd_wclrattr(p1,p2)9#define wclrtobot(p1) decc$bsd_wclrtobot(p1)9#define wclrtoeol(p1) decc$bsd_wclrtoeol(p1)6#define wdelch(p1) decc$bsd_wdelch(p1)9#define wdeleteln(p1) decc$bsd_wdeleteln(p1)6#define werase(p1) decc$bsd_werase(p1)6#d efine wgetch(p1) decc$bsd_wgetch(p1):#define wgetstr(p1,p2) decc$bsd_wgetstr(p1,p2)9#define winsch(p1,p2) decc$bsd_winsch(p1,p2)9#define winsertln(p1) decc$bsd_winsertln(p1):#define winsstr(p1,p2) decc$bsd_winsstr(p1,p2);#define wmove(p1,p2,p3) decc$bsd_wmove(p1,p2,p3)8#define wrefresh(p1) decc$bsd_wrefresh(p1);#define wsetattr(p1,p2) decc$bsd_wsetattr(p1,p2)9#define wstandend(p1) decc$bsd_wstandend(p1)9#define wstandout(p1) decc$bsd_wstandout(p1)>#define mvcur(p1,p2,p3,p4) decc$bsd_mvcur(p1,p2,p3,p4)?#define newwin(p1,p2,p3,p4) decc$bsd_newwin(p1,p2,p3,p4)B#define subwin(p1,p2,p3,p4,p5) decc$bsd_subwin(p1,p2,p3,p4,p5)B#define touchline(p1,p2,p3,p4) decc$bsd_touchline(p1,p2,p3,p4)?#define touchoverlap(p1,p2) decc$bsd_touchoverlap(p1,p2)>#define waddnstr(p1,p2,p3) decc$bsd_waddnstr(p1,p2,p3)/*M** Define macros for mapping to decc$ entry points (floating point specific)*/ #if __X_FLOAT&# if __G_FLOAT /* g-float */*# define printw decc$gxbsd_printw)# define scanw decc$gxbsd_scanw+# define wprintw decc$gxbsd_wprintw*# define wscanw decc$gxbsd_wscanw,# define mvprintw decc$gxbsd_mvprintw-# define mvwprintw decc$gxbsd_mvwprintw,# define mvscanw decc$gxbsd_mvscanw ,# define mvwscanw decc$gxbsd_mvwscanw)# elif __I EEE_FLOAT /* ieee-float */*# define printw decc$txbsd_printw)# define scanw decc$txbsd_scanw+# define wprintw decc$txbsd_wprintw*# define wscanw decc$txbsd_wscanw,# define mvprintw decc$txbsd_mvprintw-# define mvwprintw decc$txbsd_mvwprintw,# define mvscanw decc$txbsd_mvscanw ,# define mvwscanw decc$txbsd_mvwscanw&# else /* d-float */*# define printw decc$dxbsd_printw)# define scanw decc$dxbsd_scanw+# define wprintw decc$dxbsd_wprintw*# define wscanw decc$dxbsd_wscanw,# define mvprintw decc$dxbsd_mvprintw-# define mvwprintw decc$dxbsd_mvwprintw,# define mvscanw decc$dxbsd_mvscanw ,# define mvwscanw decc$dxbsd_mvwscanw # endif#else&# if __G_FLOAT /* g-float */(# define printw decc$bsd_printw'# define scanw decc$bsd_scanw)# define wprintw decc$bsd_wprintw(# define wscanw decc$bsd_wscanw*# define mvprintw decc$bsd_mvprintw+# define mvwprintw decc$bsd_mvwprintw*# define mvscanw decc$bsd_mvscanw *# define mvwscanw decc$bsd_mvwscanw)# elif __IEEE_FLOAT /* ieee-float */)# define printw decc$tbsd_printw(# define scanw decc$tbsd_scanw*# define wprintw decc$tbsd_wprintw)# define wscanw decc$tbsd_wscanw+# define mvprintw decc$tbsd_mvprintw,# define mvwprintw decc$tbsd_mvwprintw+ # define mvscanw decc$tbsd_mvscanw +# define mvwscanw decc$tbsd_mvwscanw&# else /* d-float */)# define printw decc$dbsd_printw(# define scanw decc$dbsd_scanw*# define wprintw decc$dbsd_wprintw)# define wscanw decc$dbsd_wscanw+# define mvprintw decc$dbsd_mvprintw,# define mvwprintw decc$dbsd_mvwprintw+# define mvscanw decc$dbsd_mvscanw +# define mvwscanw decc$dbsd_mvwscanw # endif#endif/*** Public function prototypes*/void __cputchar (int);:int __waddbytes (WINDOW *, const char *, int, int);/*E** The DEC C RTL always allocates WINDOW structure in 32 bit memory.*/__WINDOW_ptr32 initscr (void);,__WINDOW_ptr32 newwin (int, int, int, int);6__WINDOW_ptr32 subwin (WINDOW *, int, int, int, int);/*J** The return values of these functions are pointers to character strings:** allocated by the CRTL and are always 32 bit addresses.*/"__char_ptr32 wstandend (WINDOW *);"__char_ptr32 wstandout (WINDOW *);*__char_ptr32 tgoto (char *, int, int);/*** Public function prototypes*/int baudrate (void);,int box (WINDOW *, int, int);int cbreak (void);"int delwin (WINDOW *);int erasechar (void);int echo (void);int endwin (void);int gettmode (void);'void idlok (WINDOW *, int);int killchar (void); ,int mvcur (int, int, int, int);5int mvprintw (int, int, const char *, ...);5int mvscanw (int, int, const char *, ...);,int mvwin (WINDOW *, int, int);?int mvwprintw (WINDOW *, int, int, const char *, ...);?int mvwscanw (WINDOW *, int, int, const char *, ...);int nl (void);int nocbreak (void);Lint nodelay (WINDOW *, const int); /* OpenVMS extension */int noecho (void);int nonl (void);int noraw (void);,int overlay (WINDOW *, WINDOW *);,int overwrite (WINDOW *, WINDOW *);+int printw (const char *, ...);int raw (void);int resetty (void);int savetty (void);+int scanw (const char *, ...);"int scroll (WINDOW *); int setterm (char *);1int touchline (WINDOW *, int, int, int);,int touchoverlap (WINDOW *, WINDOW *);"int touchwin (WINDOW *);'int waddch (WINDOW *, int);5int waddnstr (WINDOW *, const char *, int);"int wclear (WINDOW *);"int wclrtobot (WINDOW *);"int wclrtoeol (WINDOW *);"int wdelch (WINDOW *);"int wdeleteln (WINDOW *);"int werase (WINDOW *);"int wgetch (WINDOW *);*int wgetstr (WINDOW *, char *);'int winsch (WINDOW *, int);Lint winsstr  (WINDOW *, const char *); /* OpenVMS extension */"int winsertln (WINDOW *);,int wmove (WINDOW *, int, int);5int wprintw (WINDOW *, const char *, ...);"int wrefresh (WINDOW *);5int wscanw (WINDOW *, const char *, ...);'int wclrattr (WINDOW *, int);'int wsetattr (WINDOW *, int);'int wattron (WINDOW *, int);'int wattroff (WINDOW *, int);'int wattrset (WINDOW *, int); /*** Termcap functions*/(int tgetent (char *, char *); int tgetnum (char *); int tgetflag (char *);7void tputs (char *, int, __tputs_callback);/*J** The following routines, savetty and resetty are left in only as stubs.*/int resetty();int savetty();#endif /* _BSD44_CURSES */ /*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __message __restore$#pragma __member_alignment __restore#pragma __standard#endif /* __CURSES_LOADED */ww W(ԗ#ifndef __C_ASM_LOADED#define __C_ASM_LOADED 1#pragma __nostandardK#if !defined(__VAX) && ((!defined(__DECCXX)) || (__DECCXX_VER >= 50300000))M/******************************************************************************6** - Prototypes for asm intrinsic functions**M******************************************************************************* Header is nonstandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying.  I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I**  M******************************************************************************/#include #ifdef __cplusplus extern "C" {#endif##if defined(__INITIAL_POINTER_SIZE))# pragma __required_pointer_size __save%# pragma __required_pointer_size 32#endif/*:** DEC C supports in-line assembly code, commonly called** ASMs on UNIX platforms.**F** Like builtin-functions, ASMs are implemented with a f unction-callI** syntax. But unlike built-in functions, to use ASMs you must includeI** this header file containing prototypes for the three types?** of ASMs, and the #pragma intrinsic preprocessor directive:**A** __int64 asm(const char*, ...); // integer return, e.g. MULQJ** float fasm(const char*, ...); // single precision return, e.g. MULSJ** double dasm(const char*, ...); // double precision return, e.g. MULT(** #pragma intrinsic (asm, fasm, dasm)**** Parameters:**G** The first argument to the asm, fasm, or dasm function containsJ** the instruction(s) to be generated inline, using the metalanguageG** (see below) that describes the interpretation of the arguments)** and the instructions themselves.**G** Subsequent arguments provide the source and destination valuesK** (if any) for the instruction being generated, and any other valuesM** used in the generated instructions. These values are m ade availableK** to the instructions via the normal argument passing conventions ofK** the calling standard (e.g. the first integer argument is available** in register R16).**** Return value:**E** The choice of which function you call determines the type ofE** the function value if the function is used in an expression.E** But it is up to the user-written instructions to ensure thatB** the intended value of that type is placed in the regi sterD** mandated by the calling standard for that type in order for<** the value to be made available to the calling code.**H** Note that the #pragma intrinsic directive is required. It notifiesF** the compiler that these functions are not user-defined functions,@** and that special processing should be applied to analyze at>** compile-time the first argument and generate machine-code=** instructions as specified by the contents of the string.**I** The metalanguage for the argument references has the following form:**/** : 0** | /** | **)** : "$" number**3** : "%" **%** : number.** | 6** | "f" number | "F" number6** | "r" number | "R" number**=** : // argument registers: R16-R21F** "a0" | "a1" | "a2" | "a3" | "a4" | "a5"**K** // return value: R0 or F0, depending on type#** | "v0"**E** // scratch registers: R1, R22-R24, R28?** | "t0" | "t1" | "t2" | "t3" | "t4"**8** // save registers: R2-R15M** | "s0" | "s1" | "s2" | "s3" | "s4" | "s5" | "s6"G** | "s7" | "s8" | "s7" | "s8" | "s9" | "s10"4** | "s11" | "s12" | "s13"**4** // stack pointer: R30:** | "sp" | "SP" | "$sp" | "$SP"**K** | "RA" | "ra" // return addr: R26K** | "PV" | "pv" // procedure value: R27K** | "AI" | "ai" // arg info: R25K** | "FP" | "fp" // frame pointer: R29L** | "RZ" | "rz" | "zero" // sink/source: R31 == 0**?** Syntactically, the metalanguage can appear anywhere within** an instruction sequence.**A** The literal string that contains instructions, operands, and/** metalanguage must follow the general form:**2** : H** | ";" &** | error8** | error**4** : instruction_operand*** | directive****B** An instruction_operand is generally recognized as an assemblyD** language instruction separated by whitespace from a sequence of** comma-separated operands.**A** You can code multiple instruction sequences into one literalA** string, separatin g them by semicolons. Since the C languageA** concatentates adjacent string literals into a single string,?** successive instructions can be written as separate stringsC** one-per-line as is normally done in assembly language, as longE** as each instruction is terminated by a semicolon as shown in the** examples.**>** There are semantic and syntax rules associated with ASMs:**A** o The first argument to an ASM call is interpreted as theD** instructions to be assembled in the metalanguage, and must>** be fully understood by the compiler at compile time.F** Therefore, it must be a literal string (or a macro expandingK** to a literal string) and not a runtime value containing a string.J** Thus the following are not allowed: indirections, table lookups,-** structure de-references, and so on.**>** o The remaining arguments are loaded into the argument?** registers like normal function arguments, except thatE** the SECOND argument to the ASM call is treated as the FIRST8** argument for purposes of the calling standard.**C** For example, in the following test, the six arguments areD** loaded into arg registers a0 through a5, and the result ofC** each subexpression is stored in the value return registerG** v0. Since v0 is the calling-standard's return value registerC** (R0 for an integer function) the result of the final mulq.** is the value returned by the "call":**,** if (asm("mulq %a0, %a1, %v0;",** "mulq %a2, %v0, %v0;",** "mulq %a3, %v0, %v0;",** "mulq %a4, %v0, %v0;"H** "mulq %a5, %v0, %v0;", 1, 2, 3, 4, 5, 6) != 720){** error_cnt++;+** printf ("Test failed\n");** }**A** o A return register must be specified in the metalanguage9** for the result to appear in the expected place.**A** The following example does not work. There is no valueF** loaded into the floating-point return register. Furthermore,F** it results in a compile-time warning stating that r2 is usedE** before it is set, because the arguments are loaded into the(** arg registers and not into r2:**5** z = fasm("mulq %r2, %a1 %r5", x=10, y=5);**2** A correct version of the above would be:***** z = fasm("mulq %a0, %a 1, %a1;"(** "stq %a1, 0(%a2);"(** "ldt %f0, 0(%a2);":** "cvtqf %f0, %f0;", x=10, y=5, &temp);**=** Note that the memory location used for the transfer=** from integer to floating register is made available?** to the asm code by passing as an argument the addressA** of a variable allocated in the C code for that purpose.**>** o For intructions that do not take any argument and do>** not have a return type, leave out the arguments. For** example:**** asm("mb");*//*** Function prototypes**?** Note that there is no support for 64 bit character pointers*/ __int64 asm (const char *,...);!double dasm (const char *, ...); float fasm (const char*, ...);#pragma intrinsic(asm)#pragma intrinsic(dasm)#pragma intrinsic(fasm)/*%** Restore the users pointer context*/##if defined(__INITIAL_POINTER_SIZE),# pragma __required_pointer_size __restore#endif#ifdef __cplusplus }#endif*#endif /* !defined(__VAX) && !_DECCXX */#pragma __standard#endif /* __C_ASM_LOADED */wwW(ԗ#ifndef ____DECC_TYPES_LOADED/*J** Note, that for decc$types.h header we cannot use the name of the headerI** file with leading underscores as protecting macro, as we usually do inL** our public header files, because the file name contains dollar sign whichG** is not allowed in identifier in strict ANSI mode. T his is why we use;** ____DECC_TYPES_LOADED instead of ____DECC$TYPES_LOADED .*/#define ____DECC_TYPES_LOADEDM/******************************************************************************J** This header file is included by all header files. The purpose of thisG** header file is to include those things which are either done by allC** header files or introduce no name space violations by doing so.**M*****************************************************************************7** Header not defined by any specification or standardM*****************************************************************************I** I** Copyright 2008 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying.  I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I**  M******************************************************************************/#pragma __nostandard# if !defined(__VAX)0# define __preferred_base_alignment __quadword# else,# define __preferred_base_alignment __byte# endif /* ! __VAX *//*** Set up feature test macros*/=# if defined _XOPEN_SOURCE_EXTENDED && !defined _XOPEN_SOURCE# define _XOPEN_SOURCE# endif# if defined _XOPEN_SOURCE # if !defined _POSIX_C_SOURCE# define _POSIX_C_SOURCE 2 # endif# if _POSIX_C_SOURCE < 2# undef _POSIX_C_SOURCE# define _POSIX_C_SOURCE 2 # endif# endif# if defined _POSIX_SOURCE # if !defined _POSIX_C_SOURCE# define _POSIX_C_SOURCE 1 # endif# if _POSIX_C_SOURCE < 1N# undef _POSIX_C_SOURCE /* Use _POSIX_C_SOURCE with a value of 1 */N# define _POSIX_C_SOURCE 1 /* instead of _POSIX_SOURCE (obsolete) */ # endif# endif7# if defined _POSIX_C_SOURCE && !defined _ANSI_C_SOURCE# define _ANSI_C_SOURCE# endif ># if defined __HIDE_FORBIDDEN_NAMES && !defined _ANSI_C_SOURCE# define _ANSI_C_SOURCE# endif/*>** Define __CRTL_VER_OVERRIDE on the compiler command line to B** override the value of __CRTL_VER. Defining __CRTL_VER_OVERRIDE 8** without a value sets __CRTL_VER to the maximum value.*/ # if defined __CRTL_VER_OVERRIDE # if __CRTL_VER_OVERRIDE == 1# undef __CRTL_VER_OVERRIDE'# define __CRTL_VER_OVERRIDE 0x7fffffff # endif# if __CRTL_VER_OVERRIDE# if defined __CRTL_VER# undef __CRTL_VER # endif-# define __CRTL_VER __CRTL_VER_OVERRIDE # endif# endif/*=** Define __VMS_VER_OVERRIDE on the compiler command line to @** override the value of __VMS_VER. Defining __VMS_VER_OVERRIDE 7** without a value sets __VMS_VER to the maximum value.*/# ifdef __VMS_VER_OVERRIDE# if __VMS_VER_OVERRIDE == 1# undef __VMS_VER_OVERRIDE&# define __VMS_VER_OVERRIDE 0x7fffffff # endif# if __VMS_VER_OVERRIDE# ifndef __VMS_VER# undef __VMS_VER # endif+# define __VMS_VER __VMS_VER_OVERRIDE # endif# endif/*4** On development versions of OpenVMS the C compiler$** may not be able to set __VMS_VER.**2** Assume that this version is the highest version'** supported by the C Run-time library.*/# ifndef __VMS_VER # define __VMS_VER 0x7fffffff# endif/*K** If the compiler was not already given a definition for __CRTL_VER, then** define it now.*/# ifndef __CRTL_VERI# if !defined(__VAX) && (__VMS_VER > 70260300 && __VMS_VER < 70300000)# define __CRTL_VER 70301000 # else# define __CRTL_VER __VMS_VER # endif# endif/*4** __CRTL_VER was mistakenly set to 70300010 in some9** DECC$SHR images released for VMS 7.2-6C1. In this case** set __CRTL_VER to 70301000.***/# if __CRTL_VER == 70300010# undef __CRTL_VER# define __CRTL_VER 70301000# endif/*N** The DEC C RTL relies on the use of extern_prefix support in the compilers.N** The scenario of a customer getting these new headers via DEC C++, while atH** the same time using a compiler before DEC C V5.2 is still supported.*/# if defined(__DECC_VER)# if (__DECC_VER > 50230003)"# define __CAN_USE_EXTERN_PREFIX 1 # endif# else# if defined(__DECCXX)"# define __CAN_USE_EXTERN_PREFIX 1 # endif# endif/*=** Support for the  'restrict' type qualifier is defined here.=** Define __IOSC_RESTRICT and __XOPEN_RESTRICT appropriately.*/#if __STDC_VERSION__ >= 199901</* The compiler being used supports the restrict keyword. */7 /* Standard C APIs will use the restrict keyword. */"# define __ISOC_RESTRICT restrict<# if defined(_XOPEN_SOURCE) && ((_XOPEN_SOURCE + 0) >= 600)H /* XOPEN extensions to standard C will use the restrict keyword. */&# define __XOPEN_RESTRICT restrict# elseF /* Older  XOPEN extension APIs do not use the restrict keyword. */# define __XOPEN_RESTRICT# endif#elseF /* The compiler being used may not support the restrict keyword. */# define __ISOC_RESTRICT# define __XOPEN_RESTRICT#endif/*K** _USE_STD_STAT: The new standardized stat structure takes the place of B** all prior versions, if you compile with _USE_STD_STAT defined.*/#if defined(_USE_STD_STAT) /*; ** The _USE_STD_STAT feature is not implemented on VAX.  **/# if defined(__VAX)E# error "_USE_STD_STAT feature macro unsupported on VAX architecture" # endif /*C ** The _USE_STD_STAT feature requires extern prefixing support. */# if !__CAN_USE_EXTERN_PREFIXe# error "_USE_STD_STAT feature macro requires extern prefixing support, unavailable on this platform" # endif /*K ** The _USE_STD_STAT feature uses UTC time. Therefore we cannot compileQ ** this header with _VMS_V6_SOURCE enabled. _VMS_V6_SOURCE  implies localtime. */# if defined(_VMS_V6_SOURCE)G# error "Incompatible feature macros: _USE_STD_STAT and _VMS_V6_SOURCE" # endif /*8 ** The _USE_STD_STAT feature does not honor requests< ** for source-code compatibility with DEC C Version 4.0. */# if defined(_DECC_V4_SOURCE)H# error "Incompatible feature macros: _USE_STD_STAT and _DECC_V4_SOURCE" # endif /*3 ** _USE_STD_STAT implies 64-bit file offsets.  */# define __USE_OFF64_T 1  /*, ** _USE_STD_STAT implies 32-bit uid/gid.M ** Feature macro _DECC_SHORT_GID_T is inconsistent with __USE_LONG_GID_T,N ** but we don't flag it, as the former is overridden by the latter anyway. */# define __USE_LONG_GID_T 1 /*R ** _USE_STD_STAT provides standardized implementations of the following types,O ** which are used as the types of some stat (and dirent) structure members. */8 typedef unsigned __int64 __dev_t; /* device id */: typedef unsigned __int64 __ino_t; /* file ino */1 typedef __int64 blksize_t; /* block size */2 typedef __int64 blkcnt_t; /* block count */ /*D ** _USE_STD_STAT implies the potential for 64-bit time_t fields.0 ** We provide a macro for that support here.4 ** This macro is used in the stat.h header file.I ** It should be turned on here if 64-bit time support is implemented. */!# define __USING_64BIT_TIME_T 0 /*H ** Set the macro which controls further compilation of this feature. */# define __USING_STD_STAT 1#endif-typedef unsigned long fsblkcnt_t, fsfilcnt_t;/*>** In OpenVMS Alpha V7.2-6C1, support for POSIX-style GID/UIDB** was introduced with the intention to merge this functionality ?** into some future (currently unspecified) release of OpenVMS'** Alpha following OpenVMS Alpha V7.3.**C** POSIX-style GID requires 32-bit gid_t datatype. On a version ofB** OpenVMS Alpha which supports POSIX-style GID /UID, 32-bit gid_t=** becomes a default meaning, that unless _DECC_SHORT_GID_T,K** _VMS_V6_SOURCE or _DECC_V4_SOURCE macro is defined, __gid_t is declared3** as 'unsigned int' rather than 'unsigned short'.**G** Since the exact version of OpenVMS Alpha into which the support forH** POSIX-style GID/UID will be merged into has not been determined yet,F** we provide __COE_SYSTEM macro which allows to request 32-bit gid_tI** datatype on a version of VMS other than OpenVMS Alpha V7.2-6C1 . Note,J** that defining the __COE_SYSTEM macro on a system that does not supportD** POSIX-style GID/UID, can result in generating code which may not** execute correctly.**J** Note also, that 32-bit gid_t datatype requires a version of the Compaq0** C compiler that supports external prefixing.*/F/* The check for __COE_SYSTEM removed for OpenVMS V7.3-1 and beyond */# ifndef __USE_LONG_GID_T# if !defined(__VAX) && \? (__CRTL_VER >= 70301000) && __CAN_USE_EXTERN_PREFIX && \[ !defined(_DECC_SHORT_GID_T) && !defined(_VMS_V6_SOURCE) && !defined(_DECC_V4_SOURCE) # define __USE_LONG_GID_T 1# else # define __USE_LONG_GID_T 0 # endif# endif/*I** On some Alpha OpenVMS systems support for files larger than 2 gigabyteL** is available. This feature is enabled by specifying the MACRO _LARGEFILE.L** When enabled all file offsets are accepted and returned as 64-bit values.**H** This feature requires a version of the Compaq C compiler with support** for #pragma __extern_prefix.***/L# if !defined(__VAX) && __CAN_USE_EXTERN_PREFIX && !defined(_DECC_V4_SOURCE)# ifndef __USE_OFF64_T# if defined(_LARGEFILE)# define __USE_OFF64_T 1# else# define __USE_OFF64_T 0# endif # endif# else# undef __USE_OFF64_T# define __USE_OFF64_T 0# if defined(_LARGEFILE)J# error " Support for large files not available before OpenVMS Alpha V7.2" # endif# endif/*K** Support for cname headers is available starting with Version V7.1 of theF** hp C++ compiler. This support can be disabled by defining the macroK** __NONAMESPACE_STD either on CXX command line or in the source file prior,** to inclusion any of C or C++ header file.*/8#if (__DECCXX_VER >= 70100000) && !defined(__STD_CFRONT)!# if !defined __NONAMESPACE_STD# define __NAMESPACE_STD # endif#endif/*M** Define typedefs which are used throughout the header files. Pointer size0** is only allowed on OpenVMS Alpha after V7.0.*/#if __INITIAL_POINTER_SIZE0# if (__CRTL_VER < 70000000) || defined(__VAX)M# error " Pointer size usage not permitted before OpenVMS Alpha V7.0" # endif # pragma __pointer_size __save# pragma __pointer_size 32#endif/*F** In ANSI C++, a wchar_t is a builtin type and __WCHAR_T is defined.8** This is only defined in such compilers (> V6.0 C++).*/# ifdef __WCHAR_T# define __wchar_t wchar_t# else# typedef unsigned int __wchar_t;# endif typedef unsigned int __id_t;" typedef unsigned int __size_t;! typedef unsigned int __u_int;! typedef unsigned int __uid_t;& typedef unsigned int __useconds_t;#ifdef __SIGNED_INT_TIME_T /*! ** Unix comptability feature.D ** This can change behavior of programs relying on the sign bit. */ typedef int __time_t;#else' typedef unsigned long int __time_t;#endif% typedef unsigned short __gid16_t;% typedef unsigned int __gid32_t;# if __USE_LONG_GID_T typedef __gid32_t __gid_t;# else typedef __gid16_t __gid_t;# endif#if !__USING_STD_STAT # typedef unsigned short __ino_t;#endif% typedef unsigned short __ino16_t;% typedef unsigned int __ino32_t;#ifndef ____SIGSET_T# define ____SIGSET_T 1? typedef struct __sigset {unsigned int _set[2];} __sigset_t;#endif# ifndef __VAX' typedef unsigned __int64 __ino64_t;# endif typedef long int __key_t;$ typedef unsigned short __mode_t; typedef int __nlink_t;# if __USE_OFF64_T typedef __int64 __off_t;# else typedef int __off_t;# endif typedef int __off32_t;$ typedef unsigned int __uoff32_t;# ifndef __VAX typedef __int64 __off64_t;( typedef unsigned __int64 __uoff64_t;# endif typedef int __pid_t; typedef int __ssize_t; typedef char *__caddr_t;#if !__USING_STD_STAT  typedef char *__dev_t;#endif# typedef unsigned int __dev32_t;# ifndef __VAX' typedef unsigned __int64 __dev64_t;# endif typedef char *__va_list;' typedef unsigned int __in_addr_t;' typedef unsigned short __in_port_t;) typedef unsigned char __sa_family_t;$ typedef unsigned char __u_char;% typedef unsigned short __u_short;$ typedef unsigned long __u_long;& typedef __wchar_t * __wchar_ptr32;2 typedef const __wchar_t * __const_wchar_ptr32; typedef int __wint_t; typedef int __wctrans_t; typedef int __wctype_t; struct _iobuf;" typedef struct _iobuf *__FILE;" typedef __FILE * __FILE_ptr32; typedef char * __char_ptr32;, typedef const char * __const_char_ptr32; typedef void * __void_ptr32;, typedef const void * __const_void_ptr32;% typedef void ** __void_ptr_ptr32;3 typedef void * const * __void_ptr_const_ptr32;" typedef short * __short_ptr32;. typedef const short * __const_short_ptr32;4 typedef unsigned short * __unsigned_short_ptr32;@ typedef const unsigned short * __const_unsigned_short_ptr32;% typedef char ** __char_ptr_ptr32;3 typedef char * const * __char_ptr_const_ptr32;& typedef __u_char * __u_char_ptr32;2 typedef const __u_char * __const_u_char_ptr32;( typedef __u_short * __u_short_ptr32;4 typedef const __u_short * __const_u_short_ptr32;& typedef __u_long * __u_long_ptr32;2 typedef const __u_long * __const_u_long_ptr32;# ifndef __VAX$ typedef __int64 * __int64_ptr32;0 typedef const __int64 * __const_int64_ptr32;# endif# ifndef __NULL6# if defined(__DECCXX) && (__DECCXX_VER >= 60000000)# define __NULL 0# else!# define __NULL ((void *) 0) # endif # endif /*M** The ANSI standard defines EOF as a negative integral constant expression.*/# ifndef __EOF# define __EOF (-1) # endif #if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif typedef char * __char_ptr64;, typedef const char * __const_char_ptr64;% typedef char ** __char_ptr_ptr64;3 typedef char * const * __char_ptr_const_ptr64; typedef void * __void_ptr64;, typedef const void * __const_void_ptr64;% typedef void ** __void_ptr_ptr64;3 typedef void * const * __void_ptr_const_ptr64;& typedef __size_t * __size_t_ptr64;2 typedef const __size_t * __const_size_t_ptr64;& typedef __wchar_t * __wchar_ptr64;2 typedef const __wchar_t * __const_wchar_ptr64;& typedef __u_char * __u_char_ptr64;2 typedef const __u_char * __const_u_char_ptr64;( typedef __u_short * __u_short_ptr64;4 typedef const __u_short * __const_u_short_ptr64;& typedef __u_long * __u_long_ptr64;2 typedef const __u_long * __const_u_long_ptr64;) typedef unsigned int * __u_int_ptr64;#if __INITIAL_POINTER_SIZE&# pragma __pointer_size __restore#endif# pragma __standard## endif /* ____DECC_TYPES_LOADED */ww)ԗ#ifndef __DESCRIP_LOADED#d efine __DESCRIP_LOADED 1M/******************************************************************************1** - VMS Argument Descriptor Formats**M******************************************************************************* Header is nonstandardM*******************************************************************************M** Copyright Digital Equipment Corporation 1993, 1997. All rights reserved.**B** Restricted Rights: Use, duplication, or disclosure by the U. S.F** Government is subject to restrictions as set forth in subparagraphF** (c) (1) (ii) of DFARS 252.227-7013, or in FAR 52.227-19, or in FAR&** 52.227-14 Alt. III, as applicable.**A** This software is proprietary to and embodies the confidentialD** technology of Digital Equipment Corporation. Possession, use, orG** copying of this software and media is authorized only pursuant to aD** valid written license from Digital or an authorized sublicensor.**N****************************!***************************************************/#pragma __nostandard#ifdef __cplusplus extern "C" {#endif#ifdef __INITIAL_POINTER_SIZE(# pragma __required_pointer_size __save$# pragma __required_pointer_size 32#endif/*(** Default to member aligned structures*/!#pragma __member_alignment __save#pragma __member_alignment/*7 * 32-BIT DESCRIPTOR DEFINITIONS (64-bit forms follow) *//*] * Descriptor Prototype - each class of descriptor consists of" at least the following fields: */struct dsc$descriptor{g unsigned short dsc$w_length; /* specific to descriptor class; typically a 16-bit (unsigned) length */0 unsigned char dsc$b_dtype; /* data type code */7 unsigned char dsc$b_class; /* descriptor class code */B char *dsc$a_pointer; /* address of first byte of data element */};/* * Fixed-Length Descriptor: */struct dsc$descriptor_s{> unsigned short dsc$w_length; /* length of data item in bytes,3 or if #dsc$b_dtype is DSC$K_DTYPE_V, bits,E or if dsc$b_dtype is DSC$K_DTYPE_P, digits (4 bits each) */0 unsigned char dsc$b_dtype; /* data type code */G unsigned char dsc$b_class; /* descriptor class code = DSC$K_CLASS_S */B char *dsc$a_pointer; /* address of first byte of data storage */};/* * Dynamic String Descriptor: */struct dsc$descriptor_d{> unsigned short dsc$w_length; /* length of data item in bytes,3 or if dsc$b_dtype is DSC$K_DTYPE_V, bits,E $ or if dsc$b_dtype is DSC$K_DTYPE_P, digits (4 bits each) */0 unsigned char dsc$b_dtype; /* data type code */G unsigned char dsc$b_class; /* descriptor class code = DSC$K_CLASS_D */B char *dsc$a_pointer; /* address of first byte of data storage */};/* * Array Descriptor: */struct dsc$descriptor_a{E unsigned short dsc$w_length; /* length of an array element in bytes,3 or if dsc$b_dtype is DSC$K_DTYPE_V, bits,E or if dsc$b_dtype is DSC$K_DTYPE_P, digi%ts (4 bits each) */0 unsigned char dsc$b_dtype; /* data type code */G unsigned char dsc$b_class; /* descriptor class code = DSC$K_CLASS_A */I char *dsc$a_pointer; /* address of first actual byte of data storage */N char dsc$b_scale; /* signed power-of-two or -ten multiplier, as specified byI dsc$v_fl_binscale, to convert from internal to external form */b unsigned char dsc$b_digits; /* if nonzero, number of decimal digits in internal representation */#pragma __nomember_alignment& struct {/ unsigned : 3; /* reserved; must be zero */^ unsigned dsc$v_fl_binscale : 1; /* if set, dsc$b_scale is a power-of-two, otherwise, -ten */V unsigned dsc$v_fl_redim : 1; /* if set, indicates the array can be redimensioned */T unsigned dsc$v_fl_column : 1; /* if set, indicates column-major order (FORTRAN) */X unsigned dsc$v_fl_coeff : 1; /* if set, indicates the multipliers block is present */S unsigned dsc$v_fl_bounds : 1; /* if set, indicates the bounds block is present ' */' } dsc$b_aflags; /* array flag bits */#pragma __member_alignment6 unsigned char dsc$b_dimct; /* number of dimensions */= unsigned long dsc$l_arsize; /* total size of array in bytes,E or if dsc$b_dtype is DSC$K_DTYPE_P, digits (4 bits each) */ /*T * One or two optional blocks of information may follow contiguously at this point;U * the first block contains information about the dimension multipliers (if present,T * dsc$b_aflags.dsc$v_fl_coeff is set), the second block (contains information aboutS * the dimension bounds (if present, dsc$b_aflags.dsc$v_fl_bounds is set). If theT * bounds information is present, the multipliers information must also be present. *3 * The multipliers block has the following format:I * char *dsc$a_a0; Address of the element whose subscripts are all zero? * long dsc$l_m [DIMCT]; Addressing coefficients (multipliers) *. * The bounds block has the following format: * struct * { * long dsc$l_l; Lower bound) * long dsc$l_u; Upper bound * } dsc$bounds [DIMCT]; *: * (DIMCT represents the value contained in dsc$b_dimct.) */};/* * Procedure Descriptor: */struct dsc$descriptor_p{M unsigned short dsc$w_length; /* length associated with the function value */? unsigned char dsc$b_dtype; /* function value data type code */G unsigned char dsc$b_class; /* descriptor class code = DSC$K_CLASS_P */> int (*dsc$a_pointer)(); /* address of function entry mask */};/* * D *ecimal String Descriptor: */struct dsc$descriptor_sd{> unsigned short dsc$w_length; /* length of data item in bytes,3 or if dsc$b_dtype is DSC$K_DTYPE_V, bits,E or if dsc$b_dtype is DSC$K_DTYPE_P, digits (4 bits each) */0 unsigned char dsc$b_dtype; /* data type code */H unsigned char dsc$b_class; /* descriptor class code = DSC$K_CLASS_SD */B char *dsc$a_pointer; /* address of first byte of data storage */N char dsc$b_scale; /* signed power-of-two or -ten multiplie +r, as specified byI dsc$v_fl_binscale, to convert from internal to external form */b unsigned char dsc$b_digits; /* if nonzero, number of decimal digits in internal representation */#pragma __nomember_alignment struct {. unsigned : 3; /* reserved; must be zero */^ unsigned dsc$v_fl_binscale : 1; /* if set, dsc$b_scale is a power-of-two, otherwise, -ten */. unsigned : 4; /* reserved; must be zero */( } dsc$b_sflags; /* scalar flag bits */#pragma __member_alignment- uns,igned : 8; /* reserved; must be zero */};/*" * Noncontiguous Array Descriptor: */struct dsc$descriptor_nca{E unsigned short dsc$w_length; /* length of an array element in bytes,3 or if dsc$b_dtype is DSC$K_DTYPE_V, bits,E or if dsc$b_dtype is DSC$K_DTYPE_P, digits (4 bits each) */0 unsigned char dsc$b_dtype; /* data type code */I unsigned char dsc$b_class; /* descriptor class code = DSC$K_CLASS_NCA */I char *dsc$a_pointer; /* address of first actual by -te of data storage */N char dsc$b_scale; /* signed power-of-two or -ten multiplier, as specified byI dsc$v_fl_binscale, to convert from internal to external form */b unsigned char dsc$b_digits; /* if nonzero, number of decimal digits in internal representation */#pragma __nomember_alignment struct {/ unsigned : 3; /* reserved; must be zero */^ unsigned dsc$v_fl_binscale : 1; /* if set, dsc$b_scale is a power-of-two, otherwise, -ten */2 unsigned dsc$v_fl_redim : 1; /* m .ust be zero */0 unsigned : 3; /* reserved; must be zero */' } dsc$b_aflags; /* array flag bits */#pragma __member_alignment6 unsigned char dsc$b_dimct; /* number of dimensions */b unsigned long dsc$l_arsize; /* if elements are actually contiguous, total size of array in bytes,E or if dsc$b_dtype is DSC$K_DTYPE_P, digits (4 bits each) */ /*V * Two blocks of information must follow contiguously at this point; the first blockS * contains information about the difference be/tween the addresses of two adjacentS * elements in each dimension (the stride). The second block contains information * about the dimension bounds. */ * The strides block has the following format:J * char *dsc$a_a0; Address of the element whose subscripts are all zero* * unsigned long dsc$l_s [DIMCT]; Strides *. * The bounds block has the following format: * struct * { * long dsc$l_l; Lower bound * long dsc$l_u; Upper bound * } dsc$bounds [DIMCT]; 0*: * (DIMCT represents the value contained in dsc$b_dimct.) */};/*Z * The Varying String Descriptor and Varying String Array Descriptor are used with strings * of the following form: * * struct * {@ * unsigned short CURLEN; The current length of BODY in bytesE * char BODY [MAXSTRLEN]; A fixed-length area containing the string * }; *Y * where MAXSTRLEN is the value contained in the dsc$w_maxstrlen field in the descriptor. *//* * Varying String Descri1ptor: */struct dsc$descriptor_vs{f unsigned short dsc$w_maxstrlen; /* maximum length of the BODY field of the varying string in bytes */A unsigned char dsc$b_dtype; /* data type code = DSC$K_DTYPE_VT */H unsigned char dsc$b_class; /* descriptor class code = DSC$K_CLASS_VS */N char *dsc$a_pointer; /* address of the CURLEN field of the varying string */};/*# * Varying String Array Descriptor: */struct dsc$descriptor_vsa{d unsigned short dsc$w_maxstrlen; /* maximum length2 of the BODY field of an array element in bytes */A unsigned char dsc$b_dtype; /* data type code = DSC$K_DTYPE_VT */I unsigned char dsc$b_class; /* descriptor class code = DSC$K_CLASS_VSA */I char *dsc$a_pointer; /* address of first actual byte of data storage */N char dsc$b_scale; /* signed power-of-two or -ten multiplier, as specified byI dsc$v_fl_binscale, to convert from internal to external form */b unsigned char dsc$b_digits; /* if nonzero, number of decimal digits in intern 3al representation */#pragma __nomember_alignment struct {/ unsigned : 3; /* reserved; must be zero */^ unsigned dsc$v_fl_binscale : 1; /* if set, dsc$b_scale is a power-of-two, otherwise, -ten */2 unsigned dsc$v_fl_redim : 1; /* must be zero */0 unsigned : 3; /* reserved; must be zero */' } dsc$b_aflags; /* array flag bits */#pragma __member_alignment6 unsigned char dsc$b_dimct; /* number of dimensions */d unsigned long dsc$l_arsize; /* if elements are actually contiguou 4s, total size of array in bytes */ /*V * Two blocks of information must follow contiguously at this point; the first blockS * contains information about the difference between the addresses of two adjacentS * elements in each dimension (the stride). The second block contains information * about the dimension bounds. */ * The strides block has the following format:J * char *dsc$a_a0; Address of the element whose subscripts are all zero* * unsigned long dsc$l_s [DIMCT]; Str5ides *. * The bounds block has the following format: * struct * { * long dsc$l_l; Lower bound * long dsc$l_u; Upper bound * } dsc$bounds [DIMCT]; *: * (DIMCT represents the value contained in dsc$b_dimct.) */};/*# * Unaligned Bit String Descriptor: */struct dsc$descriptor_ubs{? unsigned short dsc$w_length; /* length of data item in bits */A unsigned char dsc$b_dtype; /* data type code = DSC$K_DTYPE_VU */I unsigned char dsc$b_class; /* descrip6tor class code = DSC$K_CLASS_UBS */@ char *dsc$a_base; /* address to which dsc$l_pos is relative */R long dsc$l_pos; /* bit position relative to dsc$a_base of first bit in string */};/*" * Unaligned Bit Array Descriptor: */struct dsc$descriptor_uba{? unsigned short dsc$w_length; /* length of data item in bits */A unsigned char dsc$b_dtype; /* data type code = DSC$K_DTYPE_VU */I unsigned char dsc$b_class; /* descriptor class code = DSC$K_CLASS_UBA */K char *dsc$a_base; /* 7 address to which effective bit offset is relative */1 char dsc$b_scale; /* reserved; must be zero */: unsigned char dsc$b_digits; /* reserved; must be zero */#pragma __nomember_alignment struct {/ unsigned : 3; /* reserved; must be zero */4 unsigned dsc$v_fl_binscale : 1; /* must be zero */2 unsigned dsc$v_fl_redim : 1; /* must be zero */0 unsigned : 3; /* reserved; must be zero */' } dsc$b_aflags; /* array flag bits */#pragma __member_alignment6 unsigned char dsc8$b_dimct; /* number of dimensions */> unsigned long dsc$l_arsize; /* total size of array in bits */ /*X * Three blocks of information must follow contiguously at this point; the first blockW * contains information about the difference between the bit addresses of two adjacentS * elements in each dimension (the stride). The second block contains informationR * about the dimension bounds. The third block is the relative bit position with? * respect to dsc$a_base of the first actual bi9t of the array. */ * The strides block has the following format:M * long dsc$l_v0; Bit offset of the element whose subscripts are all zero,# * with respect to dsc$a_base* * unsigned long dsc$l_s [DIMCT]; Strides *. * The bounds block has the following format: * struct * { * long dsc$l_l; Lower bound * long dsc$l_u; Upper bound * } dsc$bounds [DIMCT]; *, * The last block has the following format: * long dsc$l_pos; *: * (DIMCT represent:s the value contained in dsc$b_dimct.) */ };/*! * String with Bounds Descriptor: */struct dsc$descriptor_sb{= unsigned short dsc$w_length; /* length of string in bytes */@ unsigned char dsc$b_dtype; /* data type code = DSC$K_DTYPE_T */H unsigned char dsc$b_class; /* descriptor class code = DSC$K_CLASS_SB */B char *dsc$a_pointer; /* address of first byte of data storage */% long dsc$l_sb_l1; /* lower bound */% long dsc$l_sb_u1; /* upper bound */};/*/ * Unaligned ; Bit String with Bounds Descriptor: */struct dsc$descriptor_ubsb{? unsigned short dsc$w_length; /* length of data item in bits */A unsigned char dsc$b_dtype; /* data type code = DSC$K_DTYPE_VU */J unsigned char dsc$b_class; /* descriptor class code = DSC$K_CLASS_UBSB */@ char *dsc$a_base; /* address to which dsc$l_pos is relative */R long dsc$l_pos; /* bit position relative to dsc$a_base of first bit in string */' long dsc$l_ubsb_l1; /* lower bound */' long dsc$l_ubsb_u1; /* upp<er bound */};/* * Codes for dsc$b_dtype: *//* * Atomic data types: */*#define DSC$K_DTYPE_Z 0 /* unspecified */I#define DSC$K_DTYPE_BU 2 /* byte (unsigned); 8-bit unsigned quantity */J#define DSC$K_DTYPE_WU 3 /* word (unsigned); 16-bit unsigned quantity */N#define DSC$K_DTYPE_LU 4 /* longword (unsigned); 32-bit unsigned quantity */N#define DSC$K_DTYPE_QU 5 /* quadword (unsigned); 64-bit unsigned quantity */P#define DSC$K_DTYPE_OU 25 /* octaword (unsigned); 12=8-bit unsigned quantity */Z#define DSC$K_DTYPE_B 6 /* byte integer (signed); 8-bit signed 2's-complement integer */[#define DSC$K_DTYPE_W 7 /* word integer (signed); 16-bit signed 2's-complement integer */_#define DSC$K_DTYPE_L 8 /* longword integer (signed); 32-bit signed 2's-complement integer */_#define DSC$K_DTYPE_Q 9 /* quadword integer (signed); 64-bit signed 2's-complement integer */a#define DSC$K_DTYPE_O 26 /* octaword integer (signed); 128-bit signed 2's-complement integer *>/S#define DSC$K_DTYPE_F 10 /* F_floating; 32-bit single-precision floating point */S#define DSC$K_DTYPE_D 11 /* D_floating; 64-bit double-precision floating point */S#define DSC$K_DTYPE_G 27 /* G_floating; 64-bit double-precision floating point */W#define DSC$K_DTYPE_H 28 /* H_floating; 128-bit quadruple-precision floating point */3#define DSC$K_DTYPE_FC 12 /* F_floating complex */3#define DSC$K_DTYPE_DC 13 /* D_floating complex */3#define DSC$K_DTYPE_GC 29 /* G_floating compl ?ex */3#define DSC$K_DTYPE_HC 30 /* H_floating complex */>#define DSC$K_DTYPE_CIT 31 /* COBOL Intermediate Temporary *//* * String data types: */g#define DSC$K_DTYPE_T 14 /* character string; a single 8-bit character or a sequence of characters */^#define DSC$K_DTYPE_VT 37 /* varying character string; 16-bit count, followed by a string */9#define DSC$K_DTYPE_NU 15 /* numeric string, unsigned */C#define DSC$K_DTYPE_NL 16 /* numeric string, left separate sign */G#define DSC$K_ @DTYPE_NLO 17 /* numeric string, left overpunched sign */D#define DSC$K_DTYPE_NR 18 /* numeric string, right separate sign */H#define DSC$K_DTYPE_NRO 19 /* numeric string, right overpunched sign */;#define DSC$K_DTYPE_NZ 20 /* numeric string, zoned sign */5#define DSC$K_DTYPE_P 21 /* packed decimal string */1#define DSC$K_DTYPE_V 1 /* aligned bit string */5#define DSC$K_DTYPE_VU 34 /* unaligned bit string *//* * IEEE data types: */;#define DSC$K_DTYPE_FS 52 /* IEEE float ba Asic single S */G#define DSC$K_DTYPE_FT 53 /* IEEE float basic double T */C#define DSC$K_DTYPE_FSC 54 /* IEEE float basic single S complex */C#define DSC$K_DTYPE_FTC 55 /* IEEE float basic double T complex *//* * Miscellaneous data types: */9#define DSC$K_DTYPE_ZI 22 /* sequence of instructions */6#define DSC$K_DTYPE_ZEM 23 /* procedure entry mask */,#define DSC$K_DTYPE_DSC 24 /* descriptor */7#define DSC$K_DTYPE_BPV 32 /* bound procedure value */3#define DSC$K_BDTYPE_BLV 33 /* bound label value */8#define DSC$K_DTYPE_ADT 35 /* absolute date and time *//* * Reserved data type codes:( * codes 38-191 are reserved to DIGITAL;S * codes 160-191 are reserved to DIGITAL facilities for facility-specific purposes;J * codes 192-255 are reserved for DIGITAL's Computer Special Systems Group) * and for customers for their own use. *//* * Codes for dsc$b_class: */6#define DSC$K_CLASS_S 1 /* fixed-length descriptor */8#define DSC$K_CLASS_D C2 /* dynamic string descriptor */Q/* DSC$K_CLASS_V ** variable buffer descriptor; reserved for use by DIGITAL *//#define DSC$K_CLASS_A 4 /* array descriptor */3#define DSC$K_CLASS_P 5 /* procedure descriptor */E/* DSC$K_CLASS_PI ** procedure incarnation descriptor; obsolete */P/* DSC$K_CLASS_J ** label descriptor; reserved for use by the VMS Debugger */A/* DSC$K_CLASS_JI ** label incarnation descriptor; obsolete */9#define DSC$K_CLASS_SD 9 /* decimal string descriptor */@ D#define DSC$K_CLASS_NCA 10 /* noncontiguous array descriptor */:#define DSC$K_CLASS_VS 11 /* varying string descriptor */A#define DSC$K_CLASS_VSA 12 /* varying string array descriptor */A#define DSC$K_CLASS_UBS 13 /* unaligned bit string descriptor */@#define DSC$K_CLASS_UBA 14 /* unaligned bit array descriptor */>#define DSC$K_CLASS_SB 15 /* string with bounds descriptor */N#define DSC$K_CLASS_UBSB 16 /* unaligned bit string with bounds descriptor *//*# * Reserved descriptor class cEodes:( * codes 15-191 are reserved to DIGITAL;S * codes 160-191 are reserved to DIGITAL facilities for facility-specific purposes;J * codes 192-255 are reserved for DIGITAL's Computer Special Systems Group) * and for customers for their own use. *//*: * A simple macro to construct a 32-bit string descriptor: */z#define $DESCRIPTOR(name,string) struct dsc$descriptor_s name = { sizeof(string)-1, DSC$K_DTYPE_T, DSC$K_CLASS_S, string }/*! * 64-BIT DESCRIPTOR DEFINITIONS  */F#ifdef __INITIAL_POINTER_SIZE"#pragma __required_pointer_size 64/*d * 64-bit Descriptor Prototype - each class of descriptor consists of at least the following fields: */struct dsc64$descriptor{Q unsigned short dsc64$w_mbo; /* must-be-one field overlays 16-bit length field */2 unsigned char dsc64$b_dtype; /* data type code */9 unsigned char dsc64$b_class; /* descriptor class code */J long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointer */7 unsigned __int64 dsGc64$q_length; /* quadword length */E char *dsc64$pq_pointer; /* address of first byte of data storage */};/*" * 64-bit Fixed-Length Descriptor: */struct dsc64$descriptor_s{Q unsigned short dsc64$w_mbo; /* must-be-one field overlays 16-bit length field */2 unsigned char dsc64$b_dtype; /* data type code */K unsigned char dsc64$b_class; /* descriptor class code = DSC64$K_CLASS_S */J long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointer */B unsigned __int64 dsc6H4$q_length; /* length of data item in bytes,7 or if dsc64$b_dtype is DSC64$K_DTYPE_V, bits,I or if dsc64$b_dtype is DSC64$K_DTYPE_P, digits (4 bits each) */E char *dsc64$pq_pointer; /* address of first byte of data storage */};/*$ * 64-bit Dynamic String Descriptor: */struct dsc64$descriptor_d{Q unsigned short dsc64$w_mbo; /* must-be-one field overlays 16-bit length field */2 unsigned char dsc64$b_dtype; /* data type code */K unsigned char dsc64$b_class; I/* descriptor class code = DSC64$K_CLASS_D */J long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointer */B unsigned __int64 dsc64$q_length; /* length of data item in bytes,7 or if dsc64$b_dtype is DSC64$K_DTYPE_V, bits,I or if dsc64$b_dtype is DSC64$K_DTYPE_P, digits (4 bits each) */E char *dsc64$pq_pointer; /* address of first byte of data storage */};/* * 64-bit Array Descriptor: */struct dsc64$descriptor_a{Q unsigned short dsc64$w_mbJo; /* must-be-one field overlays 16-bit length field */2 unsigned char dsc64$b_dtype; /* data type code */K unsigned char dsc64$b_class; /* descriptor class code = DSC64$K_CLASS_A */J long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointer */I unsigned __int64 dsc64$q_length; /* length of an array element in bytes,7 or if dsc64$b_dtype is DSC64$K_DTYPE_V, bits,I or if dsc64$b_dtype is DSC64$K_DTYPE_P, digits (4 bits each) */E char *dsc64$pq_pointer; /* add Kress of first byte of data storage */P char dsc64$b_scale; /* signed power-of-two or -ten multiplier, as specified byK dsc64$v_fl_binscale, to convert from internal to external form */d unsigned char dsc64$b_digits; /* if nonzero, number of decimal digits in internal representation */#pragma __nomember_alignment struct {1 unsigned : 3; /* reserved; must be zero */b unsigned dsc64$v_fl_binscale : 1; /* if set, dsc64$b_scale is a power-of-two, otherwise, -ten */X unsignLed dsc64$v_fl_redim : 1; /* if set, indicates the array can be redimensioned */X unsigned dsc64$v_fl_column : 1; /* if set, indicates column-major order (FORTRAN) */\ unsigned dsc64$v_fl_coeff : 1; /* if set, indicates the multipliers block is present */W unsigned dsc64$v_fl_bounds : 1; /* if set, indicates the bounds block is present */) } dsc64$b_aflags; /* array flag bits */#pragma __member_alignment8 unsigned char dsc64$b_dimct; /* number of dimensions */F unsigned long dsc64M$l_mbz; /* MBZ field to preserve quad alignment */B unsigned __int64 dsc64$q_arsize; /* total size of array in bytes,I or if dsc64$b_dtype is DSC64$K_DTYPE_P, digits (4 bits each) */ /*T * One or two optional blocks of information may follow contiguously at this point;U * the first block contains information about the dimension multipliers (if present,X * dsc64$b_aflags.dsc64$v_fl_coeff is set), the second block contains information aboutW * the dimension bounds (if present, ds Nc64$b_aflags.dsc64$v_fl_bounds is set). If theT * bounds information is present, the multipliers information must also be present. *3 * The multipliers block has the following format:S * char *dsc64$pq_a0; (quad) Address of the element whose subscripts are all zeroD * __int64 dsc64$q_m [DIMCT]; Addressing coefficients (multipliers) *. * The bounds block has the following format: * struct * {# * __int64 dsc64$q_l; Lower bound# * __int64 dsc64$q_u; Upper bound * O} dsc64$bounds [DIMCT]; *< * (DIMCT represents the value contained in dsc64$b_dimct.) */};/* * 64-bit Procedure Descriptor: */struct dsc64$descriptor_p{Q unsigned short dsc64$w_mbo; /* must-be-one field overlays 16-bit length field */A unsigned char dsc64$b_dtype; /* function value data type code */K unsigned char dsc64$b_class; /* descriptor class code = DSC64$K_CLASS_P */J long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointer */Q unsigned __int64 Pdsc64$q_length; /* length associated with the function value */A int (*dsc64$pq_pointer)(); /* address of function entry mask */};/*$ * 64-bit Decimal String Descriptor: */struct dsc64$descriptor_sd{Q unsigned short dsc64$w_mbo; /* must-be-one field overlays 16-bit length field */2 unsigned char dsc64$b_dtype; /* data type code */L unsigned char dsc64$b_class; /* descriptor class code = DSC64$K_CLASS_SD */J long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointeQr */B unsigned __int64 dsc64$q_length; /* length of data item in bytes,7 or if dsc64$b_dtype is DSC64$K_DTYPE_V, bits,I or if dsc64$b_dtype is DSC64$K_DTYPE_P, digits (4 bits each) */E char *dsc64$pq_pointer; /* address of first byte of data storage */P char dsc64$b_scale; /* signed power-of-two or -ten multiplier, as specified byK dsc64$v_fl_binscale, to convert from internal to external form */d unsigned char dsc64$b_digits; /* if nonzero, number of decimal diRgits in internal representation */#pragma __nomember_alignment struct {. unsigned : 3; /* reserved; must be zero */b unsigned dsc64$v_fl_binscale : 1; /* if set, dsc64$b_scale is a power-of-two, otherwise, -ten */. unsigned : 4; /* reserved; must be zero */* } dsc64$b_sflags; /* scalar flag bits */#pragma __member_alignment- unsigned : 8; /* reserved; must be zero */F unsigned long dsc64$l_mbz; /* MBZ field to preserve quad alignment */};/*) * 64-bit Noncontiguous Ar Sray Descriptor: */struct dsc64$descriptor_nca{Q unsigned short dsc64$w_mbo; /* must-be-one field overlays 16-bit length field */2 unsigned char dsc64$b_dtype; /* data type code */M unsigned char dsc64$b_class; /* descriptor class code = DSC64$K_CLASS_NCA */J long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointer */I unsigned __int64 dsc64$q_length; /* length of an array element in bytes,7 or if dsc64$b_dtype is DSC64$K_DTYPE_V, bits,I or if dsc64$ Tb_dtype is DSC64$K_DTYPE_P, digits (4 bits each) */E char *dsc64$pq_pointer; /* address of first byte of data storage */P char dsc64$b_scale; /* signed power-of-two or -ten multiplier, as specified byK dsc64$v_fl_binscale, to convert from internal to external form */d unsigned char dsc64$b_digits; /* if nonzero, number of decimal digits in internal representation */#pragma __nomember_alignment struct {/ unsigned : 3; /* reserved; must be zero */b unsigned dsc64$v_fl_bi Unscale : 1; /* if set, dsc64$b_scale is a power-of-two, otherwise, -ten */3 unsigned dsc64$v_fl_redim : 1; /* must be zero */0 unsigned : 3; /* reserved; must be zero */) } dsc64$b_aflags; /* array flag bits */#pragma __member_alignment8 unsigned char dsc64$b_dimct; /* number of dimensions */F unsigned long dsc64$l_mbz; /* MBZ field to preserve quad alignment */g unsigned __int64 dsc64$q_arsize; /* if elements are actually contiguous, total size of array in bytes,I or if ds Vc64$b_dtype is DSC64$K_DTYPE_P, digits (4 bits each) */ /*V * Two blocks of information must follow contiguously at this point; the first blockS * contains information about the difference between the addresses of two adjacentS * elements in each dimension (the stride). The second block contains information * about the dimension bounds. */ * The strides block has the following format:T * char *dsc64$pq_a0; (quad) Address of the element whose subscripts are all zero' * __Wint64 dsc64$q_s [DIMCT]; Strides *. * The bounds block has the following format: * struct * {$ * __int64 dsc64$q_l; Lower bound$ * __int64 dsc64$q_u; Upper bound * } dsc64$bounds [DIMCT]; *< * (DIMCT represents the value contained in dsc64$b_dimct.) */};/*Z * The Varying String Descriptor and Varying String Array Descriptor are used with strings * of the following form: * * struct * {@ * unsigned short CURLEN; The current length of BODY in bXytesE * char BODY [MAXSTRLEN]; A fixed-length area containing the string * }; *[ * where MAXSTRLEN is the value contained in the dsc64$w_maxstrlen field in the descriptor. *//*$ * 64-bit Varying String Descriptor: */struct dsc64$descriptor_vs{Q unsigned short dsc64$w_mbo; /* must-be-one field overlays 16-bit length field */E unsigned char dsc64$b_dtype; /* data type code = DSC64$K_DTYPE_VT */L unsigned char dsc64$b_class; /* descriptor class code = DSC64$K_CLASS_VS */ YJ long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointer */j unsigned __int64 dsc64$q_maxstrlen; /* maximum length of the BODY field of the varying string in bytes */Q char *dsc64$pq_pointer; /* address of the CURLEN field of the varying string */};/** * 64-bit Varying String Array Descriptor: */struct dsc64$descriptor_vsa{Q unsigned short dsc64$w_mbo; /* must-be-one field overlays 16-bit length field */E unsigned char dsc64$b_dtype; /* data type code = DSC64$K_ZDTYPE_VT */M unsigned char dsc64$b_class; /* descriptor class code = DSC64$K_CLASS_VSA */J long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointer */j unsigned __int64 dsc64$q_maxstrlen; /* maximum length of the BODY field of the varying string in bytes */L char *dsc64$pq_pointer; /* address of first actual byte of data storage */P char dsc64$b_scale; /* signed power-of-two or -ten multiplier, as specified byK dsc64$v_fl_binscale, to convert from internal to external [form */d unsigned char dsc64$b_digits; /* if nonzero, number of decimal digits in internal representation */#pragma __nomember_alignment struct {/ unsigned : 3; /* reserved; must be zero */b unsigned dsc64$v_fl_binscale : 1; /* if set, dsc64$b_scale is a power-of-two, otherwise, -ten */3 unsigned dsc64$v_fl_redim : 1; /* must be zero */0 unsigned : 3; /* reserved; must be zero */) } dsc64$b_aflags; /* array flag bits */#pragma __member_alignment8 unsigned char dsc64$b_d\imct; /* number of dimensions */F unsigned long dsc64$l_mbz; /* MBZ field to preserve quad alignment */i unsigned __int64 dsc64$q_arsize; /* if elements are actually contiguous, total size of array in bytes */ /*V * Two blocks of information must follow contiguously at this point; the first blockS * contains information about the difference between the addresses of two adjacentS * elements in each dimension (the stride). The second block contains information * about the dimension bo]unds. */ * The strides block has the following format:T * char *dsc64$pq_a0; (quad) Address of the element whose subscripts are all zero' * __int64 dsc64$q_s [DIMCT]; Strides *. * The bounds block has the following format: * struct * {$ * __int64 dsc64$q_l; Lower bound$ * __int64 dsc64$q_u; Upper bound * } dsc64$bounds [DIMCT]; *< * (DIMCT represents the value contained in dsc64$b_dimct.) */};/** * 64-bit Unaligned Bit String Descriptor: */ ^struct dsc64$descriptor_ubs{Q unsigned short dsc64$w_mbo; /* must-be-one field overlays 16-bit length field */E unsigned char dsc64$b_dtype; /* data type code = DSC64$K_DTYPE_VU */M unsigned char dsc64$b_class; /* descriptor class code = DSC64$K_CLASS_UBS */J long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointer */D unsigned __int64 dsc64$q_length; /* length of data item in bits */E char *dsc64$pq_base; /* address to which dsc64$l_pos is relative */Y __int64 dsc64$q__pos; /* bit position relative to dsc64$a_base of first bit in string */};/*) * 64-bit Unaligned Bit Array Descriptor: */struct dsc64$descriptor_uba{Q unsigned short dsc64$w_mbo; /* must-be-one field overlays 16-bit length field */E unsigned char dsc64$b_dtype; /* data type code = DSC64$K_DTYPE_VU */M unsigned char dsc64$b_class; /* descriptor class code = DSC64$K_CLASS_UBA */J long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointer */D unsigned __int64 dsc64$ `q_length; /* length of data item in bits */N char *dsc64$pq_base; /* address to which effective bit offset is relative */3 char dsc64$b_scale; /* reserved; must be zero */< unsigned char dsc64$b_digits; /* reserved; must be zero */#pragma __nomember_alignment struct {/ unsigned : 3; /* reserved; must be zero */6 unsigned dsc64$v_fl_binscale : 1; /* must be zero */3 unsigned dsc64$v_fl_redim : 1; /* must be zero */0 unsigned : 3; /* reserved; must be zero */) } dsc64$ ab_aflags; /* array flag bits */#pragma __member_alignment8 unsigned char dsc64$b_dimct; /* number of dimensions */F unsigned long dsc64$l_mbz; /* MBZ field to preserve quad alignment */C unsigned __int64 dsc64$q_arsize; /* total size of array in bits */ /*X * Three blocks of information must follow contiguously at this point; the first blockW * contains information about the difference between the bit addresses of two adjacentS * elements in each dimension (the stride). The second b block contains informationR * about the dimension bounds. The third block is the relative bit position withA * respect to dsc64$a_base of the first actual bit of the array. */ * The strides block has the following format:R * __int64 dsc64$q_v0; Bit offset of the element whose subscripts are all zero,% * with respect to dsc64$a_base' * __int64 dsc64$q_s [DIMCT]; Strides *. * The bounds block has the following format: * struct * {$ * __int64 dsc64$q_l; Lowerc bound$ * __int64 dsc64$q_u; Upper bound * } dsc64$bounds [DIMCT]; *, * The last block has the following format: * __int64 dsc64$q_pos; *< * (DIMCT represents the value contained in dsc64$b_dimct.) */ };/*( * 64-bit String with Bounds Descriptor: */struct dsc64$descriptor_sb{Q unsigned short dsc64$w_mbo; /* must-be-one field overlays 16-bit length field */D unsigned char dsc64$b_dtype; /* data type code = DSC64$K_DTYPE_T */L unsigned char dsc64$b_class; /*d descriptor class code = DSC64$K_CLASS_SB */J long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointer */B unsigned __int64 dsc64$q_length; /* length of string in bytes */D char *dsc64$pq_pointer;/* address of first byte of data storage */* __int64 dsc64$q_sb_l1; /* lower bound */* __int64 dsc64$q_sb_u1; /* upper bound */};/*6 * 64-bit Unaligned Bit String with Bounds Descriptor: */struct dsc64$descriptor_ubsb{Q unsigned short dsc64$w_mbo; /* must-be-one field eoverlays 16-bit length field */E unsigned char dsc64$b_dtype; /* data type code = DSC64$K_DTYPE_VU */N unsigned char dsc64$b_class; /* descriptor class code = DSC64$K_CLASS_UBSB */J long dsc64$l_mbmo; /* must-be-minus-one field overlays 32-bit pointer */D unsigned __int64 dsc64$q_length; /* length of data item in bits */E char *dsc64$pq_base; /* address to which dsc64$l_pos is relative */Y __int64 dsc64$q_pos; /* bit position relative to dsc64$a_base of first bit in string */+ __int64 fdsc64$q_ubsb_l1;/* lower bound */+ __int64 dsc64$q_ubsb_u1;/* upper bound */};/* * Codes for dsc64$b_dtype: *//* * Atomic data types: */,#define DSC64$K_DTYPE_Z 0 /* unspecified */K#define DSC64$K_DTYPE_BU 2 /* byte (unsigned); 8-bit unsigned quantity */L#define DSC64$K_DTYPE_WU 3 /* word (unsigned); 16-bit unsigned quantity */P#define DSC64$K_DTYPE_LU 4 /* longword (unsigned); 32-bit unsigned quantity */P#define DSC64$K_DTYPE_QU 5 /* quadword (unsigned); 64-gbit unsigned quantity */R#define DSC64$K_DTYPE_OU 25 /* octaword (unsigned); 128-bit unsigned quantity */\#define DSC64$K_DTYPE_B 6 /* byte integer (signed); 8-bit signed 2's-complement integer */]#define DSC64$K_DTYPE_W 7 /* word integer (signed); 16-bit signed 2's-complement integer */a#define DSC64$K_DTYPE_L 8 /* longword integer (signed); 32-bit signed 2's-complement integer */a#define DSC64$K_DTYPE_Q 9 /* quadword integer (signed); 64-bit signed 2's-complement integer */c#definhe DSC64$K_DTYPE_O 26 /* octaword integer (signed); 128-bit signed 2's-complement integer */U#define DSC64$K_DTYPE_F 10 /* F_floating; 32-bit single-precision floating point */U#define DSC64$K_DTYPE_D 11 /* D_floating; 64-bit double-precision floating point */U#define DSC64$K_DTYPE_G 27 /* G_floating; 64-bit double-precision floating point */Y#define DSC64$K_DTYPE_H 28 /* H_floating; 128-bit quadruple-precision floating point */5#define DSC64$K_DTYPE_FC 12 /* F_floating complex */ i5#define DSC64$K_DTYPE_DC 13 /* D_floating complex */5#define DSC64$K_DTYPE_GC 29 /* G_floating complex */5#define DSC64$K_DTYPE_HC 30 /* H_floating complex */@#define DSC64$K_DTYPE_CIT 31 /* COBOL Intermediate Temporary *//* * String data types: */i#define DSC64$K_DTYPE_T 14 /* character string; a single 8-bit character or a sequence of characters */`#define DSC64$K_DTYPE_VT 37 /* varying character string; 16-bit count, followed by a string */;#define DSC64$K_DTYPE_NU 15 / j* numeric string, unsigned */E#define DSC64$K_DTYPE_NL 16 /* numeric string, left separate sign */I#define DSC64$K_DTYPE_NLO 17 /* numeric string, left overpunched sign */F#define DSC64$K_DTYPE_NR 18 /* numeric string, right separate sign */J#define DSC64$K_DTYPE_NRO 19 /* numeric string, right overpunched sign */=#define DSC64$K_DTYPE_NZ 20 /* numeric string, zoned sign */7#define DSC64$K_DTYPE_P 21 /* packed decimal string */3#define DSC64$K_DTYPE_V 1 /* aligned bit string */7#d kefine DSC64$K_DTYPE_VU 34 /* unaligned bit string *//* * IEEE data types: */=#define DSC64$K_DTYPE_FS 52 /* IEEE float basic single S */G#define DSC64$K_DTYPE_FT 53 /* IEEE float basic double T */E#define DSC64$K_DTYPE_FSC 54 /* IEEE float basic single S complex */E#define DSC64$K_DTYPE_FTC 55 /* IEEE float basic double T complex *//* * Miscellaneous data types: */;#define DSC64$K_DTYPE_ZI 22 /* sequence of instructions */8#define DSC64$K_DTYPE_ZEM 23 /* p lrocedure entry mask */.#define DSC64$K_DTYPE_DSC 24 /* descriptor */9#define DSC64$K_DTYPE_BPV 32 /* bound procedure value */5#define DSC64$K_DTYPE_BLV 33 /* bound label value */:#define DSC64$K_DTYPE_ADT 35 /* absolute date and time *//* * Reserved data type codes:( * codes 38-191 are reserved to DIGITAL;S * codes 160-191 are reserved to DIGITAL facilities for facility-specific purposes;J * codes 192-255 are reserved for DIGITAL's Computer Special Systems Group) * and for customemrs for their own use. *//* * Codes for dsc64$b_class: */8#define DSC64$K_CLASS_S 1 /* fixed-length descriptor */:#define DSC64$K_CLASS_D 2 /* dynamic string descriptor */S/* DSC64$K_CLASS_V ** variable buffer descriptor; reserved for use by DIGITAL */1#define DSC64$K_CLASS_A 4 /* array descriptor */5#define DSC64$K_CLASS_P 5 /* procedure descriptor */F/* DSC64$K_CLASS_PI ** procedure incarnation descriptor; obsolete */R/* DSC64$K_CLASS_J ** label descriptor; reser nved for use by the VMS Debugger */B/* DSC64$K_CLASS_JI ** label incarnation descriptor; obsolete */;#define DSC64$K_CLASS_SD 9 /* decimal string descriptor */B#define DSC64$K_CLASS_NCA 10 /* noncontiguous array descriptor */<#define DSC64$K_CLASS_VS 11 /* varying string descriptor */C#define DSC64$K_CLASS_VSA 12 /* varying string array descriptor */C#define DSC64$K_CLASS_UBS 13 /* unaligned bit string descriptor */B#define DSC64$K_CLASS_UBA 14 /* unaligned bit array descriptor */@#d oefine DSC64$K_CLASS_SB 15 /* string with bounds descriptor */P#define DSC64$K_CLASS_UBSB 16 /* unaligned bit string with bounds descriptor *//*# * Reserved descriptor class codes:( * codes 15-191 are reserved to DIGITAL;S * codes 160-191 are reserved to DIGITAL facilities for facility-specific purposes;J * codes 192-255 are reserved for DIGITAL's Computer Special Systems Group) * and for customers for their own use. *//*: * A simple macro to construct a 64-bit string descriptopr: */#define $DESCRIPTOR64(name,string) struct dsc64$descriptor_s name = { 1, DSC64$K_DTYPE_T, DSC64$K_CLASS_S, -1, sizeof(string)-1, string }/*3 * A macro to distinguish a 64-bit descriptor: */#define $is_desc64(desc) ((((struct dsc64$descriptor *)desc)->dsc64$l_mbmo == -1) && (((struct dsc64$descriptor *)desc)->dsc64$w_mbo == 1))'#endif /* __INITIAL_POINTER_SIZE */#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#ifdef __INITIAL_POINTERq_SIZE+# pragma __required_pointer_size __restore#endifC#pragma __standard /* This file uses non-ANSI-Standard features */#endif /* __DESCRIP_LOADED */ww *ԗ#ifndef __DIRENT_LOADED#define __DIRENT_LOADEDM/******************************************************************************1** - Directory manipulation functions**M*******************************************************************************1** Header introduced by the ISO POSIX-1 r Standard**K** Definitions in this header file may not be available on all versions ofK** OpenVMS. See the DEC C Runtime Library reference manual for specifics.**M*****************************************************************************I** I** Copyright 2004 Hewlett-Packard Development Company, L.P. I** I** Confidential computser software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. t I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be counstrued as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*K** If the user has used /pointer_size=short or /pointer_size=long, we will+** begin in a 32-bit pointer size context.*/#if __INvITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*1** The type ino_t is an _XOPEN_SOURCE extension.*/5#if defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCE# ifndef __INO_T # define __INO_T typedef __ino_t ino_t; # endif#endif/*M** The definition of the dirent structure has extensions when being compiled** using _XOPEN_SOURCE.*/!#pragma __member_alignment __save#pragma __member_alignment struct dirent {- cwhar d_name[256]; /* name of entry */8# if defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCE#if !_USE_STD_STAT /* 3 word array */B __ino_t d_ino[3]; /* file serial number (vms-style inode) */#else /* quadword */ __ino_t d_ino;#endif # endif };$#pragma __member_alignment __restore/*G** Data structure returned by opendir() function. A pointer to one ofI** these is returned by opendir() and is used by the the other routines.F** The contents of thisx structure do not have to be visible to users.*/typedef struct _dirdesc DIR;/*F** Define a private typedef used to indicate a short pointer to a DIR3** structure which is always returned by the CRTL.*/typedef DIR * __DIR_ptr32;.typedef struct dirent * __struct_dirent_ptr32;/*I** The only pointer permitted to be a 64 bit pointer is the name of the G** directory being opened. All structure pointers are pointers to DECI** C RTL allocated memory. We will define a 64 bity character pointer to'** be used in the function prototypes.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*=** If on OpenVMS V7.0 or higher, provide function prototypes=** (dirent functions have been added in version V7.0 of VMS)*/#if __CRTL_VER >= 70000000*__DIR_ptr32 opendir (const char *dirname);+__struct_dirent_ptr32 readdir (DIR * dirp);void rewinddir (DIR *dirp);int closedir (DIR *dirp);/*** X/Open extensions*/5#if defined z_XOPEN_SOURCE || !defined _POSIX_C_SOURCE+ void seekdir (DIR *dirp, long int loc);! long int telldir (DIR *dirp);#endif&#endif /* if __CRTL_VER >= 70000000 */#if __CRTL_VER > 70300000## if __INITIAL_POINTER_SIZE == 32 # pragma __pointer_size 32 # endif7 int readdir_r(DIR * __dirp, struct dirent *__entry,, struct dirent **__result);# if __INITIAL_POINTER_SIZE # pragma __pointer_size 32> int _readdir_r32(DIR * __dirp,{ struct dirent *__entry,3 struct dirent **__result); # pragma __pointer_size 64> int _readdir_r64(DIR * __dirp, struct dirent *__entry,3 struct dirent **__result); # endif%#endif /* if __CRTL_VER > 70300000 *//*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __DIRENT_LOADED */ww|F*ԗ#ifndef __DLFCN_LOADED#define __DLFCN_LOADEDM/******************************************************************************** - Dynamic linking**M*******************************************************************************1** Header introduced by the X/Open Specification**K** Definitions in this header file may not be available on all versions ofK** OpenVMS. See the DEC C Runtime Library reference manual for specifics.**M********************}*********************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** ~ I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*?** If compiled with /pointer_size=short or /pointer_size=long,+** begin in a 32-bit pointer size context.*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*5** Define the mode parameters to the dlopen function*/#define RTLD_LAZY 1#define RTLD_NOW 2/*** Function prototypes*/4#if __INITIAL_POINTER_SIZE && __CRTL_VER >= 703200009 void *dlopen (__const_char_ptr64 pathname, int mode);@ void *dlsym (__void_ptr64 handle, __const_char_ptr64 name);' int dlclose (__void_ptr64 handle);#else2 void *dlopen (const char *pathname, int mode);2 void *dlsym (void *handle, const char *name); int dlclose (void *handle);#endifchar *dlerror (void);/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __DLFCN_LOADED */ww8*ԗ#ifndef __ERRNO_LOADED#define __ERRNO_LOADEDM/******************************************************************************!** - Error definitions**M*****************************************************************************,** Header introduced by the ANSI C StandardM****************************************** *************************************I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. **N*******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*K** Create 'public' typedefs that are either insensitive to pointer size or>** are sensitive to pointer size and must use short pointers.*/J#define EPERM 1 /* Not owner */J#define ENOENT 2 /* No such file or directory */J#define ESRCH 3 /* No such process */J#define EINTR  4 /* Interrupted system call */J#define EIO 5 /* I/O error */J#define ENXIO 6 /* No such device or address */J#define E2BIG 7 /* Arg list too long */J#define ENOEXEC 8 /* Exec format error */J#define EBADF 9 /* Bad file number */J#define ECHILD 10 /* No children */J#define EAGAIN 11 /* No more processes */J#define ENOMEM 12 /* Not enough core */J#define EACCES 13 /* Permission denied */J#define EFAULT 14 /* Bad address */J#define ENOTBLK 15 /* Block device required */J#define EBUSY 16 /* Mount device busy */J#define EEXIST 17 /* File exists  */J#define EXDEV 18 /* Cross-device link */J#define ENODEV 19 /* No such device */J#define ENOTDIR 20 /* Not a directory */J#define EISDIR 21 /* Is a directory */J#define EINVAL 22 /* Invalid argument */J#define ENFILE 23 /* File table overflow */J#define EMFILE  24 /* Too many open files */J#define ENOTTY 25 /* Not a typewriter */J#define ETXTBSY 26 /* Text file busy */J#define EFBIG 27 /* File too large */J#define ENOSPC 28 /* No space left on device */J#define ESPIPE 29 /* Illegal seek */J#define EROFS 30 /* Read-only file system  */J#define EMLINK 31 /* Too many links */J#define EPIPE 32 /* Broken pipe */J#define EDOM 33 /* Math argument */J#define ERANGE 34 /* Result too large */J#define EWOULDBLOCK 35 /* I/O stream empty */J#define EINPROGRESS 36 /* Operation now in progress */J#define EALREADY 37 /* Operation already in progress */J#define ENOTSOCK 38 /* Socket operation on non-socket */J#define EDESTADDRREQ 39 /* Destination address required */J#define EMSGSIZE 40 /* Message too long */J#define EPROTOTYPE 41 /* Protocol wrong type for socket */J#define ENOPROTOOPT 42 /* Protocol not available */J#define EPROTONOSUPPORT 43 /* Protocol not supported */J#define ESOCKTNOSUPPORT 44 /* Socket type not supported */J#define EOPNOTSUPP 45 /* Operation not supported on socket */K#define EPFNOSUPPORT 46 /* Protocol family not supported */ J#define EAFNOSUPPORT 47 /* Address family not supported */J#define EADDRINUSE 48 /* Address already in use */J#define EADDRNOTAVAIL 49 /* Can't assign requested address */J#define ENETDOWN 50 /* Network is down  */J#define ENETUNREACH 51 /* Network is unreachable */J#define ENETRESET 52 /* Network dropped connection on reset */J#define ECONNABORTED 53 /* Software caused connection abort */J#define ECONNRESET 54 /* Connection reset by peer */J#define ENOBUFS 55 /* No buffer space available */J#define EISCONN 56 /* Socket is already connected */J#define ENOTCONN 57 /* Socket is not connected */J#define ESHUTDOWN 58 /* Can't send after socket shutdown */K#define ETOOMANYREFS 59 /* Too many references: can't splice */ J#define ETIMEDOUT 60 /* Connection timed out */J#define ECONNREFUSED 61 /* Connection refused */J#define ELOOP 62 /* Too many levels of symbolic links */J#define ENAMETOOLONG 63 /* File name too long */J#define EHOSTDOWN 64 /* Host is down */J#define EHOSTUNREACH 65 /* No route to host */J#define ENOTEMPTY 66 /* Directory not empty */J#define EPROCLIM 67 /* Too many processes */J#define EUSERS 68 /* Too many users */J#define EDQUOT 69 /* Disk quota exceeded */J#define ENOMSG 70 /* No message of desired type  */J#define EIDRM 71 /* Identifier removed */J#define EALIGN 72 /* Alignment error */J#define ESTALE 73 /* Stale NFS file handle */J#define EREMOTE 74 /* Too many levels of remote in path */J#define ENOLCK 75 /* No locks available */J#define ENOSYS 76 /* Function not implemented */J#define EFTYPE 77 /* Inappropriate operation for file type */J#define ECANCELED 78 /* Operation canceled */J#define EFAIL 79 /* Cannot start operation */J#define EINPROG 80 /* Asynchronous operation in progress */J#define ENOTSUP 81 /* Function not implemented */J#define EDEADLK 82 /* Resource deadlock avoided */J#define ENWAIT 83 /* No waiting processes */J#define EI LSEQ 84 /* Illegal byte sequence */J#define EBADCAT 85 /* Bad message catalogue format [1] */J#define EBADMSG 86 /* Corrupted message detected */J#define EABANDONED 87 /* Owner can not release resource */;#define EOVERFLOW 88 /* Value to large for datatype */#ifndef __HIDE_FORBIDDEN_NAMESJ#define __ERRNO_MAX 88 /* MUST equal largest errno value */J#define EVMSERR 65535 /* error for non-translatable VMS errors */#endif/*** Function prototypes*/Nint *CMA$TIS_ERRNO_GET_ADDR (void); /* UNIX style error code */Nint *CMA$TIS_VMSERRNO_GET_ADDR (void); /* VMS error (errno == EVMSERR) */.void CMA$TIS_ERRNO_SET_VALUE (int __value);.void CMA$TIS_VMSERRNO_SET_VALUE (int __value);/*H** In strict ANSI compilation mode, the dollar sign ('$') is not allowedJ** in identifier names. This jacket routine provides an ANSI-compliant way** to access errno.*/8#if defined(__DECCXX) && (__DECCXX_VER >= 60000000) && \E (defined(__STD_STRICT_ANSI) || defined(__STD_STRICT_ANSI_ERRORS))8inline static int *__CXX_CMA_TIS_ERRNO_GET_ADDR(void) { & return CMA$TIS_ERRNO_GET_ADDR(); }#endif/*H** The CMA function prototypes are defined as uppercase for applicationH** programs which compile using /NAMES=AS_IS. The CMA shareable images$** only offer the uppercase symbol.**F** Define lowercase names using a macro such that applications which C** already compile with either /STANDARD=ANSI or /STANDARD=RELAXED%** continue to successfully compile.*/9#define cma$tis_errno_get_addr CMA$TIS_ERRNO_GET_ADDR<#define cma$tis_vmserrno_get_addr CMA$TIS_VMSERRNO_GET_ADDR:#define cma$tis_errno_set_value CMA$TIS_ERRNO_SET_VALUE=#define cma$tis_vmserrno_set_value CMA$TIS_VMSERRNO_SET_VALUE/*4** Define macros for accessing errno and vaxc$errno*/8#if defined(__DECCXX) && (__DECCXX_VER >= 60000000) && \E  (defined(__STD_STRICT_ANSI) || defined(__STD_STRICT_ANSI_ERRORS))8# define errno (*__CXX_CMA_TIS_ERRNO_GET_ADDR())#else2# define errno (*CMA$TIS_ERRNO_GET_ADDR())#endif1#define vaxc$errno (*CMA$TIS_VMSERRNO_GET_ADDR())/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __ERRNO_LOADED */ww]*ԗ#ifndef __ERRNODEF_LOADED#define __ERRNODEF_LOADED 1M/******************************************************************************J** - VMS Status Code Equivalents for UNIX-style Error Codes **M******************************************************************************* Header is nonstandardM*****************************************************************************I** I** Copyright 2004 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warrant ies for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*** Extern model*/#pragma __extern_model __save$#pragma __extern_model __globalvalue/*!** Define the external constants*/Iextern C$_EPERM; /* not owner */Iextern C$_ENOENT; /* no such file or directory */Iextern C$_ESRCH; /* no such process */Iextern C$_EINTR; /* interrupted system call */Iextern C$_EIO; /* i/o error  */Iextern C$_ENXIO; /* no such device or address */Iextern C$_E2BIG; /* arg list too long */Iextern C$_ENOEXEC; /* exec format error */Iextern C$_EBADF; /* bad file number */Iextern C$_ECHILD; /* no children */Iextern C$_EAGAIN; /* no more processes */Iextern C$_ENOMEM;  /* not enough core */Iextern C$_EACCES; /* permission denied */Iextern C$_EFAULT; /* bad address */Iextern C$_ENOTBLK; /* block device required */Iextern C$_EBUSY; /* mount device busy */Iextern C$_EEXIST; /* file exists */Iextern C$_EXDEV; /* cross-device link */Iextern C$_ENODEV; /* no such device */Iextern C$_ENOTDIR; /* not a directory */Iextern C$_EISDIR; /* is a directory */Iextern C$_EINVAL; /* invalid argument */Iextern C$_ENFILE; /* file table overflow */Iextern C$_EMFILE; /* too many open files */Iextern C$_ENOTTY; /* not a typewriter  */Iextern C$_ETXTBSY; /* text file busy */Iextern C$_EFBIG; /* file too large */Iextern C$_ENOSPC; /* no space left on device */Iextern C$_ESPIPE; /* illegal seek */Iextern C$_EROFS; /* read-only file system */Iextern C$_EMLINK; /* too many links */Iextern C$_EPIPE;  /* broken pipe */Iextern C$_EDOM; /* math argument */Iextern C$_ERANGE; /* result too large */Iextern C$_EWOULDBLOCK; /* I/O operation would block channel */Iextern C$_EINPROGRESS; /* Operation now in progress */Iextern C$_EALREADY; /* Operation already in progress */Iextern C$_ENOTSOCK; /* Socket operation on non-socket */Iextern C$_EDESTADDRREQ; /* Destination address required */Iextern C$_EMSGSIZE; /* Message too long */Iextern C$_EPROTOTYPE; /* Protocol wrong type for socket */Iextern C$_ENOPROTOOPT; /* Protocol not available */Iextern C$_EPROTONOSUPPORT; /* Protocol not supported */Iextern C$_ESOCKTNOSUPPORT; /* Socket type not supported */Iextern C$_EOPNOTSUPP; /* Operation not supported on socket */Jextern C$_EPFNOSUPPORT; /* Protocol family not supported */ Iextern C$_EAFNOSUPPORT; /* Address family not supported */Iextern C$_EADDRINUSE; /* Address already in use */Iextern C$_EADDRNOTAVAIL; /* Can't assign requested address */Iextern C$_ENETDOWN; /* Network is down */Iextern C$_ENETUNREACH; /* Network is unreachable */Iextern C$_ENETRESET;  /* Network dropped connection on reset */Iextern C$_ECONNABORTED; /* Software caused connection abort */Iextern C$_ECONNRESET; /* Connection reset by peer */Iextern C$_ENOBUFS; /* No buffer space available */Iextern C$_EISCONN; /* Socket is already connected */Iextern C$_ENOTCONN; /* Socket is not connected */Iextern C$_ESHUTDOWN; /* Can't send after socket shutdown */Jextern C$_ETOOMANYREFS; /* Too many references: can't splice */ Iextern C$_ETIMEDOUT; /* Connection timed out */Iextern C$_ECONNREFUSED; /* Connection refused */Iextern C$_ELOOP; /* Too many levels of symbolic links */Iextern C$_ENAMETOOLONG; /* File name too long */Iextern C$_EHOSTDOWN; /* Host is down */Iextern C$_EHOSTUNREACH; /* No route to host */Iextern C$_ENOTEMPTY; /* Directory not empty */Iextern C$_EPROCLIM; /* Too many processes */Iextern C$_EUSERS; /* Too many users */Iextern C$_EDQUOT; /* Disk quota exceeded */Iextern C$_ENOMSG; /* No message of desired type */Iextern C$_EIDRM; /* Identifier removed */Iextern C$_EALIGN;  /* Alignment error */Iextern C$_ESTALE; /* Stale NFS file handle */Iextern C$_EREMOTE; /* Too many levels of remote in path */Iextern C$_ENOLCK; /* No locks available */Iextern C$_ENOSYS; /* Function not implemented */Iextern C$_EFTYPE; /* Inappropriate operation for file type */Iextern C$_ECANCELED; /* Operation canceled  */Iextern C$_EFAIL; /* Cannot start operation */Iextern C$_EINPROG; /* Asynchronous operation in progress */Iextern C$_ENOTSUP; /* Function not implemented */Iextern C$_EDEADLK; /* Resource deadlock avoided */Iextern C$_ENWAIT; /* No waiting processes */Iextern C$_EILSEQ; /* Illegal byte sequence */Iextern C$_EBADCAT; /* Bad message c atalogue format [1] */Iextern C$_EBADMSG; /* Corrupted message detected */Iextern C$_EABANDONED; /* Owner can not release resource *//*** VMS-specific error codes*/Iextern C$_ERROR; /* C error condition */Iextern C$_INV_FRAME; /* invalid frame while in fork state */Iextern C$_KILL; /* process killed, unimpl signal specified */Iextern C$_LONGJMP; /* longjump requested  */Iextern C$_LONGJMP_FAILED; /* attempted longjmp failed *//*** New in OpenVMS V6.2*/#if __CRTL_VER >= 60200000Iextern C$_SIGUSR1; /* user signal 1 */Iextern C$_SIGUSR2; /* user signal 2 */Iextern C$_LOCALEIDMISMAT; /* locale version doesn't match DEC C RTL */Iextern C$_LOCALEBAD; /* not a locale file */Iextern C$_LOCALEINCOMPLET; /* not all requested categories present */#endif/*** New in OpenVMS V7.0*/#if __CRTL_VER >= 70000000Iextern C$_SIG0; /* reserved to Digital */Iextern C$_SIGN; /* reserved to Digital */Iextern C$_SIGPIPE; /* reserved to Digital */Iextern C$_SIGCHLD; /* reserved to Digital */Jextern C$_HOST_NOT_FOUND; /* Unknown host */ Iextern C$_TRY_AGAIN; /* Host name lookup failure */Iextern C$_NO_RECOVERY; /* Unknown server error */Iextern C$_NO_DATA; /* No data record of requested type */Iextern C$_NO_ADDRESS; /* No address associated with name */Iextern C$_NO_TCP; /* Cannot find TCP routine or UCX$IPC_SHR */Iextern C$_NOSYSSHR; /* Link /NOSYSSHR disables image activate */Iextern C$_EXIT1; /* reserved to Digital  */Iextern C$_EXIT255; /* reserved to Digital */Iextern C$_ILLSYSTDF; /* Illegal OpenVMS system TDF */Iextern C$_QSORT2BIG; /* Array passed to qsort function ... */#endif/*** New in OpenVMS V7.3*/#if __CRTL_VER >= 70300000Iextern C$_SIGWINCH; /* reserved to Digital */#endif/*** New in OpenVMS V8.3*/#if __CRTL_VER >= 80300000Hextern C$_SIGTERM; /* reserved to Digital */@extern C$_EOVERFLOW; /* value too large for datatype */#endif#ifdef __cplusplus }#endif #pragma __extern_model __restore#pragma __standard#endif /* __ERRNODEF_LOADED */ww+ԗ#ifndef __FCNTL_LOADED#define __FCNTL_LOADEDM/******************************************************************************(** - File control information**M*****************************************************************************1** Header introduced by the ISO POSIX-1 StandardM*****************************************************************************I** I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying.  I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I**  M******************************************************************************/#pragma __nostandard #include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endif/* ** `cmd' values for fcntl()*/ #define F_DUPFD 0#define F_GETFD 1#define F_SETFD 2#define F_GETFL 3#define F_SETFL  4#define F_GETLK 7#define F_SETLK 8#define F_SETLKW 9/* *** File descriptor flags used for fcntl()*/ #define FD_CLOEXEC 1/*3** `l_type' values for record locking with fcntl()*/ #define F_RDLCK 1#define F_WRLCK 2#define F_UNLCK 3/* D** ISO POSIX-1 defines some values for the flags argument to open()A** and specifies that they reside here. For compatibility with K** DEC C V5.0 and prior, the an old set of flags is duplicated in */ /* * ** This group is shared with  */ #ifndef O_RDONLY # define O_RDONLY 000# define O_WRONLY 001# define O_RDWR 002# define O_APPEND 010# define O_CREAT 01000# define O_TRUNC 02000# define O_EXCL 04000#endif /* # ** This group is not in file.h */ #define O_ACCMODE 0033#define O_NOCTTY 010000 /* not implemented */#if __CRTL_VER >= 70000000# define O_NONBLOCK 0100000#endif/* K** X/Open specifies that this header defines mode_t, pid_t, off_t. DefineH** them for X/open mode, or for a default compilation, unless they wereC** previously defined or the user requested DECC V4 compatibility.*/5#if defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCE5# if !defined __MODE_T && !defined _DECC_V4_SOURCE# define __MODE_T typedef __mode_t mode_t; # endif4# if !defined __OFF_T && !defined _DECC_V4_SOURCE# define __OFF_T typedef __off_t off_t; # endif4# if !defined __PID_T && !defined _DECC_V4_SOURCE# define __PID_T typedef __pid_t pid_t; # endif /* ** Define seek modes. */# define SEEK_SET 0# define SEEK_CUR 1# define SEEK_END 2 /* > ** Constants for file status flags for open() and fcntl() */ p# define O_SYNC 00040000 /* SYNCHIO: CRTL now supports synchronized IO using O_SYNC and O_DSYNC flags */U# define O_DSYNC O_SYNC /* On VMS O_DSYNC and O_SYNC are treated identically */#endif/* ** DEC C Extensions*/ #ifndef _POSIX_C_SOURCE /* < ** O_NDELAY is shared with . O_NONBLOCK is the+ ** standard flag for similar behavior. */ # ifndef O_NDELAY# define O_NDELAY 004# define O_NOWAIT 004 # endif#endif/*-** Structure flock used in calls to fcntl().B** All structures should be member aligned on natural boundaries.;** Note that wh en compiled with macro _LARGEFILE defined, =** offsets for start and len are longer, the flock structure** is longer.*/!#pragma __member_alignment __save#pragma __member_alignment##define __FLOCK_OFF32_MEMBERS \1 short l_type; /* Type of lock */ \< short l_whence; /* Flag for starting offset */ \< __off32_t l_start; /* Relative offset in bytes */ \; __off32_t l_len; /* Size; if 0 then until EOF */ \J __pid_t l_pid; /* Process ID of the process holding the lock */##define __FLOCK_OFF64_MEMBERS \1 short l_type; /* Type of lock */ \< short l_whence; /* Flag for starting offset */ \< __off64_t l_start; /* Relative offset in bytes */ \; __off64_t l_len; /* Size; if 0 then until EOF */ \J __pid_t l_pid; /* Process ID of the process holding the lock */struct flock {#if __USE_OFF64_T __FLOCK_OFF64_MEMBERS#else __FLOCK_OFF32_MEMBERS#endif};struct __flock_off32 { __FLOCK_OFF32_MEMBERS};struct __flock_off64 { __FLOCK_OFF64_MEMBERS};$#pragma __member_alignment __restore/*#** ISO POSIX-1 function prototypes*/+#if __USE_OFF64_T && __CRTL_VER >= 80300000!# pragma __extern_prefix __save%# pragma __extern_prefix "__off64_"#endif'int fcntl (int __fd, int __cmd, ...);+#if __USE_OFF64_T && __CRTL_VER >= 80300000"# pragma __extern_prefix __restore#endif /* M ** The function open in DEC C V4.0 had a required mode_t parameter if inM ** strict ANSI mode. This is not standard conforming, so it it here for ** compatibility only. */ =#if defined _DECC_V4_SOURCE && defined __HIDE_FORBIDDEN_NAMESJ int open (const char *__file_spec, int __flags, __mode_t __mode, ...);#else9 int open (const char *__file_spec, int __flags, ...);#endif/* L** DEC C extends creat with extra parameters when not in strict POSIX mode.*/#ifndef _POSIX_C_SOURCE> int creat (const char *__file_spec, __mode_t __mode, ...);#else9 int creat (const char *__file_spec, __mode_t __mode);#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __FCNTL_LOADED */wwQ+ԗ#ifndef __FILE_LOADED#define __FILE_LOADED 1M/********************************************************************* *********=** - Manifest constants used by BSD open() function**M******************************************************************************* Header is nonstandardM*******************************************************************************M** Copyright Digital Equipment Corporation 1993, 1997. All rights reserved.**B** Restricted Rights: Use, duplication, or disclosure by the U.S.F** Government is subject to restrictions as set forth in subparagraphF** (c) (1) (ii) of DFARS 252.227-7013, or in FAR 52.227-19, or in FAR&** 52.227-14 Alt. III, as applicable.**A** This software is proprietary to and embodies the confidentialD** technology of Digital Equipment Corporation. Possession, use, orG** copying of this software and media is authorized only pursuant to aD** valid written license from Digital or an authorized sublicensor.**N*******************************************************************************/#pragma __nostandard/* M** This group of constants is shared with , protected with O_RDONLY*/ #ifndef O_RDONLY # define O_RDONLY 000# define O_WRONLY 001# define O_RDWR 002# define O_APPEND 010# define O_CREAT 01000# define O_TRUNC 02000# define O_EXCL 04000#endif/* D** This group is shared with too, protected with O_NDELAY*/ #ifndef O_NDELAY# define O_NDELAY 004# define O_NOWAIT 004#endif#pragma __standard#endif /* __FILE_LOADED */ww;+ԗ#ifndef __FLOAT_LOADED#define __FLOAT_LOADED 1M/******************************************************************************1** - Characteristics of floating types**M*****************************************************************************,** Header introduced by the ANSI C StandardM*****************************************************************************I**  I** Copyright 2004 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to  change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*E** The following literals and routines are available on OpenVMS for 3** Alpha, but only after OpenVMS V7.1 or with C++.*/#if !defined __VAXQ# if defined(__DECCXX) || (!defined _ANSI_C_SOURCE && (__CRTL_VER >= 70100000)) /*= ** Values for the IEEE Rounding Modes (IEEE ANSI Values) **( ** RZ = Round toward zero (chopped)3 ** RN = Round toward nearest (default, normal)' ** RP = Round toward plus infinity( ** RM = Round toward minus infinity */# define FP_RND_RZ 0# define FP_RND_RN 1# define FP_RND_RP 2# define FP_RND_RM 3 /* ** IEEE Constants */# ifdef _IEEE_FP## pragma __extern_model __save,# pragma __extern_model __strict_refdef' extern double decc$gt_dinfinity;# extern double decc$gt_dqnan;# extern double decc$gt_dsnan;& extern float decc$gs_sinfinity;" extern float decc$gs_sqnan;"  extern float decc$gs_ssnan;# if __X_FLOAT%# if (__CRTL_VER >= 60200000): extern long double decc$gx_long_dbl_infinity;# endif3 extern long double decc$gx_long_dbl_qnan;3 extern long double decc$gx_long_dbl_snan; # endif&# pragma __extern_model __restore,# define DBL_INFINITY decc$gt_dinfinity$# define DBL_QNAN decc$gt_dqnan$# define DBL_SNAN decc$gt_dsnan,# define FLT_INFINITY decc$gs_sinfinity$#  define FLT_QNAN decc$gs_sqnan$# define FLT_SNAN decc$gs_ssnan# if __X_FLOAT%# if (__CRTL_VER >= 60200000):# define LDBL_INFINITY decc$gx_long_dbl_infinity# else-# define LDBL_INFINITY DBL_INFINITY# endif1# define LDBL_QNAN decc$gx_long_dbl_qnan1# define LDBL_SNAN decc$gx_long_dbl_snan # else,# define LDBL_INFINITY DBL_INFINITY$# define LDBL_QNAN DBL_QNAN$# define LDBL_SNAN DBL_SNAN # endif # endif /*! ** Macros to get decc$ names  */# if (__CRTL_VER < 70100000)2# define write_rnd(__p1) decc$write_rnd(__p1)$# define read_rnd decc$read_rnd # endif /*? ** Functions to read and write floating point rounding mode *// unsigned int write_rnd(unsigned int __rnd); unsigned int read_rnd(void); # endif#endif/*.** Rounding mode for floating point addition:*/#ifdef __BIASED_FLT_ROUNDS[# define FLT_ROUNDS (__BIASED_FLT_ROUNDS-1) /* use compiler generated value, if present */#else# define FLT_ROUNDS 1 #endif/*%** Radix of exponent representation:*/#define FLT_RADIX 2/*H** Number of FLT_RADIX digits in the mantissa including the hidden bit:*/#define __F_FLT_MANT_DIG 24#define __G_DBL_MANT_DIG 53#if !defined(__VAX)#define __S_FLT_MANT_DIG 24#define __T_FLT_MANT_DIG 53#define __X_FLT_MANT_DIG 113#endif/**** Number of decimal digits of precision:*/#define __F_FLT_DIG 6#define __G_FLT_DIG 15#if !defined(__VAX)#define __S_FLT_DIG 6#define __T_FLT_DIG 15#define __X_FLT_DIG 33#endif/*E** Minimum negative integer such that FLT_RADIX raised to that power2** minus 1 is a normalized floating-point number:*/"#define __F_FLT_MIN_EXP (-127)##define __G_FLT_MIN_EXP (-1023)#if !defined(__VAX)"#define __S_FLT_MIN_EXP (-125)##define __T_FLT_MIN_EXP (-1021)$#define __X_FLT_MIN_EXP (-16381)#endif/*H** Minimum negative integer such that 10 raised to that power is in the/** range of normalized floating-point numbers:*/!#define __F_FLT_MIN_10_EXP (-38)"#define __G_FLT_MIN_10_EXP (-308)#if !defined(__VAX)!#define __S_FLT_MIN_10_EXP (-37)"#define __T_FLT_MIN_10_EXP (-307)##define __X_FLT_MIN_10_EXP (-4931)#endif/*I** Maximum integer such that FLT_RADIX raised to that power minus 1 is a/** representable finite floating point number:*/#define __F_FLT_MAX_EXP 127 #define __G_FLT_MAX_EXP 1023#if !defined(__VAX)#define __S_FLT_MAX_EXP 128 #define __T_FLT_MAX_EXP 1024!#define __X_FLT_MAX_EXP 16384#endif/*H** Maximum integer such that 10 raised to that power is in the range of0** representable finite floating-point numbers:*/#define __F_FLT_MAX_10_EXP 38#define __G_FLT_MAX_10_EXP 307#if !defined(__VAX)#define __S_FLT_MAX_10_EXP 38#define __T_FLT_MAX_10_EXP 308 #define __X_FLT_MAX_10_EXP 4932#endif/*7** Maximum representable finite floating-point number:*/*#define __F_FLT_MAX 1.7014117e+38f4#define __G_FLT_MAX 8.98846567431157854e+307#if !defined(__VAX)+#define __S_FLT_MAX 3.40282347e+38f4#define __T_FLT_MAX 1.79769313486231570e+308L#if defined(__DECCXX) && defined(__ia64) && !defined(__DECFIX_CXXC_BUGS9857)0/* Temporary IPF workaround for __X_FLT_MAX: */;#define __X_FLT_MAX 1.1897314953572317650213E+4932L#elseN#define __X_FLT_MAX 1.189731495357231765085759326628007016196477e4932l#endif#endif/*H** The difference between 1.0 and the least value greater than 1.0 that5** is representable in the given floating-point type"** (i.e. 1.0 + epsilon != 1.0):*/6#define __F_FLT_EPSILON ((float)(1.0 / (1 << 23)))9#define __G_FLT_EPSILON (1.0 / (1 << 30) / (1 << 22))#if !defined(__VAX)+#define __S_FLT_EPSILON 1.19209290e-07f2#define __T_FLT_EPSILON 2.2204460492503131e-16K#define __X_FLT_EPSILON 1.9259299443872358530559779425849273185381e-34l#endif/*6** Minimum normalized positive floating-point number:*/=#define __F_FLT_MIN ((float) 2.93873587705571877e-39)4#define __G_FLT_MIN 5.56268464626800346e-309#if !defined(__VAX)+#define __S_FLT_MIN 1.17549435e-38f3#define __T_FLT_MIN 2.2250738585072014e-308]#define __X_FLT_MIN ((long double) 3.3621031431120935062626778173217526025981e-4932l)#endif/*J** Define the FLT values to be either the __S or __F values based on IEEE*/#if __IEEE_FLOAT,# define FLT_MANT_DIG __S_FLT_MANT_DIG'# define FLT_DIG __S_FLT_DIG+# define FLT_MIN_EXP __S_FLT_MIN_EXP.# define FLT_MIN_10_EXP __S_FLT_MIN_10_EXP+# define FLT_MAX_EXP __S_FLT_MAX_EXP.# define FLT_MAX_10_EXP __S_FLT_MAX_10_EXP'# define FLT_MAX __S_FLT_MAX+# define FLT_EPSILON  __S_FLT_EPSILON'# define FLT_MIN __S_FLT_MIN#else,# define FLT_MANT_DIG __F_FLT_MANT_DIG'# define FLT_DIG __F_FLT_DIG+# define FLT_MIN_EXP __F_FLT_MIN_EXP.# define FLT_MIN_10_EXP __F_FLT_MIN_10_EXP+# define FLT_MAX_EXP __F_FLT_MAX_EXP.# define FLT_MAX_10_EXP __F_FLT_MAX_10_EXP'# define FLT_MAX __F_FLT_MAX+# define FLT_EPSILON __F_FLT_EPSILON'# define FLT_MIN __F_FLT_MIN#endif/*J** Define the  DBL values to be either the __S or __F values based on IEEE*/#if __IEEE_FLOAT,# define DBL_MANT_DIG __T_FLT_MANT_DIG'# define DBL_DIG __T_FLT_DIG+# define DBL_MIN_EXP __T_FLT_MIN_EXP.# define DBL_MIN_10_EXP __T_FLT_MIN_10_EXP+# define DBL_MAX_EXP __T_FLT_MAX_EXP.# define DBL_MAX_10_EXP __T_FLT_MAX_10_EXP'# define DBL_MIN __T_FLT_MIN#elif __G_FLOAT ,# define DBL_MANT_DIG __G_DBL_MANT_DIG'# define DBL_DIG __G_FLT_DIG +# define DBL_MIN_EXP __G_FLT_MIN_EXP.# define DBL_MIN_10_EXP __G_FLT_MIN_10_EXP+# define DBL_MAX_EXP __G_FLT_MAX_EXP.# define DBL_MAX_10_EXP __G_FLT_MAX_10_EXP'# define DBL_MIN __G_FLT_MIN#else# define DBL_MANT_DIG 56# define DBL_DIG 16+# define DBL_MIN_EXP __F_FLT_MIN_EXP.# define DBL_MIN_10_EXP __F_FLT_MIN_10_EXP+# define DBL_MAX_EXP __F_FLT_MAX_EXP.# define DBL_MAX_10_EXP __F_FLT_MAX_10_EXP3# define DBL_MIN 2.93873587705571877e-39#endif #if __IEEE_FLOAT'# define DBL_MAX __T_FLT_MAX#elif __G_FLOAT '# define DBL_MAX __G_FLT_MAX#else# if defined(__VAX)3# define DBL_MAX 1.70141183460469229e+38# else9# define DBL_MAX 1.70141183460469213e+38 # endif#endif#if __IEEE_FLOAT+# define DBL_EPSILON __T_FLT_EPSILON1#elif __G_FLOAT || (__D_FLOAT && !defined(__VAX))E# define DBL_EPSILON (1.0 / (1 << 20) / (1 << 16) / (1 << 16))#elseE# define DBL_EPSILON (1.0 / (1 << 23) / (1 << 16) / (1 << 16))#endif/*-** Define the LDBL values based on __X_FLOAT*/ #if __X_FLOAT,# define LDBL_MANT_DIG __X_FLT_MANT_DIG'# define LDBL_DIG __X_FLT_DIG+# define LDBL_MIN_EXP __X_FLT_MIN_EXP.# define LDBL_MIN_10_EXP __X_FLT_MIN_10_EXP+# define LDBL_MAX_EXP __X_FLT_MAX_EXP.# define LDBL_MAX_10_EXP __X_FLT_MAX_10_EXP'# define LDBL_MAX __ X_FLT_MAX+# define LDBL_EPSILON __X_FLT_EPSILONM# define LDBL_MIN 3.3621031431120935062626778173217526025981e-4932l#else(# define LDBL_MANT_DIG DBL_MANT_DIG## define LDBL_DIG DBL_DIG'# define LDBL_MIN_EXP DBL_MIN_EXP*# define LDBL_MIN_10_EXP DBL_MIN_10_EXP'# define LDBL_MAX_EXP DBL_MAX_EXP*# define LDBL_MAX_10_EXP DBL_MAX_10_EXP## define LDBL_MAX DBL_MAX'# define LDBL_EPSILON DBL_EPSILON## define LDBL_MIN DBL_MIN#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __FLOAT_LOADED */ww+ԗ#ifndef __FP_LOADED#define __FP_LOADED 1M/******************************************************************************)** - ANSI C NCEG floating support**M*****************************************************************************M** Header defined by NCEG Floating-Point C Extensions WG14/N319 X3J11/94-003M*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein.  The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*!** Relaxed refdef external model*/#pragma __extern_model __save'#pragma __extern_model __relaxed_refdef/*#** Naturally align all structures */!#pragma __member_alignment __save#pragma __member_alignment/* J** HUGE_VAL is +infinity or double max. Note that D float has 53 bits of"** precision on AXP and 56 on VAX*/ #if __G_FLOAT=# define HUGE_VAL 8.988465674311578540726371186585e+307#elif __IEEE_FLOAT6# if defined (_IEEE_FP) && (__CRTL_VER >= 60200000). extern double decc$gt_dbl_infinity;-# define HUGE_VAL decc$gt_dbl_infinity # else0# define HUGE_VAL 1.7976931348623158e+308 # endif#else# if !defined(__VAX).# define HUGE_VAL 1.70141183460469213e+38# else.# define HUGE_VAL 1.70141183460469229e+38 # endif#endif/* 5** HUGE_VALL is either +infinity or long double max.*/ #if !__X_FLOAT# define HUGE_VALL HUGE_VAL4#elif defined (_IEEE_FP) && (__CRTL_VER >= 60200000)2 extern long double decc$gx_long_dbl_infinity;/# define HUGE_VALL decc$gx_long_dbl_infinity#elseI# define HUGE_VALL 1.189731495357231765085759326628007016196477e4932l #endif/* C** HUGE_VALF is either +infinity or float max for the correct type*/ #if __G_FLOAT || __D_FLOAT## define HUGE_VALF 1.7014117e+38f4#elif defined (_IEEE_FP) && (__CRTL_VER >= 60200000)( extern float decc$gs_float_infinity;+# define HUGE_VALF decc$gs_float_infinity#else$# define HUGE_VALF 3.40282347e+38f#endif/* J** INFINITY is either +infinity, or a floating constant that overflows atE** compile-time. 1.8e308 is larger than DBL_MAX for D, G or IEEE T.*/ 1#if defined(_IEEE_FP) && (__CRTL_VER >= 60200000)(# define INFINITY decc$gt_dbl_infinity#else# define INFINITY 1.8e308#endif/* L** Implementation's most efficient floating types at least as wide as floatF** and double respectively. Both VAX and Alpha AXP are single/double>** architectures and so float and double are efficient types.*/ typedef float float_t;typedef double double_t;/* L** NAN is defined to be a quiet NaN, if and only if quiet NaN is supported.*/ #ifdef _IEEE_FP" extern double decc$gt_dbl_nan;# define NAN decc$gt_dbl_nan#endif/* 1** Alpha Only Constants for use with fp_classify** L** fp_classify is a type-independent macro that uses the classify functionsJ** in . fp_classify returns one of FP_NAN, FP_INFINIT, FP_NORMAL** FP_SUBNORMAL or FP_ZERO*/ #if !defined(__VAX)# define FP_NAN 0# define FP_INFINITE 1# define FP_NORMAL 2# define FP_SUBNORMAL 3# define FP_ZERO 4 int fp_classf( float __x ); in t fp_class( double __x );% int fp_classl( long double __x );# define fp_classify(x) ((sizeof(x)==sizeof(float))?fp_classf(x)>>1:(sizeof(x)==sizeof(double))?fp_class(x)>>1:fp_classl(x)>>1)#endif)#define __VALH(x) ((unsigned int *)&x)[1])#define __VALL(x) ((unsigned int *)&x)[0]/* \** signbit(x) -- nonzero iff size is negative (negative infinity, zeros and NaN's included)F** isfinite(x) -- nonzero iff x is finite (zero, subnormal or normal)Q** isnormal(x) -- nonzero iff x  is normal (not zero, subnormal, infinite or Nan)B** isnan(x) -- nonzero iff x is Not-A-Number (NaN) [defined only'** if not previously included*/ #if __IEEE_FLOAT.# define signbit(x) (__VALH(x) & 0x80000000)@# define isfinite(x) ((__VALH(x) & 0x7ff00000) != 0x7ff00000 )g# define isnormal(x) ( ((__VALH(x) & 0x7ff00000) != 0x7ff00000) && ((__VALH(x) & 0x7ff00000) != 0)) ).# if !defined __MATH_LOADED || defined __VAXk# define isnan(x) ( ((__VALH(x) & 0x7ff00000) == 0x7ff00000) && ((__VALH(x) & 0xfffff) | __VALL(x)) ) # endif#else*# define signbit(x) (__VALL(x) & 0x8000)# define isfinite(x) 1# define isnormal(x) (x != 0).# if !defined __MATH_LOADED || defined __VAX# define isnan(x) 0 # endif#endif/* O** DECIMAL_DIG -- number of decimal digits such that conversion from double toO** string and back is the identify function if the conversion uses a string of** DECIMAL_DIG digits.*/ #if __D_FLOAT && defined(__VAX)# define DECIMAL_DIG 18#else# define DECIMAL_DIG 17#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore #pragma __extern_model __restore#pragma __standard#endif /* __FP_LOADED */ww6,ԗ#ifndef __FP_CLASS_LOADED#define __FP_CLASS_LOADED 1#if !defined __VAXM/********************************* *********************************************J** - IEEE Std 754-1985 classification function return values**M******************************************************************************* Header is nonstandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I**  I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************//*-** This file uses non-ANSI-Standard features*/#pragma __nostandard/*** Define the FP_ constants*/#define FP_SNAN 0#define FP_QNAN 1#define FP_POS_INF 2#define FP_NEG_INF 3#define FP_POS_NORM 4#define FP_NEG_NORM 5#define FP_POS_DENORM 6#define FP_NEG_DENORM 7#define FP_POS_ZERO 8#define FP_NEG_ZERO 9#pragma __standard#endif /* !__VAX */#endif /* __FP_CLASS_LOADED */ww\,ԗ#ifndef __FTW_LOADED#define __FTW_LOADEDM/******************************************************************************** - walk a file tree**M**************** ***************************************************************>** Header introduced by the X/Open CAE Specification, Issue 4**K** Definitions in this header file may not be available on all versions ofK** OpenVMS. See the DEC C Runtime Library reference manual for specifics.**M*****************************************************************************I** I** Copyright 2004 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*K** If the user has used /pointer_size=short or /pointer_size=long, we will+** begin in a 32-bit pointer size context.*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*I** All includes of other header files must be done prior to altering the** pointer size mode.*/#include /*** Define FTW constant values*/C#define FTW_D 0 /* Directory */C#define FTW_DNR 1 /* Directory without read permission */C#define FTW_F 2 /* File */C#define FTW_NS 3 /* Unknown type, stat() failed */<#if defined _XOPEN_SOURCE_EXTENDED || !defined _XOPEN_SOURCE,# define FTW_SL 4 /* symbolic link */B# define FTW_SLN 5 /* symbolic link names non-existant file */#endif/*P** The callback routine for the ftw function is always passed 32 bit addresses.*/Gtypedef int (* __ftw_callback)(const char *, const struct stat *, int);/*M** We are done defining things which must always be 32 bit pointers. If theL** user has used /pointer_size=32 or /pointer_size=64, we will allow 64 bit*** pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif#if _USE_STD_STAT #pragma __extern_prefix __save #pragma __extern_prefix "__std_"#else#if __USE_OFF64_T!# pragma __extern_prefix __save# if __USE_LONG_GID_T,# pragma __extern_prefix "__off64_ long_gid_" # elif !defined _VMS_V6_SOURCE## pragma __extern_prefix "__off64_"# else+# pragma __extern_prefix "__off64_non_utc_" # endif#elif __USE_LONG_GID_T!# pragma __extern_prefix __save(# pragma __extern_prefix "__long_gid_"X#elif ((__CRTL_VER >= 70301000) && (__CRTL_VER < 70311000) && defined(_VMS_V6_SOURCE)) \V || ((__CRTL_VER >= 70311000) && defined(_VMS_V6_SOURCE) && defined(__LOCAL_TIME_FTW))$# ifdef __CAN_USE_EXTERN_PREFIX'# pragma __extern_prefix __save-# pragma __extern_prefix "__non_utc_" # elseD# define ftw(__p1,__p2,__p3) __non_utc_ftw(__p1,__p2,__p3) # endif#endif /* __USE_OFF64_T */#endif /* _USE_STD_STAT *//*** Function prototypes*/Dint ftw (const char * __path, __ftw_callback __action, int __depth);/*2** Disable extern_prefix if we enabled it earlier*/#if _USE_STD_STAT !#pragma __extern_prefix __restore#else%#if __USE_LONG_GID_T || __USE_OFF64_T$# pragma __extern_prefix __restoreX#elif ((__CRTL_VER >= 70301000) && (__CRTL_VER < 70311000) && defined(_VMS_V6_SOURCE)) \W || ((__CRTL_VER >= 70311000) && defined(_VMS_V6_SOURCE) && defined(__LOCAL_TIME_FTW))$# ifdef __CAN_USE_EXTERN_PREFIX+# pragma __extern_prefix __restore # endif#endif#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __FTW _LOADED */ww>,ԗJ/*************************************************************************J * *J * Copyright 2004 Hewlett-Packard Development Company, L.P. *J * *J * Confidential computer software. Valid license from HP and/or *J * its subsidiaries required for possession, use, or copying. *J *  *J * Consistent with FAR 12.211 and 12.212, Commercial Computer Software, *J * Computer Software Documentation, and Technical Data for Commercial *J * Items are licensed to the U.S. Government under vendor's standard *J * commercial license. *J * *J * Neither HP nor any of its subsidiaries shall be liable for technical *J * or editorial errors or omissions contained herein. The information *J * in this document is provided "as is" without warranty of any kind and *J * is subject to change without notice. The warranties for HP products *J * are set forth in the express limited warranty statements accompanying *J * such products. Nothing herein should be construed as constituting an *J * additional warranty. *J *  *K *************************************************************************//* * HISTORY *S * @(#)$RCSfile: glob.h,v $ $Revision: 1.1.6.2 $ (DEC) $Date: 1993/06/08 01:01:39 $ *G * (c) Copyright 1990, 1991, 1992, 1993 OPEN SOFTWARE FOUNDATION, INC.  * ALL RIGHTS RESERVED  * * OSF/1 1.2 */#ifndef __H_GLOB#define __H_GLOB/*J * POSIX implies that you don't have to include with glob.h.> * (compare with regex.h, where explicit decl is required....) *//*@ * COMPONENT_NAME: (LIBCPAT) Standard C Library Pattern Matching * * FUNCTIONS: * *; * (C) COPYRIGHT International Business Machines Corp. 1991 * All Rights Reserved' * Licensed Materials - Property of IBM *> * US Government Users Restricted Rights - Use, duplication orD * disclosure restricted by GSA ADP Schedule Contract with IBM Corp.+ * com/inc/glob.h, bos320 2/26/91 17:33:08  */#include /* glob() flags */9#d efine GLOB_APPEND 0x01 /* append to end of gl_pathv */?#define GLOB_DOOFFS 0x02 /* first allocate gl_offs NULL ptrs */-#define GLOB_ERR 0x04 /* return on error */;#define GLOB_MARK 0x08 /* add / to end of directory name */=#define GLOB_NOCHECK 0x10 /* return pattern if no matches */<#define GLOB_NOSORT 0x20 /* do not sort matched filenames */>#ifdef _OSF_SOURCE /* Deprecate - GLOB_QUOTE is now default*/A#define GLOB_QUOTE 0x40 /* protects next character */#endif;#define GLOB_NOESCAPE 0x80 /* disable backlash escaping */H/* Pathname Matching error codes - large so not confused with errno.h */2#define GLOB_ABORTED 0x1000 /* error detected */<#define GLOB_NOSPACE 0x2000 /* memory allocation failure */8#define GLOB_NOMATCH 0x4000 /* do not match pathname */#ifdef _XOPEN_SOURCE5#define GLOB_NOSYS -1 /* function not implemented */#endif /* _XOPEN_SOURCE */!#pragma __member_alignment __save#pragma __member_alignment8/* Use this macro in all  glob_t structure definitions */#define __GLOB_T_MEMBERS \A __size_t gl_pathc; /* matched pathname count (not gl_offs) */ \< char **gl_pathv; /* ptr to list of matched pathnames */ \9 __size_t gl_offs; /* # of gl_pathv reserved slots */ \F /* The following structure members are internal to the C Run-Time */\; void *gl_padr; /* ptr to pathname address structure */ \7 void *gl_ptx; /* ptr to first pathname text buffer */#if __INITIAL_POINTER_SIZE# pragma __pointer_size __save# pragma __pointer_size 32> typedef struct __glob_t32 { __GLOB_T_MEMBERS } __glob_t32;# pragma __pointer_size 64> typedef struct __glob_t64 { __GLOB_T_MEMBERS } __glob_t64;## pragma __pointer_size __restore#endif /* /POINTER used */ #if __INITIAL_POINTER_SIZE == 32 typedef __glob_t32 glob_t;"#elif __INITIAL_POINTER_SIZE == 64 typedef __glob_t64 glob_t;#else6 typedef struct glob_t { __GLOB_T_MEMBERS } glob_t;#endif$#pragma __member_alignment __restore#if __CRTL_VER >= 70320000#if defined(__cplusplus) extern "C" {#endif/* )** Pathname Matching function prototypes */#if __INITIAL_POINTER_SIZE#pragma __pointer_size __save#pragma __pointer_size 64#endif/* K** Use 64 bit pointers, so they can be passed to these functions, includingG** the user supplied errfunc function. Note that the C Run-Time should7** only pass a 32 bit pointers to the errfunc function.*/#if __INITIAL_POINTER_SIZEI /* These pointer specific functions require /POINTER to be visible */D int _glob32 (const char *, int, int(*)(__const_char_ptr32,int),  __glob_t32 *);$ void _globfree32 (__glob_t32 *);D int _glob64 (const char *, int, int(*)(__const_char_ptr32,int),  __glob_t64 *);$ void _globfree64 (__glob_t64 *); #endif /* /POINTER_SIZE check */Gint glob (const char *, int, int(*)(__const_char_ptr32,int), glob_t *);void globfree (glob_t *);#if __INITIAL_POINTER_SIZE #pragma __pointer_size __restore#endif#if defined(__cplusplus)}#endif#endif /* __CRTL_VER */#endif /* __H_GLOB */wwc,ԗ#ifndef __GRP_LOADED#define __GRP_LOADED 1#pragma __nostandard#include /*8** Group database functions are available on Alpha only.:** They require version of OpenVMS Alpha higher than V7.3.*/#if __CRTL_VER >= 70301000M/******************************************************************************)** - Group file access functions**M*****************************************************************************1** Header introduced by the ISO POSIX-1 StandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#ifdef __cplusplus extern "C" {#endif/*#** Naturally align data structures*/!#pragma __member_alignment __save#pragma __member_alignment/* ** X/Open extensions for types*/5#if defined _XOPEN_SOURCE || !define!d _POSIX_C_SOURCE# if !defined __GID_T# define __GID_T 1 typedef __gid_t gid_t; # endif# if !defined __SIZE_T# define __SIZE_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __size_t size_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::size_t;#endif # endif#endif/*** Define the group structure*/ struct group{ char *gr_name; __gid32_t gr_gid; char **gr_mem;};/*** Function prototypes.*//*5** Applications compiled with long pointers will use4** __*64() flavour of the group database functions.*/#ifdef __INITIAL_POINTER_SIZE## if __INITIAL_POINTER_SIZE == 64## define getgrent __getgrent64/# define getgrgid(__p1) __getgrgid64(__p1)8# define getgrgid_r(__p1, __p2, __p3, __p4, __p5) \: __getgrgid_r64(__p1, __p2, __p3, __p4, __p5)/# define getgrnam(__p1) __getgrnam64(__p1)8# define getgrnam_r(__p1, __p2, __p3, __p4, __p5) \: __getgrnam_r64(__p1, __p2, __p3, __p4, __p5) # endif#endif void endgrent(void);! struct group *getgrent(void); void setgrent(void);, struct group *getgrgid(__gid32_t __gid);H int getgrgid_r(__gid32_t __gid, struct group *__grp, char *__buffer,1 __size_t __bufsize, struct group **__result);/ struct group *getgrnam(const char *__name);K int getgrnam_r(const char *__name, struct group *__grp, char *__buffer,1 __size_t __bufsize, struct group **__result);#ifdef __cplusplus }#endif$#pragma __member_alignment __restore$#endif /* __CRTL_VER >= 70301000 */#pragma __standard#endif /* __GRP_LOADED */ww-ԗ#ifndef __ICONV_LOADED#define __ICONV_LOADEDM/******************************************************************************#** - code set conversion**M*******************************************************************************>** Header introduced by t he X/Open CAE Specification, Issue 4**K** Definitions in this header file may not be available on all versions ofK** OpenVMS. See the DEC C Runtime Library reference manual for specifics.**M*****************************************************************************I** I** Copyright 2004 Hewlett-Packard Development Company, L.P. I**   I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license.   I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. N othing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard #include #ifdef __cplusplus extern "C" {#endif/*K** If the user has used /pointer_size=short or /pointer_size=long, we will+** begin in a 32-bit pointe r size context.*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*** Define public typedefs*/#ifndef __ICONV_MAJOR# define __ICONV_MAJOR 1#endif#ifndef __ICONV_MINOR# define __ICONV_MINOR 0#endiftypedef void *iconv_t;/*+** Define the __iconv interface definition*/struct __iconv_extern_obj_t;'typedef __size_t (*do_convert_function)K (struct __iconv_extern_obj_t *cd, char **inbuf, __size_t *in bytesleft, , char **outbuf, __size_t *outbytesleft); typedef int (*do_close_function)& (struct __iconv_extern_obj_t *cd);%typedef struct __iconv_extern_obj_t {# do_convert_function do_convert; do_close_function do_close;B unsigned int major; /* major version id */B unsigned int minor; /* minor version id */B int tcs_mb_cur_max; /* tocodeset mb_cur_max */I long int reserved_for_digital; /* private data will be placed here */I int nonidentical_converts; /* num non-identical converts */} *__iconv_extern_obj_p;/*K** These functions do not support 64 bit pointers being used as arguments.*/Jstruct __iconv_extern_obj_t *_u_iconv_open (char *tocode, char *fromcode);__size_t iconv (iconv_t __cd, #if _XOPEN_SOURCE == 500const#endif- char **__inbuf, __size_t *__inbytesleft, 9 char **__outbuf, __size_t *__outbytesleft);/*O** If the user has used /pointer_size=32 or /pointer_size=64, we will allow 64.** bit pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*** Function prototypes*/#int iconv_close (iconv_t __cd);Ciconv_t iconv_open (const char *__tocode, const char *__fromcode);/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard #endif /* __ICONV_LOADED */wwA-ԗ#ifndef __IF_LOADED#define __IF_LOADED 1M/******************************************************************************>** - Structures providing a packet transport mechanism**M******************************************************************************* Header is nonstandardM*****************************************************************************I**  I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M*******************************************************************************E** Copyright (c) 1982, 1993 Regents of the University of California.A** All rights reserved. The Berkeley software License Agreement:** specifies the terms and conditions for redistribution.**/** if.h 8.1 (Berkeley) 6/10/93**N*******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#include #include #include #include #if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*7** Set __nomember_alignment to avoid internal and tail2** padding in structures; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment/*$** External model of relaxed refdef*/#pragma __extern_model __save'#pragma __extern_model __relaxed_refdef/*** Public typedefs*/0#if !defined __U_INT && !defined _DECC_V4_SOURCE# define __U_INT typedef unsigned int u_int;#endif/*> * Structures defining a network interface, providing a packet: * transport mechanism (ala level 0 of the PUP protocols). *A * Each interface accepts output datagrams of a specified maximumB * length, and provides higher level routines with input datagrams * received from its medium. *L * Output occurs when the routine if_output is called, with four parameters:% * (*ifp->if_output)(ifp, m, dst, ro )J * Here m is the mbuf chain to be sent and dst is the destination address.F * The output routine encapsulates the supplied datagram if necessary,' * and then transmits it on its medium. *G * On input, each interface unwraps the data received by it, and eitherB * places it on the input queue of a internetwork datagram routineO * and posts the associated software interrupt, or passes the datagram to a raw * packet input routine. *< * Routines exist for locating interfaces by their addressesL * or for locating a interface on a certain network, as well as more generalF * routing and gateway routines maintaining information used to locateA * interfaces. These routines live in the files if.c and route.c *//* forward decls for C++ */#ifdef __cplusplus struct mbuf;struct ifaddr;struct ifmulti;struct rtentry;struct ifafilt;#endif/*6 * Structure defining a queue for a network interface. */struct ifqueue {' struct mbuf *ifq_head;' struct mbuf *ifq_tail; int ifq_len;# int ifq_maxlen;" int ifq_drops;};/** * Structure defining a network interface. */struct ifnet {/* 64-byte alignment */L struct ifnet *if_next; /* the next structure in the list */I char *if_name; /* name, e.g. ``en'' or ``lo'' */M char *if_version; /* The version string. */B struct sockaddr if_addr; /* address of interface */F int if_flags; /* up/down, broadcast, etc. */I int if_pfactive; /* interface-specific pfactive */M short if_unit; /* sub-unit for lower level driver */J u_short if_mtu; /* maximum IP transmission unit */F u_short if_mediamtu; /* maximum MTU of the media */J short if_timer; /* time 'til if_watchdog called */L  int if_metric; /* routing metric (external only) */ int pad_a[1];/* 64-byte alignment */M struct ifaddr *if_addrlist; /* linked list of addresses per if */M E struct ifmulti *if_multiaddrs; /* list of multicast addrs */O int if_multicnt; /* number of multicast addrs in list */I int if_allmulticnt; /* number of allmulti requests *//* procedure handles */V int (*if_init)(int); /* init routine */; int (*if_output)(struct ifnet *, struct mbuf *,p struct sockaddr *, struct rtentry *, __caddr_t); /* output routine (enqueue) */a int (*if_start)(struct ifnet *); /* initiate output routine */a int (*if_done)(struct ifnet *); /* output complete routine */Y  int (*if_ioctl)(struct ifnet *, unsigned int, __caddr_t); /* ioctl routine *//* 64-byte alignment */[ int (*if_reset)(int, int); /* bus reset routine */W int (*if_watchdog)(int, struct ifnet *); /* timer routine */C void *drvr_softc; /* ptr to driver's softc */E long if_reserved[5]; /* reserved for future use *//* 64-byte alignment */"/* generic interface statistics */K  u_long if_ipackets; /* packets received on interface */G u_long if_ierrors; /* input errors on interface */G u_long if_opackets; /* packets sent on interface */H u_long if_oerrors; /* output errors on interface */K u_long if_collisions; /* collisions on csma interfaces */C u_long if_sysid_type; /* MOP SYSID device code *//* SNMP statistics */: struct timeval if_lastchange; /* last updated */M u_long if_ibytes; /* total number of octets received */I u_long if_obytes; /* total number of octets sent */L u_long if_imcasts; /* packets received via multicast */H u_long if_omcasts; /* packets sent via multicast */N u_long if_iqdrops; /* dropped on input, this interface */O u_long if_noproto; /* destined for unsupported protocol */7 u_lo ng if_baudrate; /* linespeed */G u_long if_imbytes; /* multicast octets received */C u_long if_ombytes; /* multicast octets sent *//* end statistics *//* 64-byte alignment */F u_char if_type; /* ethernet, tokenring, etc */B u_char if_addrlen; /* media address length */A u_char if_hdrlen; /* media header length */H u_char if_initialized; /* ifnet has been in!itialized */N __u_int if_index; /* numeric abbreviation for this if */a int if_trustgrp; /* Interface trustgrp (see below) for FIREWALL product */O int if_affinity; /* which CPU to run on (master, all) */E struct ifafilt *if_afilt; /* interface access filter */R struct ifnet *if_nrnext; /* Flink in NetRAIN set - circular list */N struct ifnet *if_nrif; /* Back link to netrain virtual if "p */P u_short if_alloc_size; /* size structure if_alloc() alloc'ed */> u_short if_padb[1]; /* unused - padding */F int if_rad_id; /* RAD this interface is in */O __caddr_t if_arp_cache_head; /* pointer to this ifnet's ARP cache */> __u_int if_padc[2]; /* unused - padding *//* 64-byte alignment */: struct ifqueue if_snd; /* output queue *//* 64-byte alignment */#if SEC_NET # struct tnet_if *if_sec;)# define SEC_IFF_LOADING 0x10000000#endif /* SEC_NET */ u_short ovms_if_sts; u_short ovms_if_pad; u_short ovms_if_size; u_char ovms_if_type; u_char ovms_if_iftype;#define IF_LOCAL 0! __u_int ovms_if_eth_name;" u_short ovms_if_react_att;# u_short ovms_if_succ_react; __u_int ovms_if_cluster;# __u_int ovms_if_clust_tcps;) __u_int ovms_if_cluster_timer_id;! $ u_char ovms_if_lock[24]; u_char *ovms_vcib_ip; u_char *ovms_vcib_arp; u_char *ovms_vcib_ipv6;* __u_int if_ovms_outstanding_xmits;};*#define IFF_UP 0x1 /* interface is up */8#define IFF_BROADCAST 0x2 /* broadcast address valid */.#define IFF_DEBUG 0x4 /* turn on debugging */1#define IFF_LOOPBACK 0x8 /* is a loopback net */D#define IFF_POINTOPOINT 0x10 /* interface is point-to-point link */8#define IFF_NOTRAILERS 0x20 /* avoid use of tra %ilers */3#define IFF_RUNNING 0x40 /* resources allocated */<#define IFF_NOARP 0x80 /* no address resolution protocol */4#define IFF_PROMISC 0x100 /* receive all packets */?#define IFF_ALLMULTI 0x200 /* receive all multicast packets */5#define IFF_MULTICAST 0x400 /* supports multicast */=#define IFF_SIMPLEX 0x800 /* can't hear own transmissions */:#define IFF_OACTIVE 0x1000 /* transmission in progress */M#define IFF_PFCOPYALL 0x2000 /* pfilt gets packets to this host */+&#define IFF_UIOMOVE 0x10000 /* DART */+#define IFF_PKTOK 0x20000 /* DART */+#define IFF_SOCKBUF 0x40000 /* DART */C#define IFF_VAR_MTU 0x80000 /* interface supports variable MTUs */N#define IFF_NOCHECKSUM 0x100000 /* no checksums need reliable media */O#define IFF_DYNPROTO 0x200000 /* Support dynamic proto dispatching */@#define IFF_MOP 0x400000 /* Device in MOP mode */G#define IFF_SLIP 0x800000 /* Interface is a SLIP IFNET * '/N#define IFF_DELETE 0x1000000 /* Started DELETE on this interface */O#define IFF_NONAME 0x2000000 /* Interf does not hold cluster name */J#define IFF_CLUSTER 0x4000000 /* Interface is a cluster IFNET */K#define IFF_MULTINET 0x8000000 /* Multiple network on interface */a#define IFF_QUORUMLOSS 0x10000000 /* UP interface marked DOWN due to cluster quorum loss */P#define IFF_VMIFNET 0x20000000 /* Used to identify a virtual Mac Addr*/O#d (efine IFF_CLUIF 0x40000000 /* interface is cluster interconnect */C#define IFF_DETACHED 0x80000000 /* interface is detached *//* Device-specific flags */#define IFF_D1 0x8000#define IFF_D2 0x4000?#define IFF_SNAP IFF_D1 /* Ethernet driver outputs SNAP hdr */ /* flags set internally only: */#define IFF_CANTCHANGE \@ (IFF_BROADCAST|IFF_POINTOPOINT|IFF_SIMPLEX|IFF_RUNNING|\E IFF_OACTIVE|IFF_MULTICAST|IFF_UIOMOVE|IFF_PKTOK|IFF_SOCKBUF|\ )IFF_VAR_MTU|IFF_CLUIF)B/* interface types for benefit of parsing media address headers */H/* interface trust groups for network security (aka FIREWALL) product */F#define IFG_ANY 0x0 /* for screend; matches any */?#define IFG_UNKNOWN 0x1 /* currently unknown */?#define IFG_INFRARED 0x2 /* Totally untrusted */?#define IFG_RED 0x3 /* ^ */?#define IFG_ORANGE 0x4 /* : */? *#define IFG_YELLOW 0x5 /* v */?#define IFG_GREEN 0x6 /* Somewhat trusted */?#define IFG_BLUE 0x7 /* ^ */?#define IFG_INDIGO 0x8 /* : */?#define IFG_VIOLET 0x9 /* v */?#define IFG_ULTRAVIOLET 0xa /* Totally trusted */L#define IFG_MAX 0xa /* Current max.; expand as needed */#define IFQ_LOCKINIT(ifq)#d+efine IFQ_LOCKTERMINATE(ifq) #define IFQ_LOCKINIT_SPLIMP(ifq) #define IFQ_LOCKINIT_SPLNET(ifq)!#define IFQ_LOCKINIT_SPLNONE(ifq)#define IFQ_LOCK(ifq)#define IFQ_UNLOCK(ifq)/*L * Output queues (ifp->if_snd) and internetwork datagram level (pup level 1)F * input routines have queues of messages stored on ifqueue structuresK * (defined above). Entries are added to and deleted from these structuresG * by these macros, which should be called with ipl raised to splimp(). */E#define ,IF_QFULL(ifq) ((ifq)->ifq_len >= (ifq)->ifq_maxlen)4#define IF_DROP(ifq) ((ifq)->ifq_drops++)%#define IF_ENQUEUE_NOLOCK(ifq, m) { \ (m)->m_nextpkt = 0; \# if ((ifq)->ifq_tail == 0) \& (ifq)->ifq_head = m; \ else \1 (ifq)->ifq_tail->m_nextpkt = m; \ (ifq)->ifq_tail = m; \ (ifq)->ifq_len++; \}#define IF_ENQUEUE(ifq, m) { \ IFQ_LOCK(ifq); \$ IF_ENQUEUE_NOLOCK(ifq, m); \ -IFQ_UNLOCK(ifq); \}%#define IF_PREPEND_NOLOCK(ifq, m) { \+ (m)->m_nextpkt = (ifq)->ifq_head; \# if ((ifq)->ifq_tail == 0) \( (ifq)->ifq_tail = (m); \ (ifq)->ifq_head = (m); \ (ifq)->ifq_len++; \}#define IF_PREPEND(ifq, m) { \ IFQ_LOCK(ifq); \$ IF_PREPEND_NOLOCK(ifq, m); \ IFQ_UNLOCK(ifq); \}%#define IF_DEQUEUE_NOLOCK(ifq, m) { \ (m) = (ifq)->ifq_head; \ if (m) { \> if (((ifq).->ifq_head = (m)->m_nextpkt) == 0) \. (ifq)->ifq_tail = 0; \% (m)->m_nextpkt = 0; \# (ifq)->ifq_len--; \ } \}#define IF_DEQUEUE(ifq, m) { \ IFQ_LOCK(ifq); \$ IF_DEQUEUE_NOLOCK(ifq, m); \ IFQ_UNLOCK(ifq); \}#define IFQ_MAXLEN 1024E#define IFNET_SLOWHZ 1 /* granularity is 1 second *//*> * The ifaddr structure contains information about one addressK * of an interface. / They are maintained by the different address families,D * are allocated and attached when an address is set, and are linked= * together so all addresses for an interface can be located. */struct ifaddr {6 struct sockaddr *ifa_addr; /* address of interface */= struct sockaddr *ifa_dstaddr; /* other end of p-to-p link */C#define ifa_broadaddr ifa_dstaddr /* broadcast address interface */= struct sockaddr *ifa_netmask; /* used to determine subnet */8 struct ifnet *ifa_ifp; /* back-poi 0nter to interface */: struct ifaddr *ifa_next; /* next address for interface */' /* check or clean routes (+ or -)'d */B void (*ifa_rtrequest) (int, struct rtentry *, struct sockaddr *);0 struct rtentry *ifa_rt; /* ??? for ROUTETOIF */6 u_short ifa_flags; /* mostly rt_flags for cloning */K u_short ifa_llinfolen; /* extra to malloc for link info */% __u_int ifa_refcnt; /* ref count */};/#define IFA_ROUTE RTF_UP /* route installed */:#define IFA_ARPDISABLED RTF_REJECT 1 /* ARP disabled *//*. * Interface request structure used for socket6 * ioctl's. All interface ioctl's must have parameter. * definitions which begin with ifr_name. The' * remainder may be interface specific. */struct ifreq {#define IFNAMSIZ 164 char ifr_name[IFNAMSIZ]; /* if name, e.g. "en0" */ union { struct sockaddr ifru_addr; struct sockaddr ifru_dstaddr;! struct sockaddr ifru_broadaddr; int ifru_flags; int ifru_metric; __caddr_t ifru_data;* int ifru 2_value; /* any generic value */ __u_int ifru_index;#if SEC_NET* struct tnet_if *ifru_sec;D#define ifr_sec ifr_ifru.ifru_sec /* tnet interface */#endif /* SEC_NET */ } ifr_ifru; #define IF_NAMESIZE IFNAMSIZ1#define ifr_addr ifr_ifru.ifru_addr /* address */H#define ifr_dstaddr ifr_ifru.ifru_dstaddr /* other end of p-to-p link */E#define ifr_broadaddr ifr_ifru.ifru_broadaddr /* broadcast address */1#define ifr_flags ifr_ifru.ifru_flags 3/* flags */4#define ifr_metric ifr_ifru.ifru_metric /* metric */>#define ifr_data ifr_ifru.ifru_data /* for use by interface */@#define ifr_value ifr_ifru.ifru_value /* for use by interface */;#define ifr_index ifr_ifru.ifru_index /* interface index */};/*; * structure used to query de and qe for physical addresses */struct ifdevea {I char ifr_name[IFNAMSIZ]; /* if name, e.g. "en0" */N u_char default_pa[6]; /* default hardware addres4s */N u_char current_pa[6]; /* current physical address */};struct ifaliasreq {5 char ifra_name[IFNAMSIZ]; /* if name, e.g. "en0" */ struct sockaddr ifra_addr; struct sockaddr ifra_broadaddr; struct sockaddr ifra_mask;};/*: * Request struct to create interface access filters. Used * in SIOCSIFAFILT requests. */struct ifafiltreq {A char ifafr_name[IFNAMSIZ]; /* if name, e.g. "en0" */? __u_int ifafr_cnt; /* num5ber of entries */A struct ifafilt *ifafr_filt; /* user-defined filter */};/*8 * Interface access filter. Filter is variable length as7 * specified by user's ifafiltreq. Filter allocated via9 * NET_MALLOC; one valid filter per interface; new filter * outdates existing filter. * ; * Filter entrys contain {addr, mask, action}. {addr, mask}7 * combine to filter packets; {action} gives action for8 * matching packets. "cnt" is reference count for number< * of hits per fil6ter entry. Filtering is protocol-specific;6 * see netinet/{in,ip_input}.c for IP-style filtering. */struct ifafilt {& struct sockaddr ifaf_addr; /* addr */& struct sockaddr ifaf_mask; /* mask */# __u_int ifaf_action; /* action */! __u_int ifaf_cnt; /* counter */};#define IFAF_PERMIT 0x1#define IFAF_DENY 0x2#define IFAF_DENYLOG 0x4/* * IFAF_MAXBUFSIZE = 32KbytesA * IFAF_MAXENTRIES = (IFAF_MAXBUFSIZE/sizeof(struct ifafilt)) - 2 */#define IFAF_MAXBUFSIZE 0x8000#d7efine IFAF_MAXENTRIES 0x331/*) * Structure used in SIOCGIFCONF request.+ * Used to retrieve interface configuration) * for machine (useful for programs which& * must know all networks accessible). */struct ifconf {. int ifc_len; /* size of associated buffer */ union { __caddr_t ifcu_buf; struct ifreq *ifcu_req; } ifc_ifcu;6#define ifc_buf ifc_ifcu.ifcu_buf /* buffer address */D#define ifc_req ifc_ifcu.ifcu_req /* array of structures returned */};/*I * Interfa 8ce multicast address structure. There is one of these for eachI * multicast address or range of multicast addresses that we are supposedK * to listen to on a particular interface. They are kept in a linked list,/ * rooted in the interfaces's ifnet structure.  */struct ifmulti {; u_char ifm_addrlo[6]; /* low or only address of range */; u_char ifm_addrhi[6]; /* high or only address of range */5 struct ifnet *ifm_ifnet; /* back pointer to ifnet */; __u_int ifm_refcount; /* no. c 9laims to this addr/range */4 struct ifmulti *ifm_next; /* ptr to next ifmulti */};/*G * Structure for EEPROM downline upgrades. (Supported by FDDI adapters) */struct ifeeprom {J char ife_name[IFNAMSIZ]; /* if name, e.g. "fza0" */J u_char ife_data[64]; /* block of EEPROM data */K __u_int ife_offset; /* byte offset from base */I __u_int ife_blklen; /* len of EEPROM block */H : __u_int ife_lastblk; /* True if last block */};H#define IFE_NOTLAST 0x0 /* Intermediary block of EEPROM image */@#define IFE_LASTBLOCK 0x1 /* Last block of EEPROM image */J#define IFE_SUCCESS 0x0 /* Block of EEPROM successfully written */>#define IFE_RETRY 0x1 /* Retry last block written */M#define IFE_FAIL 0x2 /* Fail entire EEPROM image write sequence *//*. * Structure for set adapter's characteristics */struct ifchar ;{ char ifc_name[IFNAMSIZ]; __u_int ifc_treq; __u_int ifc_tvx; __u_int ifc_lem; __u_int ifc_rtoken; __u_int ifc_ring_purger;8 __u_int ifc_cnt_interval; /* Not applicable to DEFZA */#define FDX_ENB 1#define FDX_DIS 28 int ifc_full_duplex_mode; /* Not applicable to DEFZA */ int ifc_media_speed; int ifc_media_type;#define AUTO_ENB 1#define AUTO_DIS 2 int ifc_auto_sense;};/*A * We pass extra options (defined in lan_common.h) by overloading *< the ifc_media_type field. */(#define ifc_extra_options ifc_media_type/*" * interface statistics structures */5struct estat { /* Ethernet interface statistics */6 u_short est_seconds; /* seconds since last zeroed */, __u_int est_bytercvd; /* bytes received */( __u_int est_bytesent; /* bytes sent */2 __u_int est_blokrcvd; /* data blocks received */. __u_int est_bloksent; /* data blocks sent */7 __u_int est_mbytercvd; /* multicast bytes received */8 __u_int est_mblokrcvd; = /* multicast blocks received */= __u_int est_deferred; /* blocks sent, initially deferred */9 __u_int est_single; /* blocks sent, single collision */> __u_int est_multiple; /* blocks sent, multiple collisions */8 u_short est_sendfail_bm; /* 0 - Excessive collisions */# /* 1 - Carrier check failed */ /* 2 - Short circuit */ /* 3 - Open circuit */ /* 4 - Frame too long */& /* 5 - Remote failure to defer */5 u_short est_sendfail; /* send failures: (bit map)*/: > u_short est_collis; /* Collision detect check failure */5 u_short est_recvfail_bm; /* 0 - Block check error */ /* 1 - Framing error */ /* 2 - Frame too long */8 u_short est_recvfail; /* receive failure: (bit map) */; u_short est_unrecog; /* unrecognized frame destination */) u_short est_overrun; /* data overrun */5 u_short est_sysbuf; /* system buffer unavailable */4 u_short est_userbuf; /* user buffer unavailable */3 __u_int est_mbytesent; /* multicast bytes sent */4 ? __u_int est_mbloksent; /* multicast blocks sent */};Mstruct estat_extended { /* 64-bit Ethernet interface stats */G u_long est_seconds; /* seconds since last zeroed */$ /* xmit stats: successful */8 u_long est_bytesent; /* bytes sent */B u_long est_bloksent; /* blocks (frames) sent */B u_long est_mbytesent; /* multicast bytes sent */L u_long est_mbloksent; /* multicast blo @cks (frames) sent */@ u_long est_deferred; /* initially deferred */9 u_long est_single; /* 1 collision */: u_long est_multiple; /* >1 collision */ /* xmit stats: failed */M u_long est_collis; /* collision detect check failures */E u_long est_unrecog; /* unrecognized frame dest */E u_long est_userbuf; /* user buffer unavailable */= u_long est_latecoll; A /* late collisions */B u_long est_excesscoll; /* excessive collisions */@ u_long est_carrierfail; /* carrier sense lost */; u_long est_shortcirc; /* short circuit */: u_long est_opencirc; /* open circuit */< u_long est_sndlong; /* frame too long */A u_long est_sendfail; /* total send failures */$ /* recv stats: successful */< u_long est_bytercvd; /* bytes r Beceived */F u_long est_blokrcvd; /* blocks (frames) received */F u_long est_mbytercvd; /* multicast bytes received */L u_long est_mblokrcvd; /* multicast blocks (frames) rcvd */ /* recv stats: failed */; u_long est_overrun; /* data overruns */G u_long est_sysbuf; /* system buffer unavailable */= u_long est_unaligned; /* unaligned frame */< u_long est_longframe; C /* frame too long */= u_long est_shortframe; /* frame too short */I u_long est_fcsfail; /* frame check sequence errors */9 u_long est_badframe; /* frame error */I u_long est_symbolerror; /* symbol error during carrier */D u_long est_recvfail; /* total receive failures */9 /* padding for the future, but must fit in ctrreq! * (512 - 248) / 8 = 33 */ u_long padd Ding[33];};;struct dstat { /* DDCMP pt-to-pt interface statistics */6 u_short dst_seconds; /* seconds since last zeroed */, __u_int dst_bytercvd; /* bytes received */( __u_int dst_bytesent; /* bytes sent */3 __u_int dst_blockrcvd; /* data blocks received *// __u_int dst_blocksent; /* data blocks sent */9 u_short dst_inbound_bm; /* 0 - NAKs sent, header crc */" /* 1 - NAKs sent, data crc */& /* 2 - NAKs sent, REP response */: u_char dst_inbound; /* data errors inbound E: (bit map) */9 u_short dst_outbound_bm; /* 0 - NAKs rcvd, header crc */" /* 1 - NAKs rcvd, data crc */& /* 2 - NAKs rcvd, REP response */< u_char dst_outbound; /* data errors outbound: (bit map) */3 u_char dst_remotetmo; /* remote reply timeouts */1 u_char dst_localtmo; /* local reply timeouts */B u_short dst_remotebuf_bm; /* 0 - NAKs rcvd, buffer unavailable */* /* 1 - NAKs rcvd, buffer too small */= u_char dst_remotebuf; /* remote buffer errors: (bit map) */A u_short d Fst_localbuf_bm; /* 0 - NAKs sent, buffer unavailable */* /* 1 - NAKs sent, buffer too small */; u_char dst_localbuf; /* local buffer errors: (bit map) */6 u_char dst_select; /* selection intervals elapsed */7 u_short dst_selecttmo_bm; /* 0 - No reply to select */) /* 1 - Incomplete reply to select */; u_char dst_selecttmo; /* selection timeouts: (bit map) */? u_short dst_remotesta_bm; /* 0 - NAKs rcvd, receive overrun */' /* 1 - NAKs sent, header format */$ /* 2 - SeGlect address errors */$ /* 3 - Streaming tributaries */> u_char dst_remotesta; /* remote station errors: (bit map) */> u_short dst_localsta_bm; /* 0 - NAKs sent, receive overrun */, /* 1 - Receive overrun, NAK not sent */! /* 2 - Transmit underruns */' /* 3 - NAKs rcvd, header format */< u_char dst_localsta; /* local station errors: (bit map) */};struct fstat {G u_short fst_second; /* seconds since last zeroed */7 __u_int fst_frame; /* total nu Hmber of frames seen */ 2 __u_int fst_error; /* MAC counter frame error */1 __u_int fst_lost; /* MAC counter frame count */< __u_int fst_bytercvd; /* bytes received */8 __u_int fst_bytesent; /* bytes sent */B __u_int fst_pdurcvd; /* data blocks received */> __u_int fst_pdusent; /* data blocks sent */F __u_int fst_mbytercvd; /* multicast bytes received */@ __u_int fst_mpdurcvd; /* multicast blocks I received */B __u_int fst_mbytesent; /* multicast bytes sent */C __u_int fst_mpdusent; /* multicast blocks sent */5 u_short fst_underrun; /* transmit underrun error */E u_short fst_sendfail; /* sent failures: (bit map)*/6 u_short fst_fcserror; /* FCS check failure */0 u_short fst_fseerror; /* frame status error */2 u_short fst_pdualig; /* frame alignment error */. u_short fst_pdulen; /* frame length error */2 u_short fst_pduunre Jcog; /* frame unrecognized */< u_short fst_mpduunrecog; /* multicast frame unrecognized */: u_short fst_overrun; /* data overrun */G u_short fst_sysbuf; /* system buffer unavailable */E u_short fst_userbuf; /* user buffer unavailable */@ u_short fst_ringinit; /* other station ring reinit. intiated*/? u_short fst_ringinitrcv; /* ring reinitialization initiated */= u_short fst_ringbeacon; /* ring beacon process initiated */; u_short f Kst_ringbeaconrecv; /* ring beacon process recv */5 u_short fst_duptoken; /* duplicat token detected */? u_short fst_dupaddfail; /* duplicate address test failures */0 u_short fst_ringpurge; /* ring purge errors */3 u_short fst_bridgestrip; /* bridge strip errors *// u_short fst_traceinit; /* traces initiated */. u_short fst_tracerecv; /* traces received */- u_short fst_lem_rej; /* LEM reject count */0 u_short fst_lem_events; /* LEM events count */- u_short fst_lct_rej; /* LCT reLject count */8 u_short fst_tne_exp_rej; /* TNE expired reject count */: u_short fst_connection; /* Completed Connection count */7 u_short fst_ebf_error; /* Elasticity Buffer Errors */};/*0 * Same fields as "struct fstat", but all u_long */struct fstat_extended {G u_long fst_second; /* seconds since last zeroed */I u_long fst_frame; /* total number of frames seen */E u_long fst_error; /* MAC counter frame error */EM u_long fst_lost; /* MAC counter frame count */< u_long fst_bytercvd; /* bytes received */8 u_long fst_bytesent; /* bytes sent */B u_long fst_pdurcvd; /* data blocks received */> u_long fst_pdusent; /* data blocks sent */F u_long fst_mbytercvd; /* multicast bytes received */G u_long fst_mpdurcvd; /* multicast blocks received */B u_long fst_mbytesent; N /* multicast bytes sent */C u_long fst_mpdusent; /* multicast blocks sent */E u_long fst_underrun; /* transmit underrun error */A u_long fst_sendfail; /* total send failures */? u_long fst_fcserror; /* FCS check failure */@ u_long fst_fseerror; /* frame status error */C u_long fst_pdualig; /* frame alignment error */@ u_long fst_pdulen; /* frame length error O*/@ u_long fst_pduunrecog; /* frame unrecognized */J u_long fst_mpduunrecog; /* multicast frame unrecognized */: u_long fst_overrun; /* data overrun */G u_long fst_sysbuf; /* system buffer unavailable */E u_long fst_userbuf; /* user buffer unavailable */P u_long fst_ringinit; /* other station ring reinit. intiated*/M u_long fst_ringinitrcv; /* ring reinitialization initiatPed */K u_long fst_ringbeacon; /* ring beacon process initiated */F u_long fst_ringbeaconrecv; /* ring beacon process recv */E u_long fst_duptoken; /* duplicat token detected */M u_long fst_dupaddfail; /* duplicate address test failures */? u_long fst_ringpurge; /* ring purge errors */A u_long fst_bridgestrip; /* bridge strip errors */> u_long fst_traceinit; /* traces initiated */ Q= u_long fst_tracerecv; /* traces received */> u_long fst_lem_rej; /* LEM reject count */> u_long fst_lem_events; /* LEM events count */> u_long fst_lct_rej; /* LCT reject count */F u_long fst_tne_exp_rej; /* TNE expired reject count */H u_long fst_connection; /* Completed Connection count */F u_long fst_ebf_error; /* Elasticity Buffer Errors */};/*  * FDDI MIB structRures  *//* SMT group */struct fddismt {1 short smt_number; /* SMT number */, short smt_index; /* SMT FDDI SMT index */ 0 u_char smt_stationid[8]; /* FDDI station id */ 4 u_short smt_opversionid; /* operation version id */2 u_short smt_hiversionid; /* highest version id */1 u_short smt_loversionid; /* lowest version id */( short smt_macct; /* number of MACs */7 short smt_nonmasterct; /* number of non master port */1 short smt_masterct; /* number of master port S */3 short smt_pathsavail; /* available path type */7 short smt_configcap; /* configuration capabilities */3 short smt_configpolicy; /* configuration policy */3 u_short smt_connectpolicy; /* connection policy */? u_short smt_timenotify; /* neighbor notification prot. time*/8 short smt_statusreport; /* status reporting protocol */6 short smt_ecmstate; /* state of ECM state machine */# short smt_cfstate; /* CF_state */; short smt_holdstate; /* current state of Hold function */< T short smt_remotedisconn; /* remotely disconnection flag */ ; u_char smt_msgtimestamp[8]; /* timestamp for SMT frames */< u_char smt_trantimestamp[8]; /* timestamp for last event */< u_char smt_setinfo[12]; /* station last parameter change */6 u_char smt_lastsetid[8]; /* Last station ID change */, short smt_action; /* SMT station action */}; B/*--------------------------------------------------------------*/ /* */;/* FDDI Station/Link/Physical Port Attributes & Status: */ /* U */8/* defined by the DNA-FDDI Data Link Functional Spec */"/* version 1.0.1 chapter 5. */ /* */C/*--------------------------------------------------------------*/ struct fddi_dna_attributes { /* STATION Attributes */- u_char stationid[8]; /* FDDI station id */ . short stationtype; /* FDDI station type */1 u_short opversionid; /* operation version id *// u_short hiversionid; /* highest version id */. u_short loversionid; /* lowest version id */ /* LIVNK Attributes */* u_char link_addr[6]; /* LINK address */# __u_int t_req; /* TRT request */- __u_int tvx; /* Valid Transmission time */8 __u_int rtoken_timeout; /* restricted token timeout */2 short ring_purge_enable; /* ring purger enable */ /* PHY Attributes */ ! u_char phy_type; /* PHY type */! u_char pmd_type; /* PMD type */4 __u_int lem_threshold; /* lem threshold */};struct fddi_dna_status { /* STATION Status */, short station_state; /* stWation state */5 u_char laststationid[8]; /* Last FDDI station id */ + u_char station_uid[8]; /* station uid */  /* LINK Status */& short link_state; /* LINK state */% u_char link_uid[8]; /* link uid */ ' __u_int neg_trt; /* Negotiated TRT */4 short dup_add_flag; /* duplicate address flag */. u_char upstream[6]; /* Upstream Neighbor */5 u_char oldupstream[6]; /* Old Upstream Neighbor */E short upstreamdaf; /* Upstream Neighbor duplicate address flag */2 u_char dow Xnstream[6]; /* Downstream Neighbor */8 u_char olddownstream[6]; /* Old Downstream Neighbor */1 short ring_purge_state; /* ring purge state */1 u_char frame_strip_mode; /* frame strip mode */- u_char ring_error; /* ring error reasons */2 short loopback; /* loopback mode - true/false */< short ring_latency; /* currently measured ring latency */6 u_char ring_purge_addr[6]; /* ring purger address */  /* PHY Status */) u_char phy_state; /* Physical state */# u_char phy_uid[8]Y; /* phy uid */ 3 u_char neighbor_phy_type; /* Neighborshort */ 7 __u_int phy_link_error; /* phy link error estimate */5 u_char broken_reason; /* phy port broken reason */) u_char rej_reason; /* reject reason */};struct fddiDNA_status {! struct fddi_dna_attributes attr; struct fddi_dna_status stat; }; struct fstatus {" short led_state; /* LED State */$ short rmt_state; /* RMT state */& short link_state; /* LINK state */4 short dup_add_test; /* dupli Zcate address test */1 short ring_purge_state; /* ring purge state */' __u_int neg_trt; /* Negotiated TRT */. u_char upstream[6]; /* Upstream Neighbor */2 u_char downstream[6]; /* downstream Neighbor */0 u_char una_timed_out; /* una timed out flag */1 u_char frame_strip_mode; /* frame strip mode */6 u_char claim_token_mode; /* claim token yield mode */) u_char phy_state; /* Physical state */3 u_char neighbor_phy_type; /* Neighborshort */ ) u_char rej_reason; /* reject re [ason */7 __u_int phy_link_error; /* phy link error estimate */- u_char ring_error; /* ring error reasons */# __u_int t_req; /* TRT request */ __u_int tvx; /* TVX value */# __u_int t_max; /* TRT maximum */; __u_int lem_threshold; /* lem threshold */8 __u_int rtoken_timeout; /* restricted token timeout */, u_char fw_rev[4]; /* firmware revision */) u_char phy_rev[4]; /* ROM revision */ ! u_char pmd_type; /* PMD type */9 u_char dir_beacon[6]; /* Last D\irect Beacon address */& short smt_version; /* SMT version */% short state; /* Adapter State */B u_char dir_beacon_una[6]; /* UNA from last direct beacon addr. */; short cnt_interval; /* Interval to get counter updates */= short full_duplex_mode; /* enabling/disabling duplex mode */1 short full_duplex_state; /* state, if enabled */}; /* MAC group */struct fddimac {1 short mac_number; /* MAC number */, short mac_smt_index; /* MAC SMT index */$ short m ]ac_index; /* MAC index */4 short mac_fsc; /* MAC frame status capabilities */: __u_int mac_gltmax; /* Greastest lower bound of T_max */7 __u_int mac_gltvx; /* Greastest lower bound of TVX */- short mac_paths; /* path types available */: short mac_current; /* association of the MAC with path*/0 u_char mac_upstream[6]; /* upstream neighbor */< u_char mac_oldupstream[6]; /* previous upstream neighbor */4 short mac_dupaddrtest; /* duplicate address test */- short mac_pathsreq; /* paths ^ requested */3 short mac_downstreamtype; /* downstream PC-type */4 u_char mac_smtaddress[6]; /* MAC address for SMT */" __u_int mac_treq; /* TRT time */' __u_int mac_tneg; /* Neg. TRT time */' __u_int mac_tmax; /* max. TRT time */" __u_int mac_tvx; /* TVX value */' __u_int mac_tmin; /* min. TRT time */2 short mac_framestatus; /* current frame status */' int mac_counter; /* frame counters */+ int mac_error; /* frame error counters */( int mac_lost; /* frame lost counter */1 s_hort mac_rmtstate; /* Ring Management state */1 short mac_dupaddr; /* duplicate address flag */* short mac_condition; /* MAC condition */& short mac_action; /* MAC action */< short mac_updupaddr; /* upstream duplicate address flag */: short mac_frame_error_thresh; /* frame error threshold */6 short mac_frame_error_ratio; /* frame error ratio */- short mac_chip_set; /* the chip set used */};/* PATH group */struct fddipath {7 short path_configindex; /* path configuration i`ndex */ short path_type;  short path_portorder; 9 __u_int path_sba; /*synchronous bandwidth allocation*/ + short path_sbaoverhead; /* SBA overhead */& short path_status; /* path status */};/* PORT group */struct fddiport {2 short port_number; /* port number */, short port_smt_index; /* port SMT index */$ short port_index; /* port index */6 short port_pctype; /* value of the port's PC_type */7 short port_pcneighbor; /* PC_neighbor of remote port*/3 sho art port_connpolicy; /* connection policies */2 short port_remoteind; /* remote MAC indicated */8 short port_CEstate; /* Current Configuration state */* short port_pathreq; /* path request */, u_short port_placement; /* upstream MAC */- short port_availpaths; /* available paths */6 __u_int port_looptime; /* time for MAC loval loop */" __u_int port_TBmax; /* TB_max */3 short port_BSflag; /* the Break state, BF_flag */> __u_int port_LCTfail; /* counter for Link confidence test */ b/ short port_LerrEst; /* Link error estimate */1 __u_int port_Lemreject; /* Link reject count */2 __u_int port_Lem; /* Link error monitor count */8 short port_baseLerEst; /* value of port Ler Estimate */0 __u_int port_baseLerrej; /* Ler reject count */' __u_int port_baseLer; /* Ler count */1 u_char port_baseLerTime[8]; /* Ler timestamp */ 8 short port_Lercutoff; /* error rate cut off limit */8 short port_alarm; /* error rate cause alarm generate*/- short port_connectstate; /* concnect state */( short port_PCMstate; /* PCM state */) short port_PCwithhold; /* PC_withhold */< short port_Lercondition; /* true if Ler-Est <= Ler_alarm */( short port_action; /* PORT action */* short port_chip_set; /* PORT chip set */};/* Attachment group */struct fddiatta {6 short atta_number; /* attachment number */3 short atta_smt_index; /* attachment SMT index */+ short atta_index; /* attachment index */* short atta_class; /* attachment class */5 shodrt atta_bypass; /* attachment optical bypass */ > short atta_IMaxExpiration; /* attachment I_Max Expiration */ 2 short atta_InsertedStatus; /* Inserted status */ . short atta_InsertPolicy; /* Insert policy */ };1 /* Information here is conformant to SMT 7.2 */ /* SMT GROUP */struct smtmib_smt { u_char smt_station_id[8]; __u_int smt_op_version_id; __u_int smt_hi_version_id; __u_int smt_lo_version_id; u_char smt_user_data[32]; __u_int semt_mib_version_id; __u_int smt_mac_ct; __u_int smt_non_master_ct; __u_int smt_master_ct;! __u_int smt_available_paths;% __u_int smt_config_capabilities; __u_int smt_config_policy;# __u_int smt_connection_policy; __u_int smt_t_notify;! __u_int smt_stat_rpt_policy;& __u_int smt_trace_max_expiration; __u_int smt_bypass_present; __u_int smt_ecm_state; __u_int smt_cf_state;( __u_int smt_remote_disconnect_flag; __u_int f smt_station_status; __u_int smt_peer_wrap_flag;#if !defined __VAX5 u_long smt_msg_time_stamp; /* 64 bit counter */< u_long smt_transition_time_stamp; /* 64 bit counter */#else8 __u_int smt_msg_time_stamp_ms; /* 64 bit counter */# __u_int smt_msg_time_stamp_ls;? __u_int smt_transition_time_stamp_ms; /* 64 bit counter */* __u_int smt_transition_time_stamp_ls;#endif /* !__VAX */}; /* MAC GROUP */struct smtmib_mac {( __u_int mac_frame_statugs_functions;" __u_int mac_t_max_capability; __u_int mac_tvx_capability;! __u_int mac_available_paths; __u_int mac_current_path;! u_char mac_upstream_nbr[8];# u_char mac_downstream_nbr[8];% u_char mac_old_upstream_nbr[8];' u_char mac_old_downstream_nbr[8];" __u_int mac_dup_address_test;( __u_int mac_requested_paths;, __u_int mac_downstream_port_type; u_char mac_smt_address[8]; __u_int mac_t_req; __u_int h mac_t_neg; __u_int mac_t_max; __u_int mac_tvx_value;' __u_int mac_frame_error_threshold;# __u_int mac_frame_error_ratio; __u_int mac_rmt_state; __u_int mac_da_flag; __u_int mac_unda_flag;" __u_int mac_frame_error_flag;' __u_int mac_ma_unitdata_available; __u_int mac_hw_present;$ __u_int mac_ma_unitdata_enable;}; /* PATH GROUP */struct smtmib_path {$ u_char path_configuration[32];" __u_int path_tvx_lower_bounid;$ __u_int path_t_max_lower_bound; __u_int path_max_t_req;}; /* PORT GROUP */struct smtmib_port { __u_int port_my_type[2];# __u_int port_neighbor_type[2];) __u_int port_connection_policies[2];# __u_int port_mac_indicated[2];" __u_int port_current_path[2];% __u_int port_requested_paths[2];# __u_int port_mac_placement[2];% __u_int port_available_paths[2]; __u_int port_pmd_class[2];- __u_int port_connection_capabilities[2];j __u_int port_bs_flag[2];" __u_int port_ler_estimate[2]; __u_int port_ler_cutoff[2]; __u_int port_ler_alarm[2];# __u_int port_connect_state[2]; __u_int port_pcm_state[2];! __u_int port_pc_withhold[2]; __u_int port_ler_flag[2];& __u_int port_hardware_present[2];};struct decext_mib { /* SMT GROUP */ __u_int esmt_station_type; /* MAC GROUP */ __u_int emac_link_state; __u_int emac_ring_purger_state;! __u_int emac_ring_purger_kenable; __u_int emac_frame_strip_mode; __u_int emac_ring_error_reason;# __u_int emac_up_nbr_dup_addr_flag;' __u_int emac_restricted_token_timeout; /* PORT GROUP */ __u_int eport_pmd_type[2]; __u_int eport_phy_state[2]; __u_int eport_reject_reason[2]; /* FDX (Full-Duplex) GROUP */8 __u_int efdx_enable; /* Valid only in SMT 7.2 */8 __u_int efdx_op; /* Valid only in SMT 7.2 */8 __u_int efdx_state; /* Valid only in SMT 7.2 */};.#define CTR_ lETHER 0 /* Ethernet interface */4#define CTR_DDCMP 1 /* DDCMP pt-to-pt interface */)#define CTR_FDDI 2 /* FDDI interface *//#define FDDIMIB_SMT 3 /* FDDI MIB SMT group *//#define FDDIMIB_MAC 4 /* FDDI MIB MAC group */1#define FDDIMIB_PATH 5 /* FDDI MIB PATH group */1#define FDDIMIB_PORT 6 /* FDDI MIB PORT group */8#define FDDIMIB_ATTA 7 /* FDDI MIB Attatchment Group */(#define FDDI_STATUS 8 /* FDDI status */8#define FDDISMT_MIB_SMT 9 /* FDDI SMT SMT MIB values */5#define FD mDISMT_MIB_MAC 10 /* FDDI SMT MAC values */6#define FDDISMT_MIB_PATH 11 /* FDDI SMT PATH values */6#define FDDISMT_MIB_PORT 12 /* FDDI SMT PORT values */=#define FDDIDECEXT_MIB 13 /* FDDI DEC Extended MIB values */.#define CTR_TRN 14 /* Token ring counters */5#define TRN_CHAR 15 /* Token ring characteristics */4#define TRN_MIB_ENTRY 16 /* Token ring mib entry */?#define TRN_MIB_STAT_ENTRY 17 /* Token ring mib status entry */C#define TRN_MIB_TIMER_ENTRY 18 /* Token ring mib timer e nntry */4#define FDDIMIB_PORT_B 19 /* FDDI MIB PORT group */7#define FDDISMT_MIB_PORT_B 20 /* FDDI MIB PORT group */C#define DS1_CONFIG 21 /* DS1 mib current entry */C#define DS1_CURRENT 22 /* DS1 mib current entry */D#define DS1_INTERVAL 23 /* DS1 mib interval entry */A#define DS1_TOTAL 24 /* DS1 mib total entry */K#define DS1_FAR_END_CURRENT 25 /* DS1 mib far end current entry */L#define DS1_FAR_END_INTERVALo 26 /* DS1 mib far end interval entry */I#define DS1_FAR_END_TOTAL 27 /* DS1 mib far end total entry */@#define DS1_FRAC 28 /* DS1 mib frac entry */Y#define CTR_IPSTAT 29 /* ip protocol interface counters since zeroed */W#define CTR_IPSTATBOOT 30 /* ip protocol interface counters since boot */[#define CTR_ICMPSTAT 31 /* icmp protocol interface counters since zeroed */Y#define CTR_ICMPSTATBOOT 32 p /* icmp protocol interface counters since boot */Z#define CTR_TCPSTAT 33 /* tcp protocol interface counters since zeroed */X#define CTR_TCPSTATBOOT 34 /* tcp protocol interface counters since boot */Z#define CTR_UDPSTAT 35 /* udp protocol interface counters since zeroed */X#define CTR_UDPSTATBOOT 36 /* udp protocol interface counters since boot */\#define CTR_IGMPSTAT 37 /* igmp protocol interface counters since zeroedq */Y#define CTR_IGMPSTATBOOT 38 /* igmp protocol interface counters since boot */N#define CTR_RTSTAT 39 /* ip routing counters since zeroed */L#define CTR_RTSTATBOOT 40 /* ip routing counters since boot */X#define CTR_MRTSTAT 41 /* multicast ip routing counters since zeroed */V#define CTR_MRTSTATBOOT 42 /* multicast ip routing coutners since boot */I#define CTR_ETHER_EXTENDED 43 /* Extended Ethernet interface * r/E#define CTR_FDDI_EXTENDED 44 /* Extended FDDI interface */\#define CTR_IPSECSTAT 45 /* IPsec protocol interface counters since zeroed */Z#define CTR_IPSECSTATBOOT 46 /* IPsec protocol interface counters since boot */%#define ctr_ether ctr_ctrs.ctrc_ether-#define ctr_ether_ext ctr_ctrs.ctrc_ether_ext%#define ctr_ddcmp ctr_ctrs.ctrc_ddcmp$#define ctr_fddi ctr_ctrs.ctrc_fddi,#define ctr_fddi_ext ctr_ctrs.ctrc_fddi_ext&#define sts_fddi ctr_ctrs.stastus_fddi*#define dna_fddi ctr_ctrs.dna_status_fddi##define fmib_smt ctr_ctrs.smt_fddi##define fmib_mac ctr_ctrs.mac_fddi%#define fmib_path ctr_ctrs.path_fddi%#define fmib_port ctr_ctrs.port_fddi%#define fmib_atta ctr_ctrs.atta_fddi"#define smib_smt ctr_ctrs.smt_smt"#define smib_mac ctr_ctrs.smt_mac$#define smib_port ctr_ctrs.smt_port$#define smib_path ctr_ctrs.smt_path##define decmib_ext ctr_ctrs.dec_ext0#define CTR_HDRCRC 0 /* header crc bit index */.#define CTR_DATCRC t 1 /* data crc bit index */<#define CTR_BUFUNAVAIL 0 /* buffer unavailable bit index *//*" * Interface counter ioctl request */struct ctrreq {. char ctr_name[IFNAMSIZ]; /* if name */@ char ctr_type; /* type of interface */ union {A struct estat ctrc_ether; /* ethernet counters */X struct estat_extended ctrc_ether_ext; /* extended ethernet counters */G struct dstat ctrc_ddcmp; /* DDCMP pt-to-put counters */= struct fstat ctrc_fddi; /* FDDI counters */T struct fstat_extended ctrc_fddi_ext; /* extended FDDI counters */@ struct fstatus status_fddi; /* FDDI stsatus */V struct fddiDNA_status dna_status_fddi; /* FDDI status per DNA spec */C struct fddismt smt_fddi; /* fddi SMT attributes */C struct fddimac mac_fddi; /* fddi MAC attributes */F struct fddipath path_fddi; /* v fddi PATH attributes */G struct fddiport port_fddi; /* fddi PORT attributes */J struct fddiatta atta_fddi; /* fddi attatch attributes */8 struct smtmib_smt smt_smt; /* smt mib attributes */8 struct smtmib_mac smt_mac; /* smt mib attributes */9 struct smtmib_path smt_path; /* smt mib attributes */9 struct smtmib_port smt_port; /* smt mib attributes */6 struct decext_mib dec_ext; /* dec extended mib */; struct trnchar trnchar; /* Token riwng characteristics */6 struct trncount trncount; /* Token ring counters */< struct dot5Entry dot5Entry; /* Token ring MIB counters */B struct dot5StatsEntry dot5StatsEntry; /*Token ring MIB stats */C struct dot5TimerEntry dot5TimerEntry; /*Token ring MIB Timers */c unsigned char protos[512]; /* protocol stat structs can't be bigger */ } ctr_ctrs;};union mac_addr { u_short saddr[3]; u_char caddr[6];};/*< * following are the protoxtypes and structure defns. for the- * new interface indentification API for IPv6*/?char * if_indextoname ( unsigned int, char *);8unsigned int if_nametoindex ( const char * );,struct if_nameindex * if_nameindex ( void );1void if_freenameindex ( struct if_nameindex *);struct if_nameindex { unsigned int if_index; char *if_name;};/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#eyndif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore #pragma __extern_model __restore#pragma __standard#endif /* __IF_LOADED */wwL.ԗ#ifndef __IF_ARP_LOADED#define __IF_ARP_LOADED 1M/******************************************************************************?** - Structures for the Address Resolution Protocol**M******************************************************************************* Header is nonstandardMz*****************************************************************************I** I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** { I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial erro|rs or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** } M*******************************************************************************E** Copyright (c) 1982, 1993 Regents of the University of California.A** All rights reserved. The Berkeley software License Agreement:** specifies the terms and conditions for redistribution.**1** if_arp.h 8.1 (Berkeley) 6/10/93**N*******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus~ extern "C" {#endif#include #if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*7** Set __nomember_alignment to avoid internal and tail3** padding in structures; default base alignment. :** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment/*$** External model of relaxed refdef*/#pragma __extern_model __save'#pragma __extern_model __relaxed_refdef/* * Address Resolution Protocol. *B * See RFC 826 for protocol description. ARP packets are variableB * in size; the arphdr structure defines the fixed-length portion.C * Protocol type values are the same as those for 10 Mb/s Ethernet.? * It is followed by the variable-sized fields ar_sha, arp_spa,> * arp_tha and arp_tpa in that order, according to the lengths6 * specified. Field names used correspond to RFC 826. */struct arphdr {2 u_short ar_hrd; /* for mat of hardware address */7#define ARPHRD_ETHER 1 /* ethernet hardware address */3#define ARPHRD_802 6 /* 802 net hardware address */2 u_short ar_pro; /* format of protocol address */1 u_char ar_hln; /* length of hardware address */1 u_char ar_pln; /* length of protocol address */ u_short ar_op; /* one of: */8#define ARPOP_REQUEST 1 /* request to resolve address */8#define ARPOP_REPLY 2 /* response to previous request *//*- * The remaining fields are variable in size, * according to the sizes above. */1/* u_char ar_sha[]; sender hardware address */1/* u_char ar_spa[]; sender protocol address */1/* u_char ar_tha[]; target hardware address */1/* u_char ar_tpa[]; target protocol address */};3/* For indexing into arbitrary ha/pa ARP headers */'#define AR_SHA(ah) ((u_char *)((ah)+1)),#define AR_SPA(ah) (AR_SHA(ah)+(ah)->ar_hln),#define AR_THA(ah) (AR_SPA(ah)+(ah)->ar_pln),#define AR_TPA(ah) (AR_THA(ah)+(ah)->ar_hln)/* * ARP ioctl request  */struct arpreq {0 struct sockaddr arp_pa; /* protocol address */0 struct sockaddr arp_ha; /* hardware address */ int arp_flags; /* flags */};*/* arp_flags and at_flags field values */)#define ATF_INUSE 0x01 /* entry in use */:#define ATF_COM 0x02 /* completed entry (enaddr valid) */+#define ATF_PERM 0x04 /* permanent entry */B#define ATF_PUBL 0x08 /* publish entry (respond for other host) */9#define ATF_USETRAILERS 0x10 /* has requested trailers */4#define ATF_USE802 0x20 /* host using 802 framing */:#define ATF_STALE 0x0100 /* entry needs to be refreshed */<#define ATF_DEAD 0x0200 /* entry (host) failed to refresh */1#define ATF_CANTCHANGE (0xff00|ATF_INUSE|ATF_COM)/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore #pragma __extern_model __restore#pragma __standard#endif /* __IF_ARP_LOADED */ww .ԗ#ifndef __IF_TRNSTAT_LOADED#define __IF_TRNSTAT_LOADED 1M/******************************************************************************>** - Structures providing a packet transport mechanism**M******************************************************************************* Header is nonstandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice.  The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M*******************************************************************************E** Copyright (c) 1982, 1993 Regents of the University of California.A** All rights reserved. The Berkeley software License Agreement:** specifies the terms and conditions for redistribution.**/** if.h 8.1 (Berkeley) 6/10/93**N*******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#include #if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*A** All structures should be member aligned on natural boundaries*/!#pragma __member_alignment __save#pragma __member_alignment/*$** External model of relaxed refdef*/#pragma __extern_model __save'#pragma __extern_model __relaxed_refdef/* * Token Ring characteristics. */struct trnchar {6 __u_char mac_addr[6]; /* The mac address */2 __u_char grp_addr[6]; /* Group address */8 __u_char func_addr[6]; /* Functional address */8 __u_short drop_numb; /* P hysical drop number */9 __u_char upstream_nbr[6]; /* Upstream neighbor */@ __u_short upstream_drop_numb; /* Upstream drop number */D __u_short transmit_access_pri; /* Trasmit access priority */5 __u_short last_major_vector; /* Last major vector */+ __u_short ring_status; /* Ring status */7 __u_short interface_state; /* State of the interface*/; __u_short monitor_contd; /* monitor contender */9 __u_short soft_error_timer; /* Soft error timer value */0 __u _short ring_number; /* Local ring number */7 __u_short monitor_error_code; /* Monitor error code */= __u_short beacon_receive_type; /* Type of beacon received */A __u_short beacon_transmit_type; /* Type of beacon transmitted */= __u_char beacon_una[6]; /* UNA of the beaconing station */H __u_short beacon_stn_drop_numb; /* Drop number of the beacon station */3 __u_short ring_speed; /* The ring speed */3 __u_short etr; /* Early token release */+ __u_short open_status;  /* Open status */3 __u_char token_ring_chip[16]; /* type of chip */};/*- * Definitions for the Major Vector commands # * See page 2-30 of the TMS380 book */#define MV_RESPONSE 0x00#define MV_BEACON 0x02#define MV_CLAIM_TOKEN 0x03#define MV_RING_PURGE 0x04#define MV_ACTIVE_MON_PRES 0x05 #define MV_STANDBY_MON_PRES 0x06#define MV_DUP_ADDR_TEST 0x07#define MV_LOBE_MEDIA_TEST 0x08#define MV_TRANSMIT_FORW 0x09 #define MV_RMV_RING_STATION 0x0B#define MV_CHANGE_PARM 0x0C#define MV_INIT_RING_STN 0x0D#define MV_REQ_STN_ADDR 0x0E#define MV_REQ_STN_STATE 0x0F#define MV_REQ_STN_ATTACH 0x10#define MV_REQ_INIT 0x20#define MV_REPORT_STN_ADDR 0x22 #define MV_REPORT_STN_STATE 0x23!#define MV_REPORT_STN_ATTACH 0x24"#define MV_REPORT_NEW_MONITOR 0x25!#define MV_REPORT_SUA_CHANGE 0x26$#define MV_REPORT_RNG_POLL_FAIL 0x27"#define MV_REPORT_MONTIOR_ERR 0x28#define MV_REPORT_ERR 0x29$#define MV_REPORT_TRANSMIT_FORW 0x2A/*$ * Definitions for the beacon types # * See page 2-56 of the TMS380 book */#define BT_SET_RECOV_MODE 0x01#define BT_SET_SIGNAL_LOSS 0x02!#define BT_SET_BIT_STREAMING 0x03"#define BT_SET_CONT_STREAMING 0x04/** * Definitions for the Monitor Error Code.# * See page 2-47 of the TMS380 book */#define M_NO_ERROR 0x0000#define M_MON_ERROR 0x0001#define M_DUPLICATE_MON 0x0002#define M_DUPLICATE_ADDR 0x0003/* * Token Ring counters */struct trncount {F __u_long trn_second; /* seconds since last zeroed */> __u_long trn_bytercvd; /* bytes received */: __u_long trn_bytesent; /* bytes sent */D __u_long trn_pdurcvd; /* data blocks received */@ __u_long trn_pdusent; /* data blocks sent */H __u_long trn_mbytercvd; /* multicast bytes received */B __u_long trn_mpdurcvd; /* multicast blocks received */D __u_long trn_mbytesent; /* multica st bytes sent */E __u_long trn_mpdusent; /* multicast blocks sent */3 __u_long trn_pduunrecog; /* frame unrecognized */> __u_long trn_mpduunrecog; /* multicast frame unrecognized */I __u_short trn_nosysbuf; /* system buffer unavailable */. __u_short trn_xmit_fail; /* xmit failures */2 __u_short trn_xmit_underrun; /* xmit underruns */4 __u_short trn_line_error; /* Line errors */@ __u_short trn_internal_error; /* recoverable internal errors */4  __u_short trn_burst_error; /* Burst error */8 __u_short trn_ari_fci_error; /* ARI/FCI error */< __u_short trn_ad_trans; /* Abort delimiters transmitted */> __u_short trn_lost_frame_error; /* Lost frame error */P __u_short trn_rcv_congestion_error;/* receive overrun (or congestion) */B __u_short trn_frame_copied_error; /* Frame copied error */5 __u_short trn_frequency_error; /* Frequency error */4 __u_short trn_token_error; /* Token error */4 __ u_short trn_hard_error; /* Hard errors */; __u_short trn_soft_error; /* Soft errors */4 __u_short trn_adapter_reset; /* Resets performed */- __u_short trn_signal_loss; /* Signal loss */5 __u_short trn_xmit_beacon; /* Beacons transmitted */; __u_short trn_ring_recovery; /* Ring recoverys received */: __u_short trn_lobe_wire_fault; /* Lobe faults detected */5 __u_short trn_remove_received; /* Remove received */? __u_short trn_single_station; /* # of times host was single */> __u_short trn_selftest_fail; /* # of times selftest failed */};/* # * Token Ring RFC 1231 definitions. */struct dot5Entry { int dot5TrnNumber; int dot5IfIndex; int dot5Commands; int dot5RingStatus; int dot5RingState; int dot5RingOpenStatus; int dot5RingSpeed; __u_char dot5UpStream[6]; int dot5ActMonParticipate; __u_char dot5Functional[6];};/* Values for dot5Commands */#define MIB1231_COMM_NO_OP 1#define MIB1231_COMM_O PEN 2#define MIB1231_COMM_RESET 3#define MIB1231_COMM_CLOSE 4/* Values for dot5RingStatus */'#define MIB1231_RSTATUS_NO_PROB 0x00005#define MIB1231_RSTATUS_RING_RECOVERY 0x0020 /* 32 */6#define MIB1231_RSTATUS_SINGLE_STATION 0x0040 /* 64 */4#define MIB1231_RSTATUS_REMOVE_RCVD 0x0100 /* 256 */1#define MIB1231_RSTATUS_RESERVED 0x0200 /* 512 */8#define MIB1231_RSTATUS_AUTO_REM_ERROR 0x0400 /* 1024 */9#define MIB1231_RSTATUS_LOBE_WIRE_FAULT 0x0800 /* 2048 */9#define MIB1231_RSTATUS_ TRANSMIT_BEACON 0x1000 /* 4096 */4#define MIB1231_RSTATUS_SOFT_ERROR 0x2000 /* 8192 */5#define MIB1231_RSTATUS_HARD_ERROR 0x4000 /* 16384 */6#define MIB1231_RSTATUS_SIGNAL_LOSS 0x8000 /* 32768 */6#define MIB1231_RSTATUS_NO_STATUS 0x20000 /* 131072 *//* Values for dot5RingState */!#define MIB1231_RSTATE_OPENED 1!#define MIB1231_RSTATE_CLOSED 2"#define MIB1231_RSTATE_OPENING 3"#define MIB1231_RSTATE_CLOSING 4&#define MIB1231_RSTATE_OPEN_FAILURE 5&#define MIB1231_RSTATE_RING_FAILURE 6/* Values for dot5RingStatus */"#define MIB1231_ROSTATUS_NOOPEN 1"#define MIB1231_ROSTATUS_BADPARM 2%#define MIB1231_ROSTATUS_LOBEFAILED 3##define MIB1231_ROSTATUS_SIG_LOSS 4&#define MIB1231_ROSTATUS_INS_TIMEOUT 5&#define MIB1231_ROSTATUS_RING_FAILED 6$#define MIB1231_ROSTATUS_BEACONING 7(#define MIB1231_ROSTATUS_DUPLICATE_MAC 8%#define MIB1231_ROSTATUS_REQ_FAILED 9%#define MIB1231_ROSTATUS_REM_RECVD 10!#define MIB1231_ROSTATUS_OPEN 11/* Values for dot5RingSpeed */!#define MIB1231_RSPEED_UNKNOWN 1#define MIB1231_RSPEED_1_MEG 2#define MIB1231_RSPEED_4_MEG 3 #define MIB1231_RSPEED_16_MEG 4&/* Values for dot5ActMonParticipate */#define MIB1231_ACTMON_TRUE 1#define MIB1231_ACTMON_FALSE 2/* The statistics table */struct dot5StatsEntry { int dot5StatsIfIndex; int dot5StatsLineErrors; int dot5StatsBurstErrors; int dot5StatsACErrors;" int dot5StatsAbortTransErrors; int dot5StatsInternalErrors;! int dot5StatsLostFrameErrors;$ int dot5StatsReceiveCongestions;# int dot5StatsFrameCopiedErrors; int dot5StatsTokenErrors; int dot5StatsSoftErrors; int dot5StatsHardErrors; int dot5StatsSignalLoss;! int dot5StatsTransmitBeacons; int dot5StatsRecoverys; int dot5StatsLobeWires; int dot5StatsRemoves; int dot5StatsSingles; int dot5StatsFreqErrors;}; /* The timer table - optional */struct dot5TimerEntry { int dot5TimerIfIndex; int dot5TimerReturnRepeat; int dot5TimerHolding; int dot5TimerQueuePDU; int dot5TimerValidTransmit; int dot5TimerNoToken; int dot5TimerActiveMon; int dot5TimerStandbyMon; int dot5TimerErrorReport; int dot5TimerBeaconTransmit; int dot5TimerBeaconReceive;};/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore #pragma __extern_model __restore#pragma __standard"#endif /* __IF_TRNSTAT_LOADED */wwi.ԗ#ifndef __IF_TYPES_LOADED#define __IF_TYPES_LOADED 1M/******************************************************************************** - IANA types**M******************************************************************************* Header is nonstandardM*****************************************************************************I**  I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M*******************************************************************************?** Copyright (c) 1989 Regents of the University of California.** All rights reserved.**L** Redistribution and use in source and binary forms are permitted providedJ** that: (1) source distributions retain this entire copyright notice andK** comment, and (2) distributions including binaries display the followingG** acknowledgement: ``This product includes software developed by theD** University of California, Berkeley and its contributors'' in theJ** documentation or other materials provided with the distribution and inJ** all advertising materials mentioning features or use of this software.L** Neither the name of the University nor the names of its contributors mayM** be used to endorse or promote products derived from this software without&** specific prior written permission.J** THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIEDH** WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF9** MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.***** Base: if_types.h 7.2 (Berkeley) 9/20/89,** Merged: if_types.h 7.3 (Berkeley) 6/28/90**N*******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*0 * latest IANA sanctioned types can be found at:4 * ftp.isi.edu/in-notes/iana/assignments/smi-numbers */B/* interface types for benefit of parsing media address headers */2#define IFT_OTHER 0x1 /* none of the following */1#define IFT_1822 0x2 /* old-style arpanet imp */.#define IFT_HDH1822 0x3 /* HDH arpanet imp */(#define IFT_X25DDN 0x4 /* x25 to imp */-#define IFT_X25 0x5 /* PDN X25 interface */-#define IFT_ETHER 0x6 /* Ethernet I or II */'#define IFT_ISO88023 0x7 /* CMSA CD */)#define IFT_ISO88024 0x8 /* Token Bus */*#define IFT_ISO88025 0x9 /* Token Ring */##define IFT_ISO88026 0xa /* MAN */#define IFT_STARLAN 0xb/#define IFT_P10 0xc /* Proteon 10MBit ring *//#define IFT_P80 0xd /* Proteon 10MBit ring */'#define IFT_HY 0xe /* Hyperchannel */#define IFT_FDDI 0xf#define IFT_LAPB 0x10#define IFT_SDLC 0x11#define IFT_T1 0x12#define IFT_CEPT 0x13#define IFT_ISDNBASIC 0x14#define IFT_ISDNPRIMARY 0x15#define IFT_PTPSERIAL 0x164#define IFT_PPP 0x17 /* Point to Point Protocol*/ %#define IFT_LOOP 0x18 /* loopback */(#define IFT_EON 0x19 /* ISO over IP */A#define IFT_XETHER 0x1a /* obsolete 3MB experimental ethernet */(#define IFT_NS IP 0x1b /* XNS over IP */0#define IFT_SLIP 0x1c /* IP over generic TTY */&#define IFT_ULTRA 0x1d /* RFC 1213 */8#define IFT_DS3 0x1e /* DS3/E3 interface (RFC 1407) */,#define IFT_SIP 0x1f /* SMDS (RFC 1305) */:#define IFT_FRAMERELAY 0x20 /* Frame Relay (RFC 1315) */6#define IFT_RS232 0x21 /* RS232 Objects (RFC 1659) */<#define IFT_PARALLEL 0x22 /* Parallel Objects (RFC 1660) */*#define IFT_ARCNET 0x23 /* ARC network */4#define IFT_ARCNET_PLUS 0x24 /* ARC network plus */(#define IFT_ATM 0x25 /* ATM network *//#define IFT_MIO25 0x26 /* MIOX25 (RFC 1461) */(#define IFT_SONET 0x27 /* SONET/ SDH */8#define IFT_X25PLE 0x28 /* X.25 packet level (RFC 1382)<#define IFT_ISO88022LLC 0x29 /* 802 logical link Control */#define IFT_LOCALTALK 0x2a )#define IFT_SMDSDXI 0x2b /* SMDS DXI */ 3#define IFT_FRAMERELAYS 0x2c /* Frame Relay DCE */!#define IFT_V35 0x2d /* V.35 */!#define IFT_HSSI 0x2e /* HSSI */!#define IFT_HPPI 0x2f /* HPPI */-#define IFT_MODEM 0x30 /* "generic modem" */*#define IFT_AAL5 0x31 /* AAl5 over ATM */#define IFT_SONETPATH 0x32 #define IFT_SOBETVI 0x33 B#define IFT_SMDSICIP 0x34 /* SMDS InterCarrier Interface proto */=#define IFT_PROPVIRT 0x35 /* Proprietary Virtual/Internal */ /* Interface */@#define IFT_PROPMULTI 0x36 /* Propietary muli-link interface */,#define IFT_IEEE80212 0x37 /* 100Base VG *//#define IFT_FIBRECHAN 0x38 /* Fibre Channel */.#define IFT_HPPI_I 0x39 /* HIPPI Interface */C#define IFT_FRAM EREALYI 0x3a /* Interconnect over FR (RFC 1490) */<#define IFT_LANE8023 0x3b /* ATM LAN Emulation for 802.3 */<#define IFT_LANE8025 0x3c /* ATM LAN Emulation for 802.5 */6#define IFT_ATMECIR 0x3d /* ATM Emulatated Circuit */:#define IFT_FASTETHER 0x3e /* Fast Ethernet (100BaseT) */9#define IFT_ISDNX25 0x3f /* ISDN over X.25 (RFC 1356) */,#define IFT_V11 0x40 /* CCITT V/11/X.21 */'#define IFT_V36 0x41 /* CCITT V.36 */3#define IFT_G70364K 0x42 /* CCITT G703 @ 64Kbps */2#define IF T_G7022MB 0x43 /* CCITT G703 @ 2Mbps */%#define IFT_QLLC 0x44 /* SNA QLLC */I#define IFT_LAG 0xa1 /* IEEE 802.3ad Link Aggregate */E#define IFT_VLAN 0x87 /* IEEE 802.1q Virtual LAN */:/* non standard (non IANA) types start at 200 (decimal) */C#define IFT_WANDD 0xc8 /* Wide Area Network Device Driver */>#define IFT_RM 0xc9 /* Memory Channel (Reflective Memory) */7#define IFT_SYNC 0xca /* Synchronous communications */9#define IFT_IPV4  0xd0 /* IPv4 tunnel */9#define IFT_IPV6 0xd1 /* IPv6 tunnel */;#define IFT_IP624 0xd2 /* 6-to-4 tunnel */#ifdef __cplusplus }#endif#pragma __standard#endif /* __IF_LOADED */ww /ԗ#ifndef __IN_LOADED#define __IN_LOADED 1M/******************************************************************************%** - Internet protocol family**M*****************************************************************************I** Header introduced by the X/Open CAE Specification, Issue 4, Version 2M*****************************************************************************I** I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty.  I** M*******************************************************************************?** Copyright (c) 1982 Regents of the University of California.A** All rights reserved. The Berkeley software License Agreement:** specifies the terms and conditions for redistribution.**.** in.h 6.5 (Berkeley) 6/8/85**N*******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*I** The OpenVMS V7.0 release added a second implementation of the socket F** functions which is compatible with BSD 4.4. Define a local to be C** used throughout the remaining header file which reflects which !** implementation is being used.**I** An application program enables this support by defining _SOCKADDR_LEN(** prior to including this header file.*/#ifdef _SOCKADDR_LEN# if (__CRTL_VER < 70000000)H# error " BSD 4.4 Socket package not available before OpenVMS V7.0"# undef _SOCKADDR_LEN # endif#endif/*E** All includes of other header files must be done prior to alteringC** the pointer size mode. We include socket.h because we need the%** sa_family_t typedef for Spec1170.*/#include %#if !defined (_XOPEN_SOURCE_EXTENDED)# include #endif/*.** Start processing in 32-bit addressing mode*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*7** Set __nomember_alignment to avoid internal and tail2** padding in structures; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment/* ** Define XPG4 IP typedefs*/4#if !defined __IN_PORT_T && !defined _DECC_V4_SOURCE# define __IN_PORT_T 1" typedef __in_port_t in_port_t;#endif5#if !defined __IN_ADDR_T && !defined _DECC_V4_SOURCE# define __IN_ADDR_T 1" typedef __in_addr_t in_addr_t;#endif6#if !defined __SA_FAMILY_T && !defined _DECC_V4_SOURCE# define __SA_FAMILY_T 1& typedef __sa_family_t sa_family_t;#endif/*:** Internet address (a structure for historical reasons).;** The address format can be any of the supported Internet?** address notations. See the DEC TCP/IP Services for OpenVMS6** System Management manual for more information on ** Internet address notations.*/#ifndef __IN_ADDR# define __IN_ADDR 1 struct in_addr { union {A struct { unsigned char s_b1,s_b2,s_b3,s_b4; } S_un_b;8 struct { unsigned short s_w1,s_w2; } S_un_w;! unsigned long S_addr;#ifdef _XOPEN_SOURCE_EXTENDED& __in_addr_t S_addr_xopen;#endif } S_un;};#ifdef _XOPEN_SOURCE_EXTENDEDB# define s_addr S_un.S_addr_xopen /* X/Open version of s_addr */#elseL# define s_addr S_un.S_addr /* can be used for most tcp & ip code */#endif6# define s_host S_un.S_un_b.s_b2 /* host on imp */6# define s_net S_un.S_un_b.s_b1 /* network */6# define s_imp S_un.S_un_w.s_w2 /* imp */6# define s_impno S_un.S_un_b.s_b4 /* imp # */6# define s_lh S_un.S_un_b.s_b3 /* logical host */#endif/*2 * Buffer size to hold IPv4 address as text string */#define INET_ADDRSTRLEN 16/*; * Constants and structures defined by the internet system, * Per RFC 790, September 1981. *//* * Protocols */)#define IPPROTO_IP 0 /* dummy for IP */M#define IPPROTO_HOPOPTS 0 /* IPv6 Hop-by-Hop options */7#define IPPROTO_ICMP 1 /* control message protocol */2#define IPPROTO_IGMP 2 /* group mgmt protocol */4#define IPPROTO_GGP 3 /* gateway^2 (deprecated) */B#define IPPROTO_IPIP 4 /* IP inside IP */8#define IPPROTO_IPV4 IPPROTO_IP IP /* IPv4 (tunneled) */!#define IPPROTO_TCP 6 /* tcp */7#define IPPROTO_EGP 8 /* exterior gateway protocol */"#define IPPROTO_PUP 12 /* pup */5#define IPPROTO_UDP 17 /* user datagram protocol */&#define IPPROTO_IDP 22 /* xns idp */8#define IPPROTO_TP 29 /* tp-4 w/ class negotiation */A#define IPPROTO_IPV6 41 /* IPv6 header */I#define IPPROTO_ROUTING 43 /* IPv6 Routing header */O#define IPPROTO_FRAGMENT 44 /* IPv6 fragmentation header */P#define IPPROTO_RSVP 46 /* resource reservation proto */M#define IPPROTO_ESP 50 /* encap. security payload */K#define IPPROTO_AH 51 /* authentication header */<#define IPPROTO_ICMPV6 58 /* ICMPv6 */I#define IPPROTO_NONE 59 /* IPv6 no next header */N#define IPPROTO_DSTOPTS 60 /* IPv6 Destination options */>#define IPPROTO_EO N 80 /* ISO cnlp */O#define IPPROTO_IFMP 101 /* Ipsilon Flow Mgmt Protocol*/L#define IPPROTO_IPCOMP 108 /* IP Payload Compression */:#define IPPROTO_SCTP 132 /* SCTP */J#define IPPROTO_MH 135 /* IPv6 Mobility header */J#define IPPROTO_MOBILITY IPPROTO_MH /* IPv6 Mobility header */-#define IPPROTO_RAW 255 /* raw IP packet */#define IPPROTO_MAX 256/*! * Local port number conventions:+ * Ports < IPPORT_RESERVED are reserved for$ * privileged processes (e.g. root).+ * Ports > IPPORT_USERRESERVED are reserved+ * for servers, not necessarily privileged. */#define IPPORT_RESERVED 1024 #define IPPORT_USERRESERVED 5000./* From Sun 4.1 sources, needed for SUN rpc */%#define IPPORT_TIMESERVER 37/*** Link numbers*/#define IMPLINK_IP 155#define IMPLINK_LOWEXPER 156#define IMPLINK_HIGHEXPER 158/*9** Ma cros for subnetworks. A subnet is distinguished by**=** (1) the network number is a `local' network number, and;** (2) the most significant bit of the host part is set.**I** Such addresses include one additional byte in the network number, andK** use one less byte in the host part (i.e., a subnet of a Class A networkK** uses the rules for Class B net/host number extraction, a Class B subnetH** is dealt with as if it were a Class C net). Subnets of Class C nets** are not supported.*/E#define SUBNETSHIFT 8 /* used to get main net number from subnet */B#define IN_SUBNETA(i) ((((long)(i))&0x80800000)==0x00800000)&#define IN_CLASSA_SUBNET 0xffff0000<#define IN_CLASSA_SUBNSHIFT (IN_CLASSA_NSHIFT - SUBNETSHIFT)&#define IN_CLASSA_SUBHOST 0x0000ffffB#define IN_SUBNETB(i) ((((long)(i))&0xc0008000)==0x80008000)&#define IN_CLASSB_SUBNET 0xffffff00<#define IN_CLASSB_SUBNSHIFT (IN_CLASSB_NSHIFT - SUBNETSHIFT)&#define IN_CLASSA_SUBHOST 0x0000ffff&#define IN_CLASSB_SUBHOST 0x000000ff/*4 * Definitions of bits in internet address integers.C * On subnets, the decomposition of addresses to host and net parts8 * is done according to subnet mask, not the masks here. */4#define IN_CLASSA(i) (((int)(i) & 0x80000000) == 0)!#define IN_CLASSA_NET 0xff000000#define IN_CLASSA_NSHIFT 24"#define IN_CLASSA_HOST 0x00ffffff#define IN_CLASSA_MAX 128=#define IN_CLASSB(i) (((int)(i) & 0xc0000000) == 0x80000000)!#define IN_CLASSB_NET 0xffff0000#define IN_CLASSB_NSHIFT 16"#define IN_CLASSB_HOST 0x0000ffff#define IN_CLASSB_MAX 65536=#define IN_CLASSC(i) (((int)(i) & 0xe0000000) == 0xc0000000)!#define IN_CLASSC_NET 0xffffff00#define IN_CLASSC_NSHIFT 8"#define IN_CLASSC_HOST 0x000000ff=#define IN_CLASSD(i) (((int)(i) & 0xf0000000) == 0xe0000000)@#define IN_CLASSD_NET 0xf0000000 /* These ones aren't really */;#define IN_CLASSD_NSHIFT 28 /* net and host fields, but */?#define IN_CLASSD_HOST 0x0fff ffff /* routing needn't know. */%#define IN_MULTICAST(i) IN_CLASSD(i)B#define IN_EXPERIMENTAL(i) (((int)(i) & 0xe0000000) == 0xe0000000)?#define IN_BADCLASS(i) (((int)(i) & 0xf0000000) == 0xf0000000),#define INADDR_ANY (unsigned int)0x00000000F#define INADDR_BROADCAST (unsigned int)0xffffffff /* must be masked */8#define INADDR_LOOPBACK (unsigned int)0x7F000001F#define INADDR_UNSPEC_GROUP (unsigned int)0xe0000000 /* 224.0.0.0 */H#define INADDR_ALLHOSTS_GROUP (unsigned int)0xe0000001 /* 224.0.0.1 */I#define INADDR_MAX_LOCAL_GROUP (unsigned int)0xe00000ff /* 224.0.0.255 */0#define INADDR_NONE 0xffffffff /* -1 return */-#define IN_LOOPBACKNET 127 /* official! *//*" * Socket address, internet style. */#if defined(_SOCKADDR_LEN) || \" defined(_XOPEN_SOURCE_EXTENDED)struct sockaddr_in { unsigned char sin_len;: __sa_family_t sin_family; /* New typedef for Spec 1170 */6 __in_port_t sin_port; /* New typedef for Spec 1170 */ struct in_addr sin_addr;#ifdef _XOPEN_SOURCE_EXTENDED; unsigned char sin_zero[8]; /* Changed type from char to */& /* unsigned char for Spec 1170 */#else char sin_zero[8];#endif};#elsestruct sockaddr_in { unsigned short sin_family; unsigned short sin_port; struct in_addr sin_addr; char sin_zero[8];};#endif/* ** DEC C extensions** N** caddr_t was here in previous versions and so is retained for compatibility*/ M#if !defined __CADDR_T && !defined CADDR_T && !defined _XOPEN_SOURCE_EXTENDED# define __CADDR_T 1!# ifndef __HIDE_FORBIDDEN_NAMES# define CADDR_T 1 # endif typedef __caddr_t caddr_t;# endif/*) * Structure used to describe IP options.? * Used to store options internally, to pass them to a process,+ * or to restore options retrieved earlier.I * The ip_dst is used for the first-hop gateway when using a source route* * (this gets put into the header proper). */struct ip_opts {6 struct in_addr ip_dst; /* first hop, 0 w/o src rt */#if defined(__cplusplus)E char Ip_opts[40]; /* cannot have same name as class */#else3 char ip_opts[40]; /* actually variable in size */#endif};/*6 * Options for use with [gs]etsockopt at the IP level.= * First word of comment is data type; bool is stored in int. */E#define IP_OPTIONS 1 /* buf/ip_opts; set/get IP per-packet options */B#define IP_HDRINCL 2 /* int; header is included with data (raw) */>#define IP_TOS 3 /* int; IP typ e of service and precedence */,#define IP_TTL 4 /* int; IP time to live */C#define IP_RECVOPTS 5 /* bool; receive all IP options w/datagram */D#define IP_RECVRETOPTS 6 /* bool; receive IP options for response */C#define IP_RECVDSTADDR 7 /* bool; receive IP dst addr w/datagram */A#define IP_RETOPTS 8 /* ip_opts; set/get IP per-packet options */B#define IP_MULTICAST_IF 9 /* in_addr; IP multicast interface */C#define IP_MULTICAST_TTL 10 /* u_char; IP multicast timetolive */A#define IP_MULTICAST_LOOP 11 /* u_char; IP multicast loopback */H#define IP_ADD_MEMBERSHIP 12 /* ip_mreq; add an IP group membership */H#define IP_DROP_MEMBERSHIP 13 /* ip_mreq; drop an IP group membership */E#define IP_MULTICAST_VIF 14 /* set/get IP mcast vir. interface */E#define OIP_MULTICAST_IF 16 /* in_addr; IP multicast interface */E#define OIP_MULTICAST_TTL 17 /* u_char; IP multicast timetolive */C#define OIP_MULTICAST_LOOP 18 /* u_char; IP multicast loopback */J#define OIP_ADD_MEMBERSHIP 19 /* ip_mreq; add an IP group membership */J#define OIP_DROP_MEMBERSHIP 20 /* ip_mreq; drop an IP group membership */E#define OIP_MULTICAST_VIF 21 /* set/get IP mcast vir. interface */E#define IP_RSVP_ON 25 /* set rsvp var. in kernel */E#define IP_RSVP_OFF 26 /* unset rsvp var in kernel */E#define IP_RSVP_VIF_ON 27 /* set rsvp per-vif socket */E#define IP_RSVP_VIF_OFF 28 /* unset rsvp per-vif socket */?#define IP_PROXY 29 /* bool; allow proxy packet reception */,/* IP_FLOWLABEL 20 defined in in6.h */(/* IP_RXHDR 21 defined in in6.h */K#define IP_DEFAULT_MULTICAST_TTL 1 /* normally limit m'casts to 1 hop */K#define IP_DEFAULT_MULTICAST_LOOP 1 /* normally hear sends if a member */K#define IP_DEFAULT_MEMBERSHIPS 20 /* default multicasts per socket */D#define IP_MAX_MEMBERSHIPS 65535 /* max per socket *//*# * IP protocol specific route flags */K#define IP_RTF_PMTU RTF_PROTO3 /* rmx_mtu set by pmtu discovery *//*C * Argument structure for IP_ADD_MEMBERSHIP and IP_DROP_MEMBERSHIP. */struct ip_mreq {B struct in_addr imr_multiaddr; /* IP multicast address of group */B struct in_addr imr_interface; /* local IP address of interface */};/* * Protocol specific route flags */@#define RTF_PMTU RTF_PROTO4 /* rmx_mtu set by pmtu discovery */@#define RTF_NOPMTUDISC RTF_PROTO5 /* pmtu discovery disabled */L#define RTF_NOFRAGTOPMTU RTF_PROTO6 /* fragment to pmtu size disabled */L#define RTF_LOOPBACK RTF_PROTO7 /* send packets over loopback device */:/* included to get decls for ntohs, htons, ntohl, htonl */ /*4 ** Macros for number representation conversion. */$ __in_addr_t htonl (__in_addr_t);$ __in_port_t htons (__in_port_t);$ __in_addr_t ntohl (__in_addr_t);$ __in_port_t ntohs (__in_port_t);#include /*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#pragma __standard#endif /* __IN_LOADED */ww"/ԗ#ifndef __IN6_LOADED#define __IN6_LOADED 1M/******************************************************************************)** - Internet V6 protocol family**M*****************************************************************************I** Header introduced by the X/Open CAE Specification, Issue 4, Version 2M*****************************************************************************I** I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I**  M*******************************************************************************?** Copyright (c) 1982 Regents of the University of California.A** All rights reserved. The Berkeley software License Agreement:** specifies the terms and conditions for redistribution.**/** in6.h 6.5 (Berkeley) 6/8/85**N*******************************************************************************/#pragma __nostandard#include <decc$types.h>#ifdef __cplusplus extern "C" {#endif/*H** The OpenVMS V7.0 release added a second implementation of the socketE** functions which is compatible with BSD 4.4. Define a local to beB** used throughout the remaining header file which reflects which!** implementation is being used.**I** An application program enables this support by defining _SOCKADDR_LEN(** prior to including this header file.*/#ifdef _SOCKADDR_LEN# if (__CRTL_VER < 70000000)H#  error " BSD 4.4 Socket package not available before OpenVMS V7.0"# undef _SOCKADDR_LEN # endif#endif/*I** All includes of other header files must be done prior to altering the** pointer size mode.*/#include %#if !defined (_XOPEN_SOURCE_EXTENDED)# include #endif#include #include #include /*.** Start processing in 32-bit addressing mode*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save#  pragma __pointer_size 32#endif/*7** Set __nomember_alignment to avoid internal and tail2** padding in structures; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment/*** Define XPG4 IP typedefs*/4#if !defined __IN_PORT_T && !defined _DECC_V4_SOURCE# define __IN_PORT_T 1" typedef __in_port_t in_port_t;#endif5#if !defined __IN_ADDR_T && !defined _DECC_V4_SOURCE# define __IN_ADDR_T 1" typedef __in_addr_t in_addr_t;#endif6#if !defined __SA_FAMILY_T && !defined _DECC_V4_SOURCE# define __SA_FAMILY_T 1& typedef __sa_family_t sa_family_t;#endif/* * IPv6 protocols */4#define IPPROTO_HOPOPTS 0 /* Hop-by-hop options */4#define IPPROTO_IPV6 41 /* IPv6 header */0#define IPPROTO_ROUTING 43 /* Routing header */6#define IPPROTO_FRAGMENT 44 /* Fragmentation header */5#define IPPROTO_ESP 50 /* Encap. security payload */2#define IPPROTO_AH 51 /* Authentication header */#define IPPROTO_ICMPV6 58#define IPPROTO_NONE 599#define IPPROTO_DSTOPTS 60 /* Destination Node header *//*! * Interface token lengths (bits) */%#define IPV6_LOOPBACK_TOKEN_LENGTH 0%#define IPV6_ETHERNET_TOKEN_LENGTH 64"#define IPV6_FDDI_TOKEN_LENGTH 64"#define IPV6_IPV4_TOKEN_LENGTH 48/*7 * Define the extra set/getsockopts for the IPv6 level. */E#define IP_FLOWLABEL 20 /* int; flow label in net byte ord er */@#define IP_RXHDR 21 /* int; include rx info in raw recv *//* * IPv6 level socket options */B#define IPV6_UNICAST_HOPS 104 /* int; unicast hoplimit (0..255) */F#define IPV6_MULTICAST_HOPS 105 /* int; multicast hoplimit (0..255) */;#define IPV6_MULTICAST_IF 106 /* u_int; mcast interface */ H#define IPV6_MULTICAST_LOOP 107 /* u_int; recv own multicast (0 or 1) */J#define IPV6_JOIN_GROUP 108 /* struct ipv6_mreq; join group */K#define IPV6_LEAVE_GROUP 109  /* struct ipv6_mreq; leave group */=#define IPV6_PKTINFO 110 /* set in6_pktinfo */;#define IPV6_HOPLIMIT 111 /* set hop limit */D#define IPV6_HOPOPTS 112 /* set hop-by-hop options */O#define IPV6_DSTOPTS 113 /* set dest. options after rt header */@#define IPV6_RTHDR 114 /* set routing header */B#define IPV6_NEXTHOP 115 /* set next hop address */B#define IPV6_CHECKSUM 116 /* int: checksum offset */<#define IPV6_PKTOPTIONS 117 /* sticky options */N#define IPV6_RXHDR 118 /* int; include rx info in raw recv */P#define IPV6_V6ONLY 119 /* int; AF_INET6 socket over IPv6 only*/P#define IPV6_RTHDRDSTOPTS 120 /* dest. options before routing header*/E#define IPV6_RECVPKTINFO 121 /* receive the in6_pktinfo */?#define IPV6_RECVHOPLIMIT 122 /* receive hop limit */D#define IPV6_RECVRTHDR 123 /* receive routing header */H#define IPV6_RECVHOPOPTS 124 /* receive hop-by-hop options */O#define IPV6_RECVDSTOPTS 125 /* receive dest opts after rt header */P#define IPV6_RECVRTHDRDSTOPTS 126 /* receive dest opts before rt header */O#define IPV6_RTHDR2 127 /* set rtng hdr t2 (kernel use only) */?#define IPV6_TCLASS 128 /* set traffic class */C#define IPV6_RECVTCLASS 129 /* receive traffic class */G#define IPV6_USE_MIN_MTU  130 /* path mtu discovery policy */C#define IPV6_DONTFRAG 131 /* don't fragment option */J#define IPV6_RECVPATHMTU 132 /* recieve path mtu information */;#define IPV6_PATHMTU 133 /* path mtu data */J#define IPV6_DEFAULT_UNICAST_HOPLIMIT 64 /* default unicast hop limit */O#define IPV6_DEFAULT_MULTICAST_HOPS 1 /* normally limit mcasts to 1 hop */P#define IPV6_DEFAULT_MULTICAST_LOOP 1 /* normally hear sends if a member */C#define IPV6_DEFAULT_MEMBERSHIPS 32 /* default per socket */?#define IPV6_MAX_MEMBERSHIPS 65536 /* max per socket *//* * Define the IPv6 address. */struct in6_addr { union { u_int8_t sa6_addr[16];#define s6_addr s6_un.sa6_addr u_int16_t sa6_waddr[8]; #define s6_waddr s6_un.sa6_waddr u_int32_t sa6_laddr[4]; #define s6_laddr s6_un.sa6_laddr#ifdef IN6_HAS_64BIT_INTTYPE u_int64_t sa6_qaddr[2]; #define s6_qaddr s6_un.sa6_qaddr#endif } s6_un;};/*0 * Maximum length of IPv6 address as text string */#define INET6_ADDRSTRLEN 46/*% * IPv6 protocol specific route flags */N#define IPV6_RTF_MINMTU RTF_PROTO2 /* mtu less then 1280, use frag hdr *//*+ * Structure for join/leave multicast group */struct ipv6_mreq {B struct in6_addr ipv6mr_multiaddr; /* IPv6 multicast address */7 unsigned int ipv6mr_interface; /* inteface index */};/*1 * Define the macros to manipulate IPv6 addresses */#ifdef IN6_HAS_64BIT_INTTYPEK#define IN6_ARE_ADDR_EQUAL(a,b) ((a)->s6_qaddr[1] == (b)->s6_qaddr[1] && \+ (a)->s6_qaddr[0] == (b)->s6_qaddr[0])f#define IN6_ARE_ADDR_SAMEPREFIX(a,b,m) (((a)->s6_qaddr[0] & (m)->s6_qaddr[0]) == (b)->s6_qaddr[0] && \@ ((a)->s6_qaddr[1] & (m)->s6_qaddr[1]) == (b)->s6_qaddr[1])P#define IN6_IS_ADDR_HOSTMASK(a) (((a)->s6_qaddr[0] & (a)->s6_qaddr[1]) == ~0UL)>#define IN6_IS_ADDR_LOOPBACK(a) ((a)->s6_qaddr[0] == 0UL && \@ (a)->s6_qaddr[1] == IN6__MK7_MSB64_VALUE(0,0,0,0,0,0,0,1))Q#define IN6_IS_ADDR_UNSPECIFIED(a) (((a)->s6_qaddr[0] | (a)->s6_qaddr[1]) == 0UL)E#define IN6_IS_ADDR_V4COMPAT(a) ((a)->s6_qaddr[0] == 0UL && \E (a)->s6_laddr[2] == 0 && \C (a)->s6_laddr[3] != 0 && \[ (a)->s6_laddr[3] != IN6__MK3_MSB32_VALUE(0,0,0,1))>#define IN6_IS_ADDR_V4MAPPED(a) ((a)->s6_qaddr[0] == 0UL && \; (a)->s6_laddr[2] == IN6__MK1_MSW32_VALUE(0, 0xFFFFU))O#define IN6_SET_ADDR_HOSTMASK(a) ((a)->s6_qaddr[1] = ((a)->s6_qaddr[0] = ~0UL));#define IN6_SET_ADDR_LOOPBACK(a) ((a)->s6_qaddr[0] = 0UL, \? (a)->s6_qaddr[1] = IN6__MK7_MSB64_VALUE(0,0,0,0,0,0,0,1))]#define IN6_SET_ADDR_PREFIX(a,b,c) ((a)->s6_qaddr[0] = (b)->s6_qaddr[0] & (c)->s6_qaddr[0], \= (a)->s6_qaddr[1] = (b)->s6_qaddr[1] & (c)->s6_qaddr[1])Q#define IN6_SET_ADDR_UNSPECIFIED(a) ((a)->s6_qaddr[1] = ((a)->s6_qaddr[0] = 0UL));#define IN6_SET_ADDR _V4MAPPED(a,b) ((a)->s6_qaddr[0] = 0, \< (a)->s6_laddr[2] = IN6__MK1_MSW32_VALUE(0, 0xFFFFU), \ (a)->s6_laddr[3] = (b));#define IN6_SET_ADDR_V4COMPAT(a,b) ((a)->s6_qaddr[0] = 0, \ (a)->s6_laddr[2] = 0, \ (a)->s6_laddr[3] = (b))\#define IN6_SET_LINKLOCAL_NETMASK(a) ((a)->s6_qaddr[0] = IN6__MK1_MSB64_VALUE(0xFF, 0xC0), \ (a)->s6_qaddr[1] = 0UL)_#define IN6_SET_LINKLOCAL_PREFIX(a) ((a)->s6_qaddr[0] = IN6__MK1_MSB64_VALUE(0xFE, 0x80), \@  (a)->s6_qaddr[1] = 0UL)B#define IN6_SET_LOWER_64_MASK(a) ((a)->s6_qaddr[0] = 0UL, \A (a)->s6_qaddr[1] = ~0UL):#define IN6_JOIN_PREFIX_TOKEN(a,p,t) ((a)->s6_qaddr[0] = \- (p)->s6_qaddr[0] | (t)->s6_qaddr[0], \ (a)->s6_qaddr[1] = \+ (p)->s6_qaddr[1] | (t)->s6_qaddr[1])#elseK#define IN6_ARE_ADDR_EQUAL(a,b) ((a)->s6_laddr[3] == (b)->s6_laddr[3] && \/ (a)->s6_laddr[0] == (b)->s6_laddr[0] && \/ (a)->s6_laddr[2] == (b)->s6_laddr[2] && \+ (a)->s6_laddr[1] == (b)->s6_laddr[1])f#define IN6_ARE_ADDR_SAMEPREFIX(a,b,m) (((a)->s6_laddr[0] & (m)->s6_laddr[0]) == (b)->s6_laddr[0] && \D ((a)->s6_laddr[1] & (m)->s6_laddr[1]) == (b)->s6_laddr[1] && \D ((a)->s6_laddr[2] & (m)->s6_laddr[2]) == (b)->s6_laddr[2] && \@ ((a)->s6_laddr[3] & (m)->s6_laddr[3]) == (b)->s6_laddr[3])?#define IN6_IS_ADDR_HOSTMASK(a) ((a)->s6_laddr[3] == ~0UL && \# (a)->s6_laddr[0] == ~0UL && \#  (a)->s6_laddr[2] == ~0UL && \ (a)->s6_laddr[1] == ~0UL)>#define IN6_IS_ADDR_LOOPBACK(a) ((a)->s6_laddr[0] == 0UL && \" (a)->s6_laddr[1] == 0UL && \" (a)->s6_laddr[2] == 0UL && \8 (a)->s6_laddr[3] == IN6__MK3_MSB32_VALUE(0,0,0,1))@#define IN6_IS_ADDR_UNSPECIFIED(a) ((a)->s6_laddr[3] == 0UL && \" (a)->s6_laddr[0] == 0UL && \" (a)->s6_laddr[2] == 0UL && \ (a)->s6_laddr[1] == 0UL)>#define IN6_IS_ADDR_V4COMPAT(a) ((a)->s6_laddr[0] == 0UL && \" (a)->s6_laddr[1] == 0UL && \E (a)->s6_laddr[2] == 0UL && \C (a)->s6_laddr[3] != 0 && \[ (a)->s6_laddr[3] != IN6__MK3_MSB32_VALUE(0,0,0,1))>#define IN6_IS_ADDR_V4MAPPED(a) ((a)->s6_laddr[0] == 0UL && \" (a)->s6_laddr[1] == 0UL && \; (a)->s6_laddr[2] == IN6__MK1_MSW32_VALUE(0, 0xFFFFU))y#define IN6_SET_ADDR_HOSTMASK(a) ((a)->s6_laddr[3] = ((a)->s6_laddr[2] = ((a)->s6_laddr[1] = ((a)->s6_laddr[0] = ~0UL))))e#define IN6_SET_ADDR_LOOPBACK(a) ((a)->s6_laddr[0] = ((a)->s6_laddr[1] = ((a)->s6_laddr[2] = 0UL)), \7 (a)->s6_laddr[3] = IN6__MK3_MSB32_VALUE(0,0,0,1))]#define IN6_SET_ADDR_PREFIX(a,b,c) ((a)->s6_laddr[0] = (b)->s6_laddr[0] & (c)->s6_laddr[0], \? (a)->s6_laddr[1] = (b)->s6_laddr[1] & (c)->s6_laddr[1], \? (a)->s6_laddr[2] = (b)->s6_laddr[2] & (c)->s6_laddr[2], \= (a)->s6_laddr[3] = (b)->s6_laddr[3] & (c)->s6_laddr[3]){#define IN6_SET_ADDR_UNSPECIFIED(a) ((a)->s6_laddr[3] = ((a)->s6_laddr[2] = ((a)->s6_laddr[1] = ((a)->s6_laddr[0] = 0UL))))Q#define IN6_SET_ADDR_V4MAPPED(a,b) ((a)->s6_laddr[0] = 0, (a)->s6_laddr[1] = 0, \< (a)->s6_laddr[2] = IN6__MK1_MSW32_VALUE(0, 0xFFFFU), \ (a)->s6_laddr[3] = (b))Q#define IN6_SET_ADDR_V4COMPAT(a,b) ((a)->s6_laddr[0] = 0, (a)->s6_laddr[1] = 0, \ (a)->s6_laddr[2] = 0, \ (a)->s6_laddr[3] = (b))\#define IN6_SET_LINKLOCAL_NETMASK(a) ((a)->s6_laddr[0] = IN6__ MK1_MSB32_VALUE(0xFF, 0xC0), \ (a)->s6_laddr[1] = 0, \ (a)->s6_laddr[2] = 0, \ (a)->s6_laddr[3] = 0)_#define IN6_SET_LINKLOCAL_PREFIX(a) ((a)->s6_laddr[0] = IN6__MK1_MSB32_VALUE(0xFE, 0x80), \@ (a)->s6_laddr[1] = 0, \@ (a)->s6_laddr[2] = 0, \> (a)->s6_laddr[3] = 0)@#define IN6_SET_LOWER_64_MASK(a) ((a)->s6_laddr[0] = 0, \@  (a)->s6_laddr[1] = 0, \_ (a)->s6_laddr[2] = IN6__MK1_MSB32_VALUE(0xFF, 0xFF), \] (a)->s6_laddr[3] = IN6__MK1_MSB32_VALUE(0xFF, 0xFF)):#define IN6_JOIN_PREFIX_TOKEN(a,p,t) ((a)->s6_laddr[0] = \- (p)->s6_laddr[0] | (t)->s6_laddr[0], \ (a)->s6_laddr[1] = \- (p)->s6_laddr[1] | (t)->s6_laddr[1], \ (a)->s6_laddr[2] = \- (p)->s6_laddr[2] | (t)->s6_laddr[2], \ (a)->s6_laddr[3] = \+ (p)->s6_laddr[3] | (t)->s6_laddr[3])#endif1#define IN6_EXTRACT_V4ADDR(a) ((a)->s6_laddr[3])P#define IN6_EXTRACT_V4ADDR_624(a) (IN6__MK1_MSW32_VALUE((a)->s6_waddr[1],\P (a)->s6_waddr[2]))|#define IN6_IS_ADDR_LINKLOCAL(a) (((a)->s6_laddr[0] & IN6__MK1_MSB32_VALUE(0xFF, 0xC0)) == IN6__MK1_MSB32_VALUE(0xFE, 0x80))|#define IN6_IS_ADDR_SITELOCAL(a) (((a)->s6_laddr[0] & IN6__MK1_MSB32_VALUE(0xFF, 0xC0)) == IN6__MK1_MSB32_VALUE(0xFE, 0xC0))p#define IN6_IS_ADDR_MULTICAST(a) (((a)->s6_laddr[0] & IN6__MK0_MSB32_VALUE(0xFF)) == IN6__MK0_MSB32_VALUE(0xFF))#define IN6_IS_ADDR_MC_NODELOCAL(a) (((a)->s6_laddr[0] & IN6__MK1_MSB32_VALUE(0xFF, 0x0F)) == IN6__MK1_MSB32_VALUE(0xFF, IN6_MCSCOPE_NODELOCAL))#define IN6_IS_ADDR_MC_LINKLOCAL(a) (((a)->s6_laddr[0] & IN6__MK1_MSB32_VALUE(0xFF, 0x0F)) == IN6__MK1_MSB32_VALUE(0xFF, IN6_MCSCOPE_LINKLOCAL))#define IN6_IS_ADDR_MC_SITELOCAL(a) (((a)->s6_laddr[0] & IN6__MK1_MSB32_VALUE(0xFF, 0x0F)) == IN6__MK1_MSB32_VALUE(0xFF, IN6_MCSCOPE_SITELOCAL))#define IN6_IS_ADDR_MC_ADMINLOCAL(a) (((a)->s6_laddr[0] & IN6__MK1_MSB32_VALUE(0xFF, 0x0F)) == IN6__MK1_MSB32_VALUE(0xFF, IN6_MCSCOPE_ADMINLOCAL))#define IN6_IS_ADDR_MC_ORGLOCAL(a) (((a)->s6_laddr[0] & IN6__MK1_MSB32_VALUE(0xFF, 0x0F)) == IN6__MK1_MSB32_VALUE(0xFF, IN6_MCSCOPE_ORGLOCAL))#define IN6_IS_ADDR_MC_GLOBAL(a) (((a)->s6_laddr[0] & IN6__MK1_MSB32_VALUE(0xFF, 0x0F)) == IN6__MK1_MSB32_VALUE(0xFF, IN6_MCSCOPE_GLOBAL))[#define IN6_SET_LINKLOCAL_PREFIX(a) ((a)->s6_laddr[0] = IN6__MK1_MSB32_VALUE(0xFE, 0x80), \E (a)->s6_laddr[1] = ((a)->s6_laddr[2] = ((a)->s6_laddr[3] = 0)))-#define IPV6ADDR_LINKLOCAL_ALL_NODES_INIT { \% 0xFF, IN6_MCSCOPE_LINKLOCAL, 0, 0, \ 0, 0, 0, 0, \ 0, 0, 0, 0, \ 0, 0, 0, 1 \ }/#define IPV6ADDR_LINKLOCAL_ALL_ROUTERS_INIT { \% 0xFF, IN6_MCSCOPE_LINKLOCAL, 0, 0, \ 0, 0, 0, 0, \ 0, 0, 0, 0, \ 0, 0, 0, 2 \ })extern const struct in6_addr in6 addr_any;K#define IN6ADDR_ANY_INIT { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }B#define IN6ADDR_TLA624_INIT { 0x20, 0x02, /* IANA defined TLA */ \? 0, 0, 0, 0, /* NLA == V4ADDR */ \8 0, 0, /* SLA ID */ \I 0, 0, 0, 0, 0, 0, 0, 0 /* interface id */ }E#define IN6ADDR_TLA624_PFXMASK {0xFF, 0xFF, 0, 0, 0, 0, 0, 0, 0, 0, \2 0, 0, 0, 0, 0, 0 }.extern const struct in6_addr in6addr_loopback;!#define IN6ADDR_LOOPBACK_INIT { \ 0, 0, 0, 0, \ 0, 0, 0, 0, \ 0, 0, 0, 0, \ 0, 0, 0, 1 \ }q#define IN6ADDR_HOMEAGENT_ANYCAST_INIT { 0, 0, 0, 0, 0, 0, 0, 0, 0xFD, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFE }/* * IPv6 multicast scope. */"#define IN6_MCSCOPE_NODELOCAL 0x01"#define IN6_MCSCOPE_LINKLOCAL 0x02$#define IN6_MCSCOPE_ADMINLOCAL 0x04"#define IN6_MCSCOPE_SITELOCAL 0x05!#define IN6_MCSCOPE_ORGLOCAL 0x08#define IN6_MCSCOPE_GLOBAL 0x0E!#define IN6_MCFLAG_PERMANENT 0x00!#define IN6_MCFLAG_TRANSIENT 0x10#ifdef IN6_HAS_64BIT_INTTYPE/#define IN6_SET_MULTICAST_CLASS(addrp, class) \I ((void) (*(u_int64_t *) (addrp) = IN6__MK1_MSB64_VALUE(0xFF, class)))#else/#define IN6_SET_MULTICAST_CLASS(addrp, class) \a ((void) ((addrp)->s6_laddr[0] = IN6__MK1_MSB32_VALUE(0xFF, class), (addrp)->s6_laddr[1] = 0))#endif/* forward decls for C++ */#ifdef __cplusplusstruct rtentry;#endif/*6** The TCP/IP V5.4 and prior kernel checks for strict1** equality sizeof(struct sockaddr_in6) == 28. 6** __nomember_alignment allows this check to pass for=** scalar variables. However arrays of struct sockaddr_in6 :** will cause compiler messages and must be avoided with 8** this file. Fortunately such arrays are not a common** programming practice.***//*% * Define the socket address for IPv6 */struct sockaddr_in6 {#if defined(_SOCKADDR_LEN)#define SIN6_LEN5 u_char sin6_len; /* length of this struct */* u_char sin6_family; /* AF_INET6 */#else. u_int16m_t sin6_family; /* AF_INET6 */#endif; u_int16m_t sin6_port; /* Transport layer port # */= u_int32m_t sin6_flowinfo; /* IPv6 flow information */2 struct in6_addr sin6_addr; /* IPv6 address */K u_int32m_t sin6_scope_id; /* set of interfaces for a scope */};/*J * ioctl handles up to 128 bytes on stack. The max amount of generic dataJ * this structur e can hold is carefully chosen so the entire ip6ifreq doesK * not exceed 128 bytes, thus avoiding a kalloc(). The max size of a link-F * layer address is smaller to account for a 16 byte IPv6 address, the * lladdrlen and the radv_flags. */B#define IFR6_MAX_DATA 88 /* max generic data in ip6ifreq */I#define IFR6_MAX_LLADDR 63 /* max link-layer address in un_lladdr *//*E * Define the structure used for interface ioctls with IPv6 addresses *B * Caution: some code expect s the first portion of the ip6ifreq toC * be identical to an ifreq (i.e. the union containing the sockaddr7 * structures et al. must immediately follow ifr6_name) */struct ip6ifreq {J char ifr6_name[IFNAMSIZ]; /* i/f name, e.g. "ln0" */ union {= struct sockaddr un_addr; /* address */= struct sockaddr_in un_addr4; /* address */= struct sockaddr_in6 un_addr6; /* address */ struct {N  __size_t un_datalen; /* generic data len */J char un_data[IFR6_MAX_DATA]; /* generic data */ } un_1; struct {F __u_int un_value; /* generic value... */A int un_code; /* generic ... */ } un_2; struct {N struct in6_addr un_dst; /* IPv6 address */O __size_t un_lladdrlen; /* link addr len */K char un_lladdr[IFR6_MAX_LLADDR]; /* link addr */L uint8_t un_radv_flags; /* radv flags */ } un_3; struct {E struct in6_addr un_liid; /* local intf id */M struct in6_addr un_riid; /* remote intf id for ppp6 */ } un_4; struct {< struct in6_addr un_prefix; /* prefix */C uint8_t un_prefixlen; /*  prefix length */= uint8_t un_pad_5_1; /* padding */N uint16_t un_prefixflags; /* flags (see ip6_mobile.h) */= uint16_t un_pad_5_2; /* padding */K uint32_t un_validlife; /* valid prefix lifetime */P uint32_t un_preferredlife;/* preferred prefix lifetime */ } un_5; } ifr6_un;'#define ifr6_addr ifr6_un.un_addr(#define ifr6_addr4 ifr6_un.un_addr4( #define ifr6_addr6 ifr6_un.un_addr6/#define ifr6_datalen ifr6_un.un_1.un_datalen,#define ifr6_data ifr6_un.un_1.un_data-#define ifr6_value ifr6_un.un_2.un_value,#define ifr6_code ifr6_un.un_2.un_code+#define ifr6_dst ifr6_un.un_3.un_dst2#define ifr6_radv_flags ifr6_un.un_3.un_radv_flags1#define ifr6_lladdrlen ifr6_un.un_3.un_lladdrlen.#define ifr6_lladdr ifr6_un.un_3.un_lladdr,#define ifr6_lid ifr6_un.un_4.un_liid,#define ifr6_rid ifr6_u n.un_4.un_riid.#define ifr6_prefix ifr6_un.un_5.un_prefix1#define ifr6_prefixlen ifr6_un.un_5.un_prefixlen4#define ifr6_prefixflags ifr6_un.un_5.un_prefixflags1#define ifr6_validlife ifr6_un.un_5.un_validlife=#define ifr6_preferredlife ifr6_un.un_5.un_preferredlife5 unsigned ifr6_flags; /* */Z#define IFR6_NODAD 0x0001U /* suppress duplicate address detection */P#define IFR6_ADDTOKEN 0x0002U /* add token to end of  prefix */'#define IFR6_DADFAILED 0x0004U'#define IFR6_DADINPROGRESS 0x0008U'#define IFR6_DEPRECATED 0x0010UH#define IFR6_ANYCAST 0x0020U /* address is anycast */J#define IFR6_PROXY 0x0040U /* proxying for address */N#define IFR6_MOBILE 0x0080U /* mobile node home address */D __u_int ifr6_reserved[3]; /* for future use */};/*= * Define the structure that is added as a control message to8 * incoming raw packets before being handed to the user. */struct rip6_header {9 int rhdr_ifindex; /* ifnet index number */C int rhdr_pktflags; /* The mbuf flags (M_MCAST etc) */A u_short rhdr_offset; /* data offset in IPv6 packet */8 u_char rhdr_proto; /* The protocol type */H u_char rhdr_authOK; /* TRUE if the pkt was authenticated */};/* * advance API defines (rfc2292) */struct in6_pktinfo {1 struct in6_addr ipi6_addr; /* IPv6 address */= unsigned int ipi6_ifindex; /* interface index */};struct ip6_mtuinfo {F struct sockaddr_in6 ip6m_addr; /* IPv6 destination address */6 uint32_t ip6m_mtu; /* path mtu */};/** * Define constants for the routing header */D#define IPV6_RTHDR_LOOSE 0 /* this hop need not be a neighbor */@#define IPV6_RTHDR_STRICT 1 /* this hop must be a neighbor */?#define IPV6_RTHDR_TYPE_0 0 /* IPv6 Routing header type 0 */?#define IPV6_RTHDR_TYPE_2 2 /* IPv6 Routing header type 2 *//* * function and macro prototypes */1extern int inet6_opt_init (void*, __size_t);Lextern int inet6_opt_append (void *, __size_t, int, u_int8_t, __size_t,9 u_int32_t, void **);9extern int inet6_opt_finish (void *, __size_t, int);Bextern int inet6_opt_set_val (void *, __size_t, void *, int);Nextern int inet6_opt_next (void *, __size_t, int,  u_int8_t *, __size_t *,, void **);Lextern int inet6_opt_find (void *, __size_t, int, u_int8_t, __size_t *,, void **);Bextern int inet6_opt_get_val (void *, __size_t, void *, int);+extern __size_t inet6_rth_space (int, int);7extern void * inet6_rth_init (void *, int, int, int);@extern int inet6_rth_add (void *, const struct in6_addr *);9extern int inet6_rth_reverse (const void *, void *);2extern int inet6_rth_segments (const void *);@extern struct in6_addr * inet6_rth_getaddr (void *, int);/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#pragma __standard#endif /* __IN6_LOADED */ww0ԗ#ifndef __IN6_MACHTYPES_LOADED #define __IN6_MACHTYPES_LOADED 1M/********************************************************* *********************3** - Internet V6 protocol family**M******************************************************************************* Header is nonstandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license.  I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include /*3 * Machine or architecure specific MACROS and types * for IPv6. */#include #ifndef OPENVMS_32BIT#if !defined(__VAX)#define IN6_HAS_64BIT_INTTYPE#endif#endif7#if !defined(BYTE_ORDER) || BYTE_ORDER == LITTLE_ENDIAN#define IN6_MSB16_SHIFT 0#define IN6_MSB32_SHIFT 0#define IN6_MSW32_SHIFT 0#define IN6_BIT_ORDER +1#ifdef IN6_HAS_64BIT_INTTYPE#define IN6_MSB64_SHIFT 0#define IN6_MSW64_SHIFT 0#define IN6_MSL64_SHIFT 0#endif#elif BYTE_ORDER == BIG_ENDIAN"#define IN6_MSB16_SHIFT (16 - 8)"#define IN6_MSB32_SHIFT (32 - 8)##define IN6_MSW32_SHIFT (32 - 16)#define IN6_BIT_ORDER -1#ifdef  IN6_HAS_64BIT_INTTYPE"#define IN6_MSB64_SHIFT (64 - 8)##define IN6_MSW64_SHIFT (64 - 16)##define IN6_MSL64_SHIFT (64 - 32)#endif#endif#ifdef IN6_HAS_64BIT_INTTYPEJ#define IN6_MSB64_OFFSET(n) (IN6_MSB64_SHIFT + ((n) * IN6_BIT_ORDER * 8))K#define IN6_MSW64_OFFSET(n) (IN6_MSB64_SHIFT + ((n) * IN6_BIT_ORDER * 16))K#define IN6_MSL64_OFFSET(n) (IN6_MSB64_SHIFT + ((n) * IN6_BIT_ORDER * 32))-#define IN6_LSB64_SHIFT IN6_MSB64_OFFSET(7)-#define IN6_LSW64_SHIFT IN6_MSW64_OFFSET(3)-#define IN6_LSL64_SHIFT IN6_MSL64_OFFSET(1)M#define IN6__MK0_MSB64_VALUE(a) ( ((u_int64_t) (a)) << IN6_MSB64_OFFSET(0))g#define IN6__MK1_MSB64_VALUE(a,b) ((((u_int64_t) (b)) << IN6_MSB64_OFFSET(1))|IN6__MK0_MSB64_VALUE(a))k#define IN6__MK2_MSB64_VALUE(a,b,c) ((((u_int64_t) (c)) << IN6_MSB64_OFFSET(2))|IN6__MK1_MSB64_VALUE(a,b))o#define IN6__MK3_MSB64_VALUE(a,b,c,d) ((((u_int64_t) (d)) << IN6_MSB64_OFFSET(3))|IN6__MK2_MSB64_VALUE(a,b,c))s#define IN6__MK4_MSB64_VALUE(a,b,c,d,e)  ((((u_int64_t) (e)) << IN6_MSB64_OFFSET(4))|IN6__MK3_MSB64_VALUE(a,b,c,d))v#define IN6__MK5_MSB64_VALUE(a,b,c,d,e,f) ((((u_int64_t) (f)) << IN6_MSB64_OFFSET(5))|IN6__MK4_MSB64_VALUE(a,b,c,d,e))z#define IN6__MK6_MSB64_VALUE(a,b,c,d,e,f,g) ((((u_int64_t) (g)) << IN6_MSB64_OFFSET(6))|IN6__MK5_MSB64_VALUE(a,b,c,d,e,f))~#define IN6__MK7_MSB64_VALUE(a,b,c,d,e,f,g,h) ((((u_int64_t) (h)) << IN6_MSB64_OFFSET(7))|IN6__MK6_MSB64_VALUE(a,b,c,d,e,f,g))L#define IN6__MK0_MSW64_VALUE(a) ( ((u_int64_t) (a)) << IN6_MSW64_OFFSET(0))f#define IN6__MK1_MSW64_VALUE(a,b) ((((u_int64_t) (b)) << IN6_MSW64_OFFSET(1))|IN6__MK0_MSW64_VALUE(a))j#define IN6__MK2_MSW64_VALUE(a,b,c) ((((u_int64_t) (c)) << IN6_MSW64_OFFSET(2))|IN6__MK1_MSW64_VALUE(a,b))n#define IN6__MK3_MSW64_VALUE(a,b,c,d) ((((u_int64_t) (d)) << IN6_MSW64_OFFSET(3))|IN6__MK2_MSW64_VALUE(a,b,c))M#define IN6__MK0_MSL64_VALUE(a) ( ((u_int64_t) (a)) << IN6_MSL64_OFFSET(0) )f#define IN6__MK1_MSL64_VALUE(a,b) ((((u_int64_t) (b)) << IN6_MSL64_OFFSET(1) )|IN6__MK0_MSL64_VALUE(a))#endifJ#define IN6_MSB32_OFFSET(n) (IN6_MSB32_SHIFT + ((n) * IN6_BIT_ORDER * 8))K#define IN6_MSW32_OFFSET(n) (IN6_MSB32_SHIFT + ((n) * IN6_BIT_ORDER * 16))-#define IN6_LSB32_SHIFT IN6_MSB32_OFFSET(3)-#define IN6_LSW32_SHIFT IN6_MSW32_OFFSET(1)M#define IN6__MK0_MSB32_VALUE(a) ( ((u_int32_t) (a)) << IN6_MSB32_OFFSET(0) )f#define IN6__MK1_MSB32_VALUE(a,b) ((((u_int32_t) (b)) << IN6_MSB32_OFFSET(1))|IN6__MK0_MSB32_VALUE(a))j#define IN6__MK2_MSB32_VALUE(a,b ,c) ((((u_int32_t) (c)) << IN6_MSB32_OFFSET(2))|IN6__MK1_MSB32_VALUE(a,b))n#define IN6__MK3_MSB32_VALUE(a,b,c,d) ((((u_int32_t) (d)) << IN6_MSB32_OFFSET(3))|IN6__MK2_MSB32_VALUE(a,b,c))M#define IN6__MK0_MSW32_VALUE(a) (( (u_int32_t) (a)) << IN6_MSW32_OFFSET(0) )f#define IN6__MK1_MSW32_VALUE(a,b) ((((u_int32_t) (b)) << IN6_MSW32_OFFSET(1))|IN6__MK0_MSW32_VALUE(a))/* * Macros for 16 bit words. */J#define IN6_MSB16_OFFSET(n) (IN6_MSB16_SHIFT + ((n) * IN6_BIT_ORDER * 8))-#define IN6_LSB16_SHIFT IN6_MSB16_OFFSET(1)L#define IN6__MK0_MSB16_VALUE(a) ( ((u_int16_t) (a)) << IN6_MSB16_OFFSET(0))f#define IN6__MK1_MSB16_VALUE(a,b) ((((u_int16_t) (b)) << IN6_MSB16_OFFSET(1))|IN6__MK0_MSB16_VALUE(a))#pragma __standard#endif /* _IN6_MACHTYPES_H */ww<0ԗ#ifndef __INET_LOADED#define __INET_LOADED 1M/******************************************************************************** - Internet access**M*****************************************************************************I** Header introduced by the X/Open CAE Specification, Issue 4, Version 2M*****************************************************************************I** I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I**  I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty.   I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*E** All includes of other header files must be done prior to altering** the pointer size mode. */#include /*.** Start processing in 32-bit addressing mode*/#i f __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*7** Set __nomember_alignment to avoid internal and tail2** padding in structures; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment/* ** Define XPG4 IP typedefs*/4#if !defined __IN_PORT_T && !defined _DECC_V4_SOURCE# define __IN_PORT_T 1" typedef __in_port_t in_port_t;#e ndif5#if !defined __IN_ADDR_T && !defined _DECC_V4_SOURCE# define __IN_ADDR_T 1" typedef __in_addr_t in_addr_t;#endif/*9** Internet address (a structure for historical reasons)*/#ifndef __IN_ADDR# define __IN_ADDR 1 struct in_addr { union {B struct { unsigned char s_b1,s_b2,s_b3,s_b4; } S_un_b;B struct { unsigned short s_w1,s_w2; } S_un_w;! unsigned long S_addr;#ifdef _XOPEN_SOURCE __in_addr_t S_ad dr_xopen;#endif } S_un;};#ifdef _XOPEN_SOURCEB# define s_addr S_un.S_addr_xopen /* X/Open version of s_addr */#elseL# define s_addr S_un.S_addr /* can be used for most tcp & ip code */#endif7# define s_host S_un.S_un_b.s_b2 /* host on imp */7# define s_net S_un.S_un_b.s_b1 /* network */7# define s_imp S_un.S_un_w.s_w2 /* imp */7# define s_impno S_un.S_un_b.s_b4 /* imp # */7# define s_lh S_un.S_un_b.s_b3 /* logical host  */#endif/*:** The following function always returns a 32 bit pointer*/'char *inet_ntoa (struct in_addr __in); #if __INITIAL_POINTER_SIZE #pragma __pointer_size __restore#endif/*9** All other functions accept 32 bit or 64 bit pointers.*/+__in_addr_t htonl (__in_addr_t __hostlong);,__in_port_t htons (__in_port_t __hostshort);*__in_addr_t ntohl (__in_addr_t __netlong);+__in_port_t ntohs (__in_port_t __netshort);3__in_addr_t inet_addr (__const_char_ptr64 __cp);3__in_addr_t inet_network (__const_char_ptr64 __cp);/__in_addr_t inet_lnaof (struct in_addr __in);/__in_addr_t inet_netof (struct in_addr __in);/*8** The new definition of inet_makeaddr() is incompatible** with the implementation4** __in_addr_t inet_makeaddr (__u_long, __u_long);*/Dstruct in_addr inet_makeaddr (__in_addr_t __net, __in_addr_t __lna);@int inet_aton (__const_char_ptr64, struct in_addr *);/*>** Functions inet_pton() and inet_ntop() do not support 64-bitA** pointers in versions of DECC$SHR prior to __CRTL_VER 70312000.*/3#if __INITIAL_POINTER_SIZE && __CRTL_VER < 70312000G int inet_pton (int, __const_char_ptr32, __void_ptr32);Q __const_char_ptr32 inet_ntop (int, __const_void_ptr32, __char_ptr32, __size_t);#elseA int inet_pton (int, __const_char_ptr64, __void_ptr64);E const char * inet_ntop (int, __const_void_ptr64, char *, __size_t);#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#pragma __standard#endif /* __INET_LOADED */ww0ԗ#ifndef __INTS_LOADED#define __INTS_LOADED 1M/******************************************************************************?** - Definitions for platform specific integer types **M******************************************************************************* Header is nonstandardM*****************************************************************************I**  I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" wi thout warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard/*E** Ensure that the compiler will not emit diagnostics about "signed"J** keyword usage when in /STAND=VAXC mode (the reason for the diagnostics7** is that VAX C does not support the signed keyword).*/4#if ((__DECC_VER >= 50600000) && !defined(__DECCXX))# pragma __message __save.# pragma __message __disable (__SIGNEDKNOWN) typedef signed char int8; typedef unsigned char uint8;# pragma __message __restore#else typedef signed char int8;  typedef unsigned char uint8;#endif/*&** Define 16 and 32 bit integer types*/=#if defined(__DECC) || (defined(__DECCXX) && !defined(__VAX))# typedef __int16 int16;$ typedef unsigned __int16 uint16;# typedef __int32 int32;$ typedef unsigned __int32 uint32;#else% typedef short int int16;& typedef unsigned short int uint16; typedef int int32; typedef unsigned int uint32;#endif/*-** Define 64 bit integer types only on Alpha*/#if !defined(__VAX)# typedef __int64 int64;$ typedef unsigned __int64 uint64;#endif#pragma __standard#endif /* __INTS_LOADED */ww%0ԗ#ifndef __INTTYPES_LOADED#define __INTTYPES_LOADEDM/******************************************************************************?** - Definitions for platform specific integer types **M*****************************************************************************>** Header introduced by the X/Open CAE Specification, Issue 5M*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying.  I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I**  M******************************************************************************/#pragma __nostandard/*E** Ensure that the compiler will not emit diagnostics about "signed"J** keyword usage when in /STAND=VAXC mode (the reason for the diagnostics7** is that VAX C does not support the signed keyword).*/4#if ((__DECC_VER >= 50600000) && !defined(__DECCXX))# pragma __message __save.# pragma __message __disable (__SIGNEDKNOWN)#endif/*;** Define integral 8-bit, 16-bit, 32-bit, and 64-bit types*/typedef signed char int8_t;typedef unsigned char uint8_t;typedef short int int16_t;$typedef unsigned short int uint16_t;typedef int int32_t;typedef unsigned int uint32_t;/*K** The VAX implementation is just a placeholder until the C9X work is done*/#if !defined(__VAX) typedef __int64 int64_t;% typedef unsigned __int64 uint64_t;#else2 typedef struct { int __p1; int __p2; } int64_t;E typedef struct { unsigned int __p1; unsigned int __p2; } uint64_t;#endif/*G** Declare [un]signed integral types large enough to hold any pointer.*/#if !defined(__VAX) typedef int64_t intptr_t; typedef uint64_t uintptr_t;#else typedef int32_t intptr_t; typedef uint32_t uintptr_t;#endif/*** Restore messages*/4#if ((__DECC_VER >= 50600000) && !defined(__DECCXX))# pragma __message __restore#endif#pragma __standard#endif /* __INTTYPES_LOADED */wwJ0ԗ#ifndef __IOCTL_LOADED#define __IOCTL_LOADEDM/******************************************************************************.** - I/O controls for special files**M******************************************************************************* Header is nonstandardM*******************************************************************************M** Copyright Digital Equipment Corporation 1993, 1997. All rights reserved.**B ** Restricted Rights: Use, duplication, or disclosure by the U.S.F** Government is subject to restrictions as set forth in subparagraphF** (c) (1) (ii) of DFARS 252.227-7013, or in FAR 52.227-19, or in FAR&** 52.227-14 Alt. III, as applicable.**A** This software is proprietary to and embodies the confidentialD** technology of Digital Equipment Corporation. Possession, use, orG** copying of this software and media is authorized only pursuant to aD** valid written license from Digital or an authorized sublicensor.**N********************************************************************************E** Copyright (c) 1982, 1994 Regents of the University of California.A** All rights reserved. The Berkeley software License Agreement:** specifies the terms and conditions for redistribution.**/** ioctl.h 8.6 (Berkeley) 3/28/94**N*******************************************************************************/ N#include /* Introduced in  X/Open CAE Specification, Issue 4 */#endif /* __IOCTL_LOADED */wwo0ԗ#ifndef __IPC_LOADED#define __IPC_LOADEDM/******************************************************************************'** - System V IPC system calls**M*****************************************************************************I** I** Copyright 2009 Hewlett-Packard Development Company, L.P. I**! I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under v"endor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the ex#press limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard #include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __poi$nter_size __save# pragma __pointer_size 64#endif1#if !defined __KEY_T && !defined _DECC_V4_SOURCE# define __KEY_T 1 typedef __key_t key_t;#endif1#if !defined __UID_T && !defined _DECC_V4_SOURCE# define __UID_T 1 typedef __uid_t uid_t;#endif1#if !defined __GID_T && !defined _DECC_V4_SOURCE# define __GID_T 1 typedef __gid32_t gid_t;#endif2#if !defined __MODE_T && !defined _DECC_V4_SOURCE# define __MODE_T 1 typedef __mode_t mode_t; #e%ndif/* Mode bits for `semget' */@#define IPC_CREAT 01000 /* Create key if key does not exist. */2#define IPC_EXCL 02000 /* Fail if key exists. */6#define IPC_NOWAIT 04000 /* Return error on wait. */%/* Control commands for `semctl' */-#define IPC_RMID 0 /* Remove identifier. */2#define IPC_SET 1 /* Set `ipc_perm' options. */2#define IPC_STAT 2 /* Get `ipc_perm' options. */$#define IPC_INFO 3 /* See ipcs. *//* Special key values. */3#define IPC_PRIVATE ((ke&y_t) 0) /* Private key. */L/* Data structure used to pass permission information to IPC operations. */struct ipc_perm {, __uid_t uid; /* Owner's user ID. */- __gid32_t gid; /* Owner's group ID. *// __uid_t cuid; /* Creator's user ID. */0 __gid32_t cgid; /* Creator's group ID. */2 __mode_t mode; /* Read/write permission. *// unsigned short int __unused1; /* Padding */ };+/* Generates key for System V style IPC. */2key_t ftok(const c'har *__pathname, int __proj_id);/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __IPC_LOADED */wwG1ԗ#ifndef __ISO646_LOADED#define __ISO646_LOADEDM/******************************************************************************9** - Alternative spelling for language tokens**M**************************************(***************************************:** Header introduced by Amendment 1 of the ISO C StandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries )required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** * I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. + I** M******************************************************************************/#pragma __nostandard/*O** According to the C++ standard clause 2.5 - Alternative tokens [lex.digraph],M** alternative tokens below are reserved words. For a C++ compilation, defineB** them as macros only when ALTERNATIVE_TOKENS option is disabled.*/?#if !defined(__NAMESPACE_STD) || !defined(__ALTE,RNATIVE_TOKENS)#define and &&#define and_eq &=#define bitand &#define bitor |#define compl ~ #define not !#define not_eq != #define or ||#define or_eq |= #define xor ^#define xor_eq ^=#endif#pragma __standard#endif /* __ISO646_LOADED */wwm1ԗ#ifndef __LANGINFO_LOADED#define __LANGINFO_LOADED 1#pragma __nostandard#include N#if __CRTL_VER >= 60200000 /**** Supported starting with OpenVMS V6.2 ****/M/*************** -***************************************************************1** - language information constants**M*****************************************************************************>** Header introduced by the X/Open CAE Specification, Issue 4M*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** . I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendo/r's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the expres0s limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#ifdef __cplusplus extern "C" {#endif#include #if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma1 __pointer_size 32#endif /* 9** Constants for items returned by nl_langinfo() routine*/N#define CODESET 0 /* Codeset name *//* $** Date and time formatting strings*/N#define D_T_FMT 1 /* String for formatting date and time */N#define D_FMT 2 /* Date format string */N#define T_FMT 3 /* Time format string *//*** AM2/PM strings*/N#define AM_STR 4 /* Ante Meridian affix */N#define PM_STR 5 /* Post Meridian affix *//*.** Names of the days of the week in full form** Note: Must be consecutive*/#define DAY_1 6#define DAY_2 7#define DAY_3 8#define DAY_4 9#define DAY_5 10#define DAY_6 11#define DAY_7 12/*5** Names of the days of the week in abbreviat3ed form** Note: Must be consecutive*/#define ABDAY_1 13#define ABDAY_2 14#define ABDAY_3 15#define ABDAY_4 16#define ABDAY_5 17#define ABDAY_6 18#define ABDAY_7 19/*0** Names of the months of the year in full form** Note: Must be consecutive*/#define MON_1 20#define MON_2 21#define MON_3 22#define MON_4 23#define MON_5 24#define MON_6 25#define MON_7 26#d4efine MON_8 27#define MON_9 28#define MON_10 29#define MON_11 30#define MON_12 31/*7** Names of the months of the year in abbreviated form** Note: Must be consecutive*/#define ABMON_1 32#define ABMON_2 33#define ABMON_3 34#define ABMON_4 35#define ABMON_5 36#define ABMON_6 37#define ABMON_7 38#define ABMON_8 39#define ABMON_9 40#define ABMON_10 41#define ABMON_151 42#define ABMON_12 43/*** From LC_NUMERIC*/N#define RADIXCHAR 44 /* Decimal point string */N#define THOUSEP 45 /* Thousands separator string *//* ** From LC_MESSAGES*/N#define YESSTR 46 /* Affirmative response string */N#define NOSTR 47 /* Negative response string */N#define CRNCYSTR 48 /* Currency symbol 6 *//*** Items that are new to XPG4*/N#define T_FMT_AMPM 49 /* Time format with AM/PM string */N#define ERA 50 /* Era strings */N#define ERA_D_FMT 51 /* Era date format string */N#define ALT_DIGITS 52 /* Alternative symbols for digits */N#define YESEXPR 53 /* Affirmative response expression */N#define NOEXPR 54 /* Negative response expr 7ession */N#define ERA_T_FMT 55 /* Locale's alternative time format, */N /* corresponding to the %EX field descriptor */N#define ERA_D_T_FMT 56 /* Locale's alternative date and time format, */N /* corresponding to the %Ec field descriptor *//*K** The function nl_langinfo() returns a pointer to memory allocated by theI** DEC C RTL. Ensure that regardless of user /pointer_size usage, this8 '** pointer is always a 32 bit pointer.*/"char *nl_langinfo(nl_item __item);#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif##endif /* OpenVMS V6.2 or later */#pragma __standard#endif /* __LANGINFO_LOADED */ww(1ԗ#ifndef __LIBGEN_LOADED#define __LIBGEN_LOADEDM/******************************************************************************&** - Filename manipulation**M********** 9*********************************************************************I** Header introduced by the X/Open CAE Specification, Issue 4, Version 2**K** Definitions in this header file may not be available on all versions ofK** OpenVMS. See the DEC C Runtime Library reference manual for specifics.**M*****************************************************************************I** I** Copyright 2003 Hewlett-Packard :Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items a;re licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for <HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif=/*N** If the user has used /pointer_size, we will save our current pointer size.*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save#endif/*** Function prototypes*/char * basename (char *);char * dirname (char *);/*K** Under the following conditions, we also define the _xxx32/64 interfaces*/>#if __INITIAL_POINTER_SIZE && !defined(_XOPEN_SOURCE_EXTENDED)# pragma __pointer_size 32 char * _basename32 (char *); char * _dirname32 (char *);># pragma __pointer_size 64 char * _basename64 (char *); char * _dirname64 (char *);#endif/*-** Restore the original pointer size context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __LIBGEN_LOADED */wwM1ԗ#ifndef __LIMITS_LOADED#define __LIMITS_LOADED 1M/******************************************************************************(** ? - Sizes of integral types**M*****************************************************************************,** Header introduced by the ANSI C StandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Vali@d license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** A I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constit Buting an I** additional warranty. I** M*****************************************************************************(** NoteN********************************************************************************J** Section 2.2.4.2 of the Rationale states "The limits for the maxima andD** minima of unsigned types are specified as unsigned const Cants..."**L** The alert reader will notice there are no minima for the unsigned types,5** but we will follow the Rationale's advice anyway.**N******************************************************************************.** Implementors NoteN******************************************************************************L** INT_MAX is not a constant value across platforms. Sone constants in this;** file, such as INT_MIN, are defined in terms of INT_MAX.** OD** Do not be tempted to speed up processing up by evaluating these expressions6** into constant values. This will work incorrectly.N*******************************************************************************/#pragma __nostandard#include /*I** Number of bits for the smallest object that is not a bit-field (byte)*/#define CHAR_BIT 8/*9** Minimum and maximum values for "signed/unsigned char"*/#define UCHAR_MAX 255u#define SCHAR_MAX E127&#define SCHAR_MIN (-SCHAR_MAX - 1)/*N** Minimum and maximum values for "char" affected by /unsigned_char qualifier*/#ifdef __UNSIGNED_CHAR#define CHAR_MIN 0#define CHAR_MAX UCHAR_MAX#else#define CHAR_MIN SCHAR_MIN#define CHAR_MAX SCHAR_MAX#endif/*>** Minimum and maximum values for "signed/unsigned short int"*/#define USHRT_MAX 65535u#define SHRT_MAX 32767%#define SHRT_MIN (-SHRT_MAX - 1)/*8** Minimum and Fmaximum values for "signed/unsigned int"*/!#define UINT_MAX 4294967295u #define INT_MAX 2147483647$#define INT_MIN (-INT_MAX - 1)/*=** Minimum and maximum values for "signed/unsigned long int"*/!#define ULONG_MAX 4294967295u #define LONG_MAX 2147483647%#define LONG_MIN (-LONG_MAX - 1)/*<** Minimum and maximum values for "signed/unsigned __intxx"*/ #define __UINT16_MAX 65535u#define __INT16_MAX 32767(#define __INT16_MIN (-__INT1G6_MAX - 1)!#define __UINT32_MAX 4294967295u #define __INT32_MAX 2147483647(#define __INT32_MIN (-__INT32_MAX - 1)#if !defined(__VAX)+#define __UINT64_MAX 18446744073709551615u)#define __INT64_MAX 9223372036854775807(#define __INT64_MIN (-__INT64_MAX - 1)#endif#if __CRTL_VER < 60200000D# define MB_LEN_MAX 1 /* Before OpenVMS V6.2 */#elseD# define MB_LEN_MAX 8 /* After OpenVMS V6.2 */#endif/*4** Limits which changHed beginning with OpenVMS V6.2*/9# if defined(_XOPEN_SOURCE) || !defined(_ANSI_C_SOURCE)D# define COLL_WEIGHTS_MAX 5 /* Max collate weights */&# define NL_TEXTMAX 8192&# define NL_SETMAX 65535&# define NL_MSGMAX 65535&# define CHARCLASS_NAME_MAX 14&# define NL_ARGMAX 9&# define NL_LANGMAX 14&# define TZNAME_MAX 15&# define SSIZE_MAX INT_MAX /*2 ** LimIits needed to support *conf() functions. */b# define BC_BASE_MAX -1 /* Max ibase and obase values for bc - not implemented */a# define BC_DIM_MAX -1 /* Max num elements in array for bc - not implemented */^# define BC_SCALE_MAX -1 /* Max scale value allowed by bc - not implemented */a# define BC_STRING_MAX -1 /* Max len of string constant by bc - not implemented */R# define EXPR_NEST_MAX (-1) /* Max num expre Jssion nested for expr */M# define LINE_MAX 2048 /* Max len of utility input line */Q# define RE_DUP_MAX (-1) /* Max num repeated reg for interval */L# define NGROUPS_MAX 0 /* User can be in no extra groups */G# define PASS_MAX 31 /* Max bytes in a password */K# define ARG_MAX 4096 /* Max len of arg to exec rtns */ /*6 ** These are used by pathconf() as well as others */;# define K LINK_MAX 1 /* Only 1 link to a file */L# define MAX_CANON 511 /* Max bytes in terminal canonical input */R# define MAX_INPUT 511 /* Max bytes required as input before reading */ \# define NAME_MAX 255 /* Max bytes in filename (not including terminating null) */X# define PATH_MAX 256 /* Max bytes in pathname (including terminating null) */G# define PIPE_BUF 512 /* Max atomic bytes on write to pipe */ /* " ** New limits wit Lh DEC C V5.2 */ )# define _POSIX_PIPE_BUF 512#endif /* XOPEN_SOURCE */?#if defined(_XOPEN_SOURCE_EXTENDED) || !defined(_ANSI_C_SOURCE)[# define ATEXIT_MAX 32767 /* Max number of functions that may be registeredR ** with atexit(). essentially unlimited, */O# define IOV_MAX 1024 /* Maximum number of iovec structuresO M ** that one process has available forL ** use with readv() or writev() */#endif/*A** Macros defined by the POSIX 1003.1c-1995 formally approved atD** the June 1995 meeting of the IEEE Standards Board. The correct A** feature test macro for strictly conforming POSIX 1003.1c-1995** applications is:**'** #define _POSIX_C_SOURCE 199506L*/8#if _POSIX_C_SOURCE >= 199506 || !defined _ANSI_C_SOURCE1# ifndef _POSIX_THREADN_DESTRUCTOR_ITERATIONS 5# define _POSIX_THREAD_DESTRUCTOR_ITERATIONS 4 # endif1# ifndef _POSIX_THREAD_KEYS_MAX 7# define _POSIX_THREAD_KEYS_MAX 128 # endif1# ifndef _POSIX_THREAD_THREADS_MAX 6# define _POSIX_THREAD_THREADS_MAX 64 # endif1# ifndef PTHREAD_DESTRUCTOR_ITERATIONS W# define PTHREAD_DESTRUCTOR_ITERATIONS _POSIX_THREAD_DESTRUCTOR_ITERATIONS # endif# ifOndef PTHREAD_KEYS_MAX/# define PTHREAD_KEYS_MAX 255 # endif-# ifndef PTHREAD_STACK_MIN # if !defined(__VAX)8# define PTHREAD_STACK_MIN 8192 # else8# define PTHREAD_STACK_MIN 1024 # endif # endif&#endif /* _POSIX_C_SOURCE >= 199506 */#pragma __standard#endif /* __LIMITS_LOADED */ww,2ԗ#ifndef __LOCALE_LOADED#define __LOCALE_LOADED 1#ifndef __ PLOCALE_PROCESSED#define __LOCALE_PROCESSEDM/******************************************************************************** - Localization**M*****************************************************************************,** Header introduced by the ANSI C StandardM*****************************************************************************I** I** Copyright 2004 Hewlett-Packard Development Company,Q L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the UR.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** aSre set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_TSIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*** Member align structures*/!#pragma __member_alignment __save#pragma __member_alignment#ifdef __NAMESPACE_STDnamespace std {#endif/*** Define the lconv structure*/struct lconv { char *decimal_point; char *thousands_sep; char *grouping; char *int_curr_symbol; char *currency_symbol; char *mon_decimal_point; char *mon_thousands_sep; char *mon_groupiUng; char *positive_sign; char *negative_sign; char int_frac_digits; char frac_digits; char p_cs_precedes; char p_sep_by_space; char n_cs_precedes; char n_sep_by_space; char p_sign_posn; char n_sign_posn;};#ifdef __NAMESPACE_STD} /* namespace std */#endif/*** Define NULL*/ #ifndef NULL# define NULL __NULL#endif /*"** Define lconv enumerated values*/#define LC_ALL (-1)#define LC_COLLATE 0V#define LC_CTYPE 1#define LC_MONETARY 2#define LC_NUMERIC 3#define LC_TIME 4O#if __CRTL_VER >= 60200000 && (_POSIX_C_SOURCE >= 2 || !defined _ANSI_C_SOURCE)# define LC_MESSAGES 5#endif5#if __CRTL_VER >= 60200000 && !defined _ANSI_C_SOURCE# define LC_MAX 5#endif/*9** Change MIA environment to use MIA setlocale semantics*/ #ifdef __MIA# ifdef setlocale# undef setlocale # endif*# define setlocale decc$mia_setlocWale_v1#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*;** Function prototypes which always return 32 bit pointers*/!struct lconv * localeconv (void);#ifdef __NAMESPACE_STD} /* namespace std */#endif/*G** When compiling with /POINTER_SIZE, change to long pointers so that I** prototypes reflect the implementation for widened pointers. When notG** using /POINTER_SIZE, the prototypes do not allow for long pointers.*/#if __INITIAL_POINTER_SIZE# pr"Xagma __pointer_size 64#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*** Function prototypes*/?__char_ptr32 setlocale (int __category, const char *__locale);#ifdef __NAMESPACE_STD} /* namespace std */#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#pragma __standard#endif /* __LOCALE_PROCESSED */>Y#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_LOCALE_NAMES # define __USING_LOCALE_NAMES using std::lconv; using std::localeconv; using std::setlocale;# endif#endif#endif /* __LOCALE_LOADED */wwR2ԗ#ifndef __MATH_LOADED#define __MATH_LOADED 1#ifndef __MATH_PROCESSED#define __MATH_PROCESSEDM/******************************************************************************** - Mathematics**ZM*****************************************************************************,** Header introduced by the ANSI C StandardM*****************************************************************************I** I** Copyright 2006 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or [ I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** \ I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warr]anty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*"** frexp frexpf frexpl!** modf modff modfl*/#if __INITIAL_POINTER_SIZE# if __CRTL_VER < 80300000 /* 32-bit pointers only */# pragma __pointer^_size __save# pragma __pointer_size 32# else0 /* Either 32-bit or 64-bit pointers accepted */# pragma __pointer_size __save# pragma __pointer_size 64 # endif#endif/*** Member align structures*/!#pragma __member_alignment __save#pragma __member_alignment/*** Define HUGE_VAL*/ #if __G_FLOAT9# define HUGE_VAL 8.988465674311578540726371186585e+307$# define __MAXFLOAT 1.7014117e+38f#elif __IEEE_FLOAT5# if defined (_IEEE_FP) && (__CRTL_VER >= 602000_00)## pragma __extern_model __save,# pragma __extern_model __strict_refdef* extern double decc$gt_dbl_infinity;&# pragma __extern_model __restore+# define HUGE_VAL decc$gt_dbl_infinity# else.# define HUGE_VAL 1.7976931348623158e+308 # endif%# define __MAXFLOAT 3.40282347e+38f#else# if !defined(__VAX)2# define HUGE_VAL 1.70141183460469213e+38 # else .# define HUGE_VAL 1.70141183460469229e+38 # endif$# define __MAXFLOA`T 1.7014117e+38f#endif/* <** MAXFLOAT is defined by X/Open extended to be the maximum8** non-infinite single precision floating point number.*/ #if !defined _DECC_V4_SOURCE7# if defined _XOPEN_SOURCE || !defined _ANSI_C_SOURCE# define MAXFLOAT __MAXFLOAT # endif#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*!** 4.5.2 Trigonometric Functions*/double acos (double __x);double asin (double __x);double atan (double __x);&double atan2 (double _a_y, double __x);double cos (double __x);double sin (double __x);double tan (double __x);#ifdef __NAMESPACE_STD} /* namespace std */#endif#if !defined(__VAX) float acosf (float __x); float asinf (float __x); float atanf (float __x);( float atan2f (float __y, float __x); float cosf (float __x); float sinf (float __x); float tanf (float __x);) long double acosl (long double __x);) long double asinl (long double __x);b) long double atanl (long double __x);: long double atan2l (long double __y, long double __x);) long double cosl (long double __x);) long double sinl (long double __x);) long double tanl (long double __x);#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*** 4.5.3 Hyperbolic Functions*/double cosh (double __x);double sinh (double __x);double tanh (double __x);#ifdef __NAMESPACE_STD} /* namespace std */#endif#if !defined(__VAX)c float coshf (float __x); float sinhf (float __x); float tanhf (float __x);( long double coshl (long double __x);( long double sinhl (long double __x);( long double tanhl (long double __x);#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*/** 4.5.4 Exponential and Logarithmic Functions*/double exp (double __x);*double frexp (double __value, int *__exp);%double ldexp (double __x, int __exp);double log (double __x);double log10 (double __xd);.double modf (double __value, double *__iptr);#ifdef __NAMESPACE_STD} /* namespace std */#endif#if !defined(__VAX) float expf (float __x);- float frexpf (float __value, int *__exp);( float ldexpf (float __x, int __exp); float logf (float __x); float log10f (float __x);0 float modff (float __value, float *__iptr);) long double expl (long double __x);9 long double frexpl (long double __value, int *__exp);4 long double ldexpl (long deouble __x, int __exp);) long double logl (long double __x);) long double log10l (long double __x);B long double modfl (long double __value, long double *__iptr);#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*** 4.5.5 Power Functions*/%double pow (double __x, double __y);double sqrt (double __x);#ifdef __NAMESPACE_STD} /* namespace std */#endif#if !defined(__VAX)' float powf (float __x, float __y); float sqrtf (float __x);9 f long double powl (long double __x, long double __y);( long double sqrtl (long double __x);#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*B** 4.5.6 Nearest Integer, Absolute Value, and Remainder Functions*/double ceil (double __x);double fabs (double __x);double floor (double __x);&double fmod (double __x, double __y);#ifdef __NAMESPACE_STD} /* namespace std */#endif#if !defined(__VAX) float ceilf (float __x); float fabsf (float __x);g float floorf (float __x);( float fmodf (float __x, float __y);) long double ceill (long double __x);) long double fabsl (long double __x);) long double floorl (long double __x);: long double fmodl (long double __x, long double __y);#endif&#if !defined(__VAX) && defined(__DECC) double __FABS (double __x); double __COS (double __x); double __SIN (double __x); # define fabs(__x) __FABS(__x)# define cos(__x) __COS(__x)# define sinh(__x) __SIN(__x)#endif/*7** Define X/Open XPG4 extensions on both VAX and Alpha*/5#if defined _XOPEN_SOURCE || !defined _ANSI_C_SOURCE * double hypot (double __x, double __y);#endif/* (** X/Open XPG4 extensions on Alpha-only*/ K#if !defined(__VAX) && (defined(_XOPEN_SOURCE) || !defined(_ANSI_C_SOURCE)) double erf (double __x); double erfc (double __x); double gamma (double __x); double j0 (double __x); double j1 (double __ix);( double jn (int __n, double __x); double lgamma (double __x); double y0 (double __x); double y1 (double __x);) double yn (int __n , double __x); float erff (float __x); float erfcf (float __x); float gammaf (float __x);( float hypotf (float __x, float __y); float lgammaf (float __x); float y0f (float __x); float y1f (float __x);( float ynf (int __n , float __x); float j0f (float __x); j float j1f (float __x);' float jnf (int __n, float __x);* long double erfl (long double __x);* long double erfcl (long double __x);* long double gammal (long double __x);: long double hypotl (long double __x, long double __y);* long double j0l (long double __x);* long double j1l (long double __x);3 long double jnl (int __n, long double __x);* long double lgammal (long double __x);* long double y0l (long double __x);* long dkouble y1l (long double __x);4 long double ynl (int __n , long double __x); /* 6 ** isnan() conflicts with isnan() macro in . */ # if !defined __FP_LOADED int isnan (double __x); # endif int isnanf (float __x);! int isnanl (long double __x);/# if defined __DECC && __DECC_VER >= 50300000## pragma __extern_model __save,# pragma __extern_model __strict_refdef extern int signgam;&# pragma __extern_modell __restore# else extern int signgam; # endif#endif/* $** Define X/open XPG4 V2 extensions*/ T#if !defined(__VAX) && (defined(_XOPEN_SOURCE_EXTENDED) || !defined(_ANSI_C_SOURCE)) double acosh (double __x); double asinh (double __x); double atanh (double __x); double cbrt (double __x); double expm1 (double __x); double logb (double __x); double log1p (double __x);. double nextafter (double __x, double __y); double rint (domuble __x);* double scalb (double __x, double __n); float acoshf (float __x); float asinhf (float __x); float atanhf (float __x); float cbrtf (float __x); float expm1f (float __x); float logbf (float __x); float log1pf (float __x);, float nextafterf (float __x, float __y); float rintf (float __x);( float scalbf (float __x, float __n);) long double acoshl (long double __x);) long double asinhl (long double __x);) long double natanhl (long double __x);( long double cbrtl (long double __x);) long double expm1l (long double __x);) long double logbl (long double __x);) long double log1pl (long double __x);> long double nextafterl (long double __x, long double __y);) long double rintl (long double __x);: long double scalbl (long double __x, long double __n);#endif/* $** Define DEC C Extensions VAX only*/ #if defined(__VAX)# if !defined _ANSI_C_SOURCE/ typedef struct o{ double x, y; } cabs_t; ! double cabs (cabs_t __z); # endif#endif/* ** DEC C Extensions, Alpha only*/ /#if !defined(__VAX) && !defined(_ANSI_C_SOURCE) # if !defined __COMPLEX_LOADED%# define _MATH_H_DEFINED_CABS 10 typedef struct { float x, y; } cabsf_t; ) typedef struct { double x, y; } cabs_t; 6 typedef struct { long double x, y; } cabsl_t; # if __IEEE_FLOAT # define cabsf DECC$SCABSF_2 # define CABSF DECC$SCABSF_2# depfine cabs DECC$TCABS_2# define CABS DECC$TCABS_2# if __X_FLOAT# define cabsl DECC$TXCABSL_2# define CABSL DECC$TXCABSL_2 # else# define cabsl DECC$TCABSL_2# define CABSL DECC$TCABSL_2 # endif# elif CC$gfloat # define cabsf DECC$FCABSF_2 # define CABSF DECC$FCABSF_2# define cabs DECC$GCABS_2# define CABS DECC$GCABS_2# if __X_FLOAT# define cabsl DECC$GXCABSL_2# define CABSL DECC$GXCABSL_2 # else# define cabsl DECC$GCABSL_2q# define CABSL DECC$GCABSL_2 # endif# else # define cabsf DECC$FCABSF_2 # define CABSF DECC$FCABSF_2# define cabs DECC$DCABS_2# define CABS DECC$DCABS_2# if __X_FLOAT# define cabsl DECC$DXCABSL_2# define CABSL DECC$DXCABSL_2 # else# define cabsl DECC$DCABSL_2# define CABSL DECC$DCABSL_2 # endif# endif# float cabsf (cabsf_t __z); double cabs (cabs_t __z);) long double cabsl (cabsl_t __z); # endif doruble acosd (double __x); double asind (double __x); double atand (double __x);+ double atand2 (double __y, double __x);. double copysign (double __x, double __y); double cosd (double __x); double cot (double __x); double cotd (double __x); double log2 (double __x); double nint (double __x); double sind (double __x); double tand (double __x); double trunc (double __x); float acosdf (float __x); float asindf (fsloat __x); float atandf (float __x);) float atand2f (float __y, float __x);, float copysignf (float __x, float __y); float cosdf (float __x); float cotf (float __x); float cotdf (float __x); float log2f (float __x); float nintf (float __x); float sindf (float __x); float tandf (float __x); float truncf (float __x);* long double acosdl (long double __x);* long double asindl (long double __x);* long double atandl (long tdouble __x);; long double atand2l (long double __y, long double __x);> long double copysignl (long double __x, long double __y);* long double cosdl (long double __x);( long double cotl (long double __x);( long double cotdl (long double __x);) long double log2l (long double __x);) long double nintl (long double __x);* long double sindl (long double __x);* long double tandl (long double __x);) long double truncl (long double __x);" int finite u (double __x);" int fp_class (double __x);. int unordered (double __x, double __y);! int finitef (float __x);! int fp_classf (float __x);, int unorderedf (float __x, float __y);- int finitel (long double __x);- int fp_classl (long double __x);> int unorderedl (long double __x, long double __y);#endifR#if defined _XOPEN_SOURCE || (!defined _DECC_V4_SOURCE && !defined _ANSI_C_SOURCE)@#define M_E 2.718 v2818284590452354E0 /* e */@#define M_LOG2E 1.4426950408889634074E0 /* log2(e) */@#define M_LOG10E 4.3429448190325182765E-1 /* log10(e) */@#define M_LN2 6.9314718055994530942E-1 /* ln(2) */@#define M_LN10 2.3025850929940456840E0 /* ln(10) */@#define M_PI 3.1415926535897932385E0 /* pi */@#define M_PI_2 1.5707963267948966192E0 /* pi/2 */@#define M_PI_4 7.8539816339744830962E-1 /* pi/4 */@#d wefine M_1_PI 3.1830988618379067154E-1 /* 1/pi */@#define M_2_PI 6.3661977236758134308E-1 /* 2/pi */@#define M_2_SQRTPI 1.1283791670955125739E0 /* 2/sqrt(pi) */@#define M_SQRT2 1.4142135623730950488E0 /* sqrt(2) */@#define M_SQRT1_2 7.0710678118654752440E-1 /* 1/sqrt(2) */#endif/* G** DEC C V4.0 compatibility. These functions were defined in previous9** versions of DEC C and are retained for compatibility.*/ #ifdef _DECC_V4_SOURxCE# if __G_FLOAT" double MTH$GCOS_R7 (double __x);" double MTH$GSIN_R7 (double __x);# elif __IEEE_FLOAT" double MTH$TCOS_R7 (double __x);" double MTH$TSIN_R7 (double __x);# else" double MTH$DCOS_R7 (double __x);" double MTH$DSIN_R7 (double __x); # endif# define VAXC$TANH 1#endif #ifdef __KAP)# if !defined(__VAX) && defined(__DECC)-# pragma _KAP no side effects ( __FABS ),# pragma _KAP no side effects ( __COS ),# pragma _KAP no side effyects ( __SIN ) # endif(# pragma _KAP no side effects ( acos )(# pragma _KAP no side effects ( asin )(# pragma _KAP no side effects ( atan ))# pragma _KAP no side effects ( atan2 )'# pragma _KAP no side effects ( cos )'# pragma _KAP no side effects ( sin )'# pragma _KAP no side effects ( tan )(# pragma _KAP no side effects ( cosh )(# pragma _KAP no side effects ( sinh )(# pragma _KAP no side effects ( tanh )'# pragma _KAP no side effects ( exp ))# pragma _ zKAP no side effects ( frexp ))# pragma _KAP no side effects ( ldexp )'# pragma _KAP no side effects ( log ))# pragma _KAP no side effects ( log10 )(# pragma _KAP no side effects ( modf )'# pragma _KAP no side effects ( pow )(# pragma _KAP no side effects ( sqrt )(# pragma _KAP no side effects ( cabs ))# pragma _KAP no side effects ( hypot )(# pragma _KAP no side effects ( ceil )(# pragma _KAP no side effects ( fabs ))# pragma _KAP no side effects ( floor )(# {pragma _KAP no side effects ( fmod ))# pragma _KAP no side effects ( acosf ))# pragma _KAP no side effects ( asinf ))# pragma _KAP no side effects ( atanf )*# pragma _KAP no side effects ( atan2f )(# pragma _KAP no side effects ( cosf )(# pragma _KAP no side effects ( sinf )(# pragma _KAP no side effects ( tanf ))# pragma _KAP no side effects ( coshf ))# pragma _KAP no side effects ( sinhf ))# pragma _KAP no side effects ( tanhf )(# pragma _KAP no side effects |( expf )*# pragma _KAP no side effects ( frexpf )*# pragma _KAP no side effects ( ldexpf )(# pragma _KAP no side effects ( logf )*# pragma _KAP no side effects ( log10f ))# pragma _KAP no side effects ( modff )(# pragma _KAP no side effects ( powf ))# pragma _KAP no side effects ( sqrtf ))# pragma _KAP no side effects ( cabsf )*# pragma _KAP no side effects ( hypotf ))# pragma _KAP no side effects ( ceilf ))# pragma _KAP no side effects ( fabsf )*# pragma _KAP }no side effects ( floorf ))# pragma _KAP no side effects ( fmodf ))# pragma _KAP no side effects ( acosl ))# pragma _KAP no side effects ( asinl ))# pragma _KAP no side effects ( atanl )*# pragma _KAP no side effects ( atan2l )(# pragma _KAP no side effects ( cosl )(# pragma _KAP no side effects ( sinl )(# pragma _KAP no side effects ( tanl ))# pragma _KAP no side effects ( coshl ))# pragma _KAP no side effects ( sinhl ))# pragma _KAP no side effects ( tanhl ) ~(# pragma _KAP no side effects ( expl )*# pragma _KAP no side effects ( frexpl )*# pragma _KAP no side effects ( ldexpl )(# pragma _KAP no side effects ( logl )*# pragma _KAP no side effects ( log10l ))# pragma _KAP no side effects ( modfl )(# pragma _KAP no side effects ( powl ))# pragma _KAP no side effects ( sqrtl ))# pragma _KAP no side effects ( cabsl )*# pragma _KAP no side effects ( hypotl ))# pragma _KAP no side effects ( ceill ))# pragma _KAP no side effects ( fabsl )*# pragma _KAP no side effects ( floorl ))# pragma _KAP no side effects ( fmodl )'# pragma _KAP no side effects ( erf )(# pragma _KAP no side effects ( erfc ))# pragma _KAP no side effects ( isnan )&# pragma _KAP no side effects ( j0 )&# pragma _KAP no side effects ( j1 )&# pragma _KAP no side effects ( jn )&# pragma _KAP no side effects ( y0 )&# pragma _KAP no side effects ( y1 )&# pragma _KAP no side effects ( yn )(# pragma _KAP no side effects ( erff ))# pragma _KAP no side effects ( erfcf )*# pragma _KAP no side effects ( isnanf )'# pragma _KAP no side effects ( j0f )'# pragma _KAP no side effects ( j1f )'# pragma _KAP no side effects ( jnf )'# pragma _KAP no side effects ( y0f )'# pragma _KAP no side effects ( y1f )'# pragma _KAP no side effects ( ynf )(# pragma _KAP no side effects ( erfl ))# pragma _KAP no side effects ( erfcl )*# pragma _KAP no side effects ( isnanl )'# pragma _KAP no side effects ( j0l )'# pragma _KAP no side effects ( j1l )'# pragma _KAP no side effects ( jnl )'# pragma _KAP no side effects ( y0l )'# pragma _KAP no side effects ( y1l )'# pragma _KAP no side effects ( ynl ),# pragma _KAP no side effects ( copysign )*# pragma _KAP no side effects ( finite ),# pragma _KAP no side effects ( fp_class )-# pragma _KAP no side effects ( nextafter )-# pragma _KAP no side effects ( unordered )-# pragma _KAP no side effects ( copysignf )+# pragma _KAP no side effects ( finitef )-# pragma _KAP no side effects ( fp_classf ).# pragma _KAP no side effects ( nextafterf ).# pragma _KAP no side effects ( unorderedf )-# pragma _KAP no side effects ( copysignl )+# pragma _KAP no side effects ( finitel )-# pragma _KAP no side effects ( fp_classl ).# pragma _KAP no side effects ( nextafterl ).# pragma _KAP no side effects ( unorderedl ))# pragma _KAP no side effects ( acosh ))# pragma _KAP no side effects ( asinh ))# pragma _KAP no side effects ( atanh )*# pragma _KAP no side effects ( acoshf )*# pragma _KAP no side effects ( asinhf )*# pragma _KAP no side effects ( atanhf )*# pragma _KAP no side effects ( acoshl )*# pragma _KAP no side effects ( asinhl )*# pragma _KAP no side effects ( atanhl )'# pragma _KAP no side effects ( cot )(# pragma _KAP no side effects ( cotd )(# pragma _KAP no side effects ( cotf ))# pragma _KAP no side effects ( cotdf )(# pragma _KAP no side effects ( cotl ))# pragma _KAP no side effects ( cotdl ))# pragma _KAP no side effects ( acosd ))# pragma _KAP no side effects ( asind ))# pragma _KAP no side effects ( atand )*# pragma _KAP no side effects ( atand2 )(# pragma _KAP no side effects ( cosd )(# pragma _KAP no side effects ( sind )(# pragma _KAP no side effects ( tand )*# pragma _KAP no side effects ( acosdf )*# pragma _KAP no side effects ( asindf )*# pragma _KAP no s ide effects ( atandf )+# pragma _KAP no side effects ( atand2f ))# pragma _KAP no side effects ( cosdf ))# pragma _KAP no side effects ( sindf ))# pragma _KAP no side effects ( tandf )*# pragma _KAP no side effects ( acosdl )*# pragma _KAP no side effects ( asindl )*# pragma _KAP no side effects ( atandl )+# pragma _KAP no side effects ( atand2l ))# pragma _KAP no side effects ( cosdl ))# pragma _KAP no side effects ( sindl ))# pragma _KAP no side effects ( tandl )(# pragma _KAP no side effects ( nint )(# pragma _KAP no side effects ( rint ))# pragma _KAP no side effects ( trunc ))# pragma _KAP no side effects ( nintf ))# pragma _KAP no side effects ( rintf )*# pragma _KAP no side effects ( truncf ))# pragma _KAP no side effects ( nintl ))# pragma _KAP no side effects ( rintl )*# pragma _KAP no side effects ( truncl )#endif /* __KAP *//*** Math routines added in C99.C** On Alpha, Compaq C V6.4 or later w ill by default add a facilityA** prefix to the external symbols for these routines in the sameC** situations when it will pre-define __STDC_VERSION__ to 199901L.C** So declare them, even though not all of them may be implemented3** on the version of OpenVMS used at compile-time.*/D#if !defined(__VAX) && (defined(__DECC) && __DECC_VER >= 60400000) \3 && __STDC_VERSION__ >= 199901L /*A ** Some were already extensions, no harm in redeclaring them) ** if they were previously declared. */ double acosh (double __x); double asinh (double __x); double atanh (double __x); double cbrt (double __x);. double copysign (double __x, double __y); double expm1 (double __x); double log1p (double __x); double log2 (double __x); double logb (double __x);. double nextafter (double __x, double __y); double rint (double __x); double trunc (double __x); float acoshf (float __x); float asinhf (float __x); float atanhf (float __x); float cbrtf (float __x);, float copysignf (float __x, float __y); float expm1f (float __x); float log1pf (float __x); float log2f (float __x); float logbf (float __x);, float nextafterf (float __x, float __y); float rintf (float __x); float truncf (float __x);) long double acoshl (long double __x);) long double asinhl (long double __x);) long double atanhl (long double __x);( long double cbrtl (long double __x);> long double copysignl (long double __x, long double __y);) long double expm1l (long double __x);) long double log1pl (long double __x);) long double log2l (long double __x);) long double logbl (long double __x);> long double nextafterl (long double __x, long double __y);) long double rintl (long double __x);) long double truncl (long double __x); double erf (double __x); double erfc (double __x);* double hypot (double __x, double __y); double lgamma (double __x); float erfcf (float __x); float erff (float __x);( float hypotf (float __x, float __y); float lgammaf (float __x);* long double erfcl (long double __x);* long double erfl (long double __x);: long double hypotl (long double __x, long double __y);* long double lgammal (long double __x); /*4 ** The rest are new to in Compaq C V6.4 */ double exp2(double __x); ( double fdim(double __x, double __y);3 double fma(double __x, double __y, double __z);( double fmax(double __x, double __y);( double fmin(double __x, double __y);" /* neearbyin not in mathlib */3 double nexttoward(double __x, long double __y);- double remainder(double __x, double __y);6 double remquo(double __x, double __y, int *__quo);/ /* round, scalbln, scalbn not in mathlib */ double tgamma(double __x); float exp2f(float __x);& float fdimf( float __x, float __y);0 float fmaf(float __x, float __y, float __z);& float fmaxf(float __x, float __y);& float fminf(float __x, float __y);# /* nearbyintf not in mathlib */2 float nexttowardf(float __x, long double __y);+ float remainderf(float __x, float __y);4 float remquof(float __x, float __y, int *__quo);2 /* roundf, scalblnf, scalbnf not in mathlib */ float tgammaf(float __x);' long double exp2l(long double __x);8 long double fdiml(long double __x, long double __y);H long double fmal(long double __x, long double __y, long double __z);8 long double fmaxl(long double __x, long double __y);8 long double fminl(long double __x, long double __y);# /* nearbyintl not in mathlib */> long double nexttowardl(long double __x, long double __y);= long double remainderl(long double __x, long double __y);F long double remquol(long double __x, long double __y, int *__quo);2 /* roundl, scalblnl, scalbnl not in mathlib */)  long double tgammal(long double __x); int ilogb(double __x); int ilogbf(float __x); int ilogbl(long double __x); long int lrint(double __x); long int lrintf(float __x);% long int lrintl(long double __x); long int lround(double __x); long int lroundf(float __x);& long int lroundl(long double __x);/ /* llrint*, llround* not in math library */ #endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#pragma __standard#endif /* __MATH_PROCESSED */>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_MATH_NAMES# define __USING_MATH_NAMES using std::acos; using std::asin; using std::atan; using std::atan2; using std::ceil; using std::cos; using std::cosh; using std::exp; using std::fabs; using std::floor; using std::fmod; using std::frexp; using std::ldexp; using std::log; using std::log10; using std::modf; using std::pow; using std::sin; using std::sinh; using std::sqrt; using std::tan; using std::tanh;# endif#endif#endif /* __MATH_LOADED */wwu3ԗ#ifndef __MEMORY_LOADED#define __MEMORY_LOADED 1M/*************************************************************************** *** ** - String Handling**M******************************************************************************* Header is nonstandardM*******************************************************************************M** Copyright Digital Equipment Corporation 1993, 1997. All rights reserved.**B** Restricted Rights: Use, duplication, or disclosure by the U.S.F** Government is subject to restrictions as set forth in subparagraphF** (c) (1) (ii) of DFARS 252.227-7013, or i n FAR 52.227-19, or in FAR&** 52.227-14 Alt. III, as applicable.**A** This software is proprietary to and embodies the confidentialD** technology of Digital Equipment Corporation. Possession, use, orG** copying of this software and media is authorized only pursuant to aD** valid written license from Digital or an authorized sublicensor.**N*******************************************************************************//* <** On some systems, includes, or used to include>** the ANSI C memory routines memccpy(), memchr(), memcpy(),A** memset() and memcmp(). The ANSI/ISO C standard ISO 9899:1990*** specifies that they are in .*/ #include #endif /* __MEMORY_LOADED */ww73ԗ#ifndef __MMAN_LOADED#define __MMAN_LOADED 1#pragma __nostandard#include >#if __CRTL_VER >= 70000000 /* Only OpenVMS V7.0 or later */M/********************************************************************* *********;** - Declarations for mapping pages of memory**M*****************************************************************************I** Header introduced by the X/Open CAE Specification, Issue 4, Version 2M*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I**  I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*&** Define off_t and size_t structures*/0#if !defined __OFF_T && !defined _DECC_V4_SOURCE# define __OFF_T 1 typedef __off_t off_t;#endif#ifndef __SIZE_T# define __SIZE_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __size_t size_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::size_t;#endif#endif/* 8** Symbolic constants for protection for mmap, mprotect*/ #define PROT_NONE 0#define PROT_READ 1#define PROT_WRITE 2#define  PROT_EXEC 4/* ,** Specify either MAP_SHARED or MAP_PRIVATE*/ #define MAP_SHARED 0x01 #define MAP_PRIVATE 0x02/* ,** Specify wither MAP_FIXED or MAP_VARIABLE*/ #define MAP_FIXED 0x100##if !defined _XOPEN_SOURCE_EXTENDED # define MAP_VARIABLE 0x200#endif/* ** failure status from mmap()*/ $#define MAP_FAILED ((void *)-1)/* ** Flags for msync()*/ #define MS_ASYNC 0x01#define MS_SYNC 0x02#define MS_INVALIDATE 0x04##if !defined _XOPEN_SOURCE_EXTENDED /* 0 ** Specify either MAP_FILE or MAP_ANONYMOUS */ # define MAP_ANONYMOUS 0x10# define MAP_ANON 0x10# define MAP_FILE 0x20#endif/*L** At this point in the processing, we are done defining those things whichJ** must always be short pointers. If the user has used the /pointer_sizeG** qualifier, we will allow long pointers to be used in function callsE** regardless of whether they have specified short or long pointers.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*;** Functions which accept either 32 bit or 64 bit pointers*/4int mprotect (void *addr, __size_t len, int prot);*int munmap (void *addr, __size_t len);5int msync (void *addr, __size_t len, int flags);#if __CRTL_VER >= 70200000/*@** shm_open and shm_unlink functions were added in OpenVMS V7.2*/Aint shm_open (const char * __name, int __oflag, __mode_t __mode);%int shm_unlink (const char * __name);#endif/*G** Functions which have separate implementations for 32 bit and 64 bitG** pointers. The implementation defaults to that corresponding to the=** default pointer size used in the /POINTER_SIZE qualifier.*/ #if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32#endif/*B** Beginning in OpenVMS V7.2, the mmap() function was enhanced toE** allow specifying an additional parameter through which the callerA** can request creation a special kind of the global section for!** MAP_SHARED (DEC C extension).*/#if __USE_OFF64_T!# pragma __extern_prefix __save%# pragma __extern_prefix "__off64_"#endifQ#if !defined(_XOPEN_SOURCE) && !defined(_POSIX_C_SOURCE) && __CRTL_VER > 70100622^ void *mmap (void *addr, __size_t len, int prot, int flags, int filedes, __off_t off, ...);#elseY void *mmap (void *addr, __size_t len, int prot, int flags, int filedes, __off_t off);#endif#if __INITIAL_POINTER_SIZE# pragma __pointer_size 32T# if !defined(_XOPEN_SOURCE) && !defined(_POSIX_C_SOURCE) && __CRTL_VER > 70100622^ void *_mmap32 (void *addr, __size_t len, int prot, int flags, int filedes, __off_t off, ...);# elseY void *_mmap32 (void *addr, __size_t len, int prot, int flags, int filedes, __off_t off); # endif# pragma __pointer_size 64Q#if !defined(_XOPEN_SOURCE) && !defined(_POSIX_C_SOURCE) && __CRTL_VER > 70100622^ void *_mmap64 (void *addr, __size_t len, int prot, int flags, int filedes, __off_t off, ...);# elseY void *_mmap64 (void *addr, __size_t len, int prot, int flags, int filedes, __off_t off); # endif#endif#if __USE_OFF64_T$# pragma __extern_prefix __restore#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif"#endif /* OpenVMS V7.0 or later */#pragma __standard#endif /* __MMAN_LOADED */ww3ԗ#ifndef _MONETARY_LOADED#define _MONETARY_LOADEDM/******************************************************************************!** - monetary types**M*******************************************************************************I** Header introduced by the X/Open CAE Specification, Issue 4, Version 2**K** Definitions in this header file may not be available on all versions ofK** OpenVMS. See the DEC C Runtime Library reference manual for s pecifics.**M*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I**  I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I**  M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*L** If the user has used /pointer_size, we will set our default pointer size** to 64-bit pointers.*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endif/*** Define SIZE_T and SSIZE_T*/#ifndef __SIZE_T# define __SIZE_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __size_t size_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::size_t;#endif#endif#ifndef __SSIZE_T# define __SSIZE_T 1 typedef __ssize_t ssize_t;#endif/*** Function prototypes*/Issize_t strfmon(char *__s, size_t __maxsize, const char *__format, ...); /*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard #endif /* _MONETARY_LOADED */ww 3ԗ#ifndef __NAMESER_LOADED#define __NAMESER_LOADED 1M/******************************************************************************1** - define maximum domain name size**M******************************************************************************* Header is nonstandardM*****************************************************************************I**  I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" with out warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*E** All includes of other header files must be done prior to altering** the pointer size mode. */#include #include /*.** Start processing in 32-bit addressing mode*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*7** Set __nomember_alignment to avoid internal and tail2** padding in structures; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment/*=** This definition does not appear in the new NAMESER.H file*/#define MAXDNAME 256/*F * revision information. this is the release date in YYYYMMDD format.E * it can change every day so the right thing to do with it is use itI * in preprocessor commands such as "#if (__NAMESER > 19931104)". do notN * compare for equality; rather, use it to determine whether your libnameser.a. * is new enough to contain a certain feature. */8/* XXXRTH I made this bigger than __BIND in 4.9.5 T6B */=#define __NAMESER 19961001 /* New interface version stamp. *//*8 * Define constants based on RFC 883, RFC 1034, RFC 1035 */1#define NS_PACKETSZ 512 /* maximum packet size */2#define NS_MAXDNAME 1025 /* maximum domain name */=#define NS_MAXCDNAME 255 /* maximum compressed domain name */;#define NS_MAXLABEL 63 /* maximum length of do main label */<#define NS_HFIXEDSZ 12 /* #/bytes of fixed data in header */:#define NS_QFIXEDSZ 4 /* #/bytes of fixed data in query */?#define NS_RRFIXEDSZ 10 /* #/bytes of fixed data in r record */9#define NS_INT32SZ 4 /* #/bytes of data in a u_int32_t */9#define NS_INT16SZ 2 /* #/bytes of data in a u_int16_t */7#define NS_INT8SZ 1 /* #/bytes of data in a u_int8_t */$#define NS_INADDRSZ 4 /* IPv4 T_A */)#define NS_IN6ADDRSZ 16 /* IPv6 T_AAAA */F#define NS_CMPRSFLGS 0xc0 /* Flag bits indicating name compression. */5#define NS_DEFAULTPORT 53 /* For both TCP and UDP. *//*M * These can be expanded with synonyms, just keep ns_parse.c:ns_parserecord() * in synch with it. */typedef enum __ns_sect {% ns_s_qd = 0, /* Query: Question. */" ns_s_zn = 0, /* Update: Zone. */# ns_s_an = 1, /* Query: Answer. */+ ns_s_pr = 1, /* Update: Prerequisites. */) ns_s_ns = 2, /* Query: Name servers. */$ ns_s_ud = 2, /* Update: Update. */6 ns_s_ar = 3, /* Query|Update: Additional records. */ ns_s_max = 4 } ns_sect;/*M * This is a message handle. It is caller allocated and has no dynamic data.J * This structure is intended to be opaque to all but ns_parse.c, thus theM * leading _'s on the member names. Use the accessor functions, not the _'s. */typedef struct __ns_msg { const __u_char *_msg, *_eom;* u_int16_t _id, _flags, _counts[ns_s_max];% const __u_char *_sections[ns_s_max]; ns_sect _sect; int _rrnum; const __u_char *_ptr; } ns_msg;?/* Private data structure - do not use from outside library. */+struct _ns_flagdata { int mask, shift; };*extern struct _ns_flagdata _ns_flagdata[];=/* Accessor macros - this is part of the public interface. */(#define ns_msg_getflag(handle, flag) ( \0 ((handle)._flags & _ns_flagdata[flag].mask) \! >> _ns_flagdata[flag].shift \ ),#define ns_msg_id(handle) ((handle)._id + 0)/#define ns_msg_base(handle) ((handle)._msg + 0).#define ns_msg_end(handle) ((handle)._eom + 0);#define ns_msg_size(handle) ((handle)._eom - (handle)._msg)E#define ns_msg_count(handle, section) ((handle)._counts[section] + 0)/*L * This is a parsed record. It is caller allocated and has no dynamic data. */typedef struct __ns_rr {2 char name[NS_MAXDNAME]; /* XXX need to malloc */ u_int16_t type; u_int16_t rr_class; u_int32_t ttl; u_int16_t rdlength; const __u_char *rdata;} ns_rr;=/* Accessor macros - this is part of the public interface. */A#define ns_rr_name(rr) (((rr).name[0] != '\0') ? (rr).name : ".")&#define ns_rr_type(rr) ((rr).type + 0)+#define ns_rr_class(rr) ((rr).rr_class + 0)$#define ns_rr_ttl(rr) ((rr).ttl + 0)+#define ns_rr_rdlen(rr) ((rr).rdlength + 0)(#define ns_rr_rdata(rr) ((rr).rdata + 0)/*H * These don't have to be in the same order as in the packet flags word,I * and they can even overlap in some cases, but they will need to be kept* * in synch with ns_parse.c:ns_flagdata[]. */typedef enum __ns_flag {# ns_f_qr, /* Question/Response. */$ ns_f_opcode, /* Operation code. */& ns_f_aa, /* Authoritative Answer. */% ns_f_tc, /* Truncation occurred. */# ns_f_rd, /* Recursion Desired. */% ns_f_ra, /* Recursion Available. */ ns_f_z, /* MBZ. */) ns_f_ad, /* Authentic Data (DNSSEC). */, ns_f_cd, /* Checking Disabled (DNSSEC). */" ns_f_rcode, /* Response code. */ ns_f_max } ns_flag;/* * Currently defined opcodes. */typedef enum __ns_opcode {' ns_o_query = 0, /* Standard query. */? ns_o_iquery = 1, /* Inverse query (deprecated/unsupported). */? ns_o_status = 2, /* Name server status query (unsupported). */) /* Opcode 3 is undefined/reserved. */1 ns_o_notify = 4, /* Zone change notification. */, ns_o_update = 5, /* Zone update message. */ ns_o_max = 6 } ns_opcode;/*$ * Currently defined response codes. */typedef enum __ns_rcode {+ ns_r_noerror = 0, /* No error occurred. */& ns_r_formerr = 1, /* Format error. */) ns_r_servfail = 2, /* Server failure. */% ns_r_nxdomain = 3, /* Name error. */' ns_r_notimpl = 4, /* Unimplemented. */+ ns_r_refused = 5, /* Operation refused. */ /* these are for BIND_UPDATE */% ns_r_yxdomain = 6, /* Name exists */% ns_r_yxrrset = 7, /* RRset exists */- ns_r_nxrrset = 8, /* RRset does not exist */3 ns_r_notauth = 9, /* Not authoritative for zone */D ns_r_notzone = 10, /* Zone of record different from zone section */ ns_r_max = 11 } ns_rcode;/* BIND_UPDATE */$typedef enum __ns_update_operation { ns_uop_delete = 0, ns_uop_add = 1, ns_uop_max = 2} ns_update_operation;/* forward decls for C++ */#ifdef __cplusplusstruct databuf;#endif/*2 * This RR-like structure is particular to UPDATE. */struct ns_updrec {9 struct ns_updrec *r_prev; /* prev record */, struct ns_updrec *r_next; /* next record */3 u_int8_t r_section; /* ZONE/PREREQUISITE/UPDATE */' char * r_dname; /* owner of the RR */& u_int16_t r_class; /* class number */% u_int16_t r_typ e; /* type number */% u_int32_t r_ttl; /* time to live */6 __u_char * r_data; /* rdata fields as text string */. u_int16_t r_size; /* size of r_data field */' int r_opcode; /* type of operation */G /* following fields for private use by the resolver/server routines */< struct ns_updrec *r_grpnext; /* next record when grouped */0 struct databuf *r_dp; /* databuf to process */= struct databuf *r_deldp; /* databuf's deleted/overwritten */. int16_t r_zone; /* zone number on server */};#typedef struct ns_updrec ns_updrec;/*; * Currently defined type values for resources and queries. */typedef enum __ns_type {! ns_t_a = 1, /* Host address. */* ns_t_ns = 2, /* Authoritative server. */& ns_t_md = 3, /* Mail destination. */$ ns_t_mf = 4, /* Mail forwarder. */' ns_t_cname = 5, /* Canonical name. */. ns_t_soa = 6, /* Start of authority zone. */) ns_t_mb = 7, /* Mailbox domain name. */' ns_t_mg = 8, /* Mail group member. */& ns_t_mr = 9, /* Mail renam e name. */- ns_t_null = 10, /* Null resource record. */* ns_t_wks = 11, /* Well known service. */+ ns_t_ptr = 12, /* Domain name pointer. */) ns_t_hinfo = 13, /* Host information. */, ns_t_minfo = 14, /* Mailbox information. *// ns_t_mx = 15, /* Mail routing information. */$ ns_t_txt = 16, /* Text strings. */) ns_t_rp = 17, /* Responsible person. */* ns_t_afsdb = 18, /* AFS cell database. */, ns_t_x25 = 19, /* X_25 calling address. */- ns_t_isdn = 20, /* ISDN calling address. * / ns_t_rt = 21, /* Router. */% ns_t_nsap = 22, /* NSAP address. */< ns_t_nsap_ptr = 23, /* Reverse NSAP lookup (deprecated). */* ns_t_sig = 24, /* Security signature. */$ ns_t_key = 25, /* Security key. */) ns_t_px = 26, /* X.400 mail mapping. */: ns_t_gpos = 27, /* Geographical position (withdrawn). */$ ns_t_aaaa = 28, /* Ip6 Address. */, ns_t_loc = 29, /* Location Information. */. ns_t_nxt = 30, /* Next domain (security). */+ ns_t_eid = 31, /* Endpoint identifier. */( ns_ t_nimloc = 32, /* Nimrod Locator. */( ns_t_srv = 33, /* Server Selection. */# ns_t_atma = 34, /* ATM Address */0 ns_t_naptr = 35, /* Naming Authority PoinTeR */A /* Query type values which do not appear in resource records. */2 ns_t_ixfr = 251, /* Incremental zone transfer. */3 ns_t_axfr = 252, /* Transfer zone of authority. */2 ns_t_mailb = 253, /* Transfer mailbox records. */5 ns_t_maila = 254, /* Transfer mail agent records. */' ns_t_any = 255, /* Wildcard match. */ ns_t_max = 65536 } ns_type;/* * Values for class field */typedef enum __ns_class { ns_c_in = 1, /* Internet. */* /* Class 2 unallocated/unsupported. */& ns_c_chaos = 3, /* MIT Chaos-net. */ ns_c_hs = 4, /* MIT Hesiod. */A /* Query class values which do not appear in resource records */? ns_c_none = 254, /* for prereq. sections in update requests */' ns_c_any = 255, /* Wildcard match. */ ns_c_max = 65536 } ns_class;/*" * Flags field of the KEY RR rdata */:#define NS_KEY_TYPEMASK 0xC000 /* Mask for "type" bits */>#define NS_KEY_TYPE_AUTH_CONF 0x0000 /* Key usable for both */I#define NS_KEY_TYPE_CONF_ONLY 0x8000 /* Key usable for confidentiality */H#define NS_KEY_TYPE_AUTH_ONLY 0x4000 /* Key usable for authentication */H#define NS_KEY_TYPE_NO_KEY 0xC000 /* No key usable for either; no key */J/* The type bits can also be interpreted independently, as single bits: */D#define NS_KEY_NO_AUTH 0x8000 /* Key unusable for authentication */E#define NS_KEY_NO_CONF 0x4000 /* Key unusable for confidentiality */I#define NS_KEY_EXPERIMENTAL 0x2000 /* Security is *mandatory* if bit=0 */>#define NS_KEY_RESERVED3 0x1000 /* reserved - must be zero */>#define NS_KEY_RESERVED4 0x0800 /* reserved - must be zero */F#define NS_KEY_USERACCOUNT 0x0400 /* key is assoc. with a user acct */E#define NS_KEY_ENTITY 0x0200 /* key is assoc. with entity eg host */4#define NS_KEY_ZONEKEY 0x0100 /* key is zone key */B#define NS_KEY_IPSEC 0x0080 /* key is for IPSEC (host or user)*/D#define NS_KEY_EMAIL 0x0040 /* key is for email (MIME security) */?#define NS_KEY_RESERVED10 0x0020 /* reserved - must be zero */?#define NS_KEY_RESERVED11 0x0010 /* reserved - must be zero */H#define NS_KEY_SIGNATORYMASK 0x000F /* key can sign RR's of same name */6#define NS_KEY_RESERVED_BITMASK ( NS_KEY_RESERVED3 | \ NS_KEY_RESERVED4 | \ NS_KEY_RESERVED10 | \ NS_KEY_RESERVED11 )I/* The Algorithm field of the KEY and SIG RR's is an integer, {1..254} */+#define NS_ALG_MD5RSA 1 /* MD5 with RSA */8#define NS_ALG_EXPIRE_ONLY 253 /* No alg, no security */C#define NS_ALG_PRIVATE_OID 254 /* Key begins with OID giving alg *//* Signatures */B#define NS_MD5RSA_MIN_BITS 512 /* Size of a mod or exp in bits */#define NS_MD5RSA_MAX_BITS 2552" /* Total of binary mod and exp */:#define NS_MD5RSA_MAX_BYTES ((NS_MD5RSA_MAX_BITS+7/8)*2+3)# /* Max length of text sig block */<#define NS_MD5RSA_MAX_BASE64 (((NS_MD5RSA_MAX_BYTES+2)/3)*4):/* Offse ts into SIG record rdata to find various values */&#define NS_SIG_TYPE 0 /* Type flags */$#define NS_SIG_ALG 2 /* Algorithm */5#define NS_SIG_LABELS 3 /* How many labels in name */(#define NS_SIG_OTTL 4 /* Original TTL */,#define NS_SIG_EXPIR 8 /* Expiration time */-#define NS_SIG_SIGNED 12 /* Signature time */*#define NS_SIG_FOOT 16 /* Key footprint */;#define NS_SIG_SIGNER 18 /* Domain name of who signed it */>/* How RR types are represented as bit-flags in NXT records */#define NS_NXT_BITS 8P#define NS_NXT_BIT_SET( n,p) (p[(n)/NS_NXT_BITS] |= (0x80>>((n)%NS_NXT_BITS)))P#define NS_NXT_BIT_CLEAR(n,p) (p[(n)/NS_NXT_BITS] &= ~(0x80>>((n)%NS_NXT_BITS)))P#define NS_NXT_BIT_ISSET(n,p) (p[(n)/NS_NXT_BITS] & (0x80>>((n)%NS_NXT_BITS)))/*? * Inline versions of get/put short/long. Pointer is advanced. */#define NS_GET16(s, cp) { \. register __u_char *t_cp = (__u_char *)(cp); \" (s) = ((u_int16_t)t_cp[0] << 8) \ | ((u_int16_t)t_cp[1]) \ ; \ (cp) += NS_INT16SZ; \}#define NS_GET32(l, cp) { \. register __u_char *t_cp = (__u_char *)(cp); \# (l) = ((u_int32_t)t_cp[0] << 24) \# | ((u_int32_t)t_cp[1] << 16) \" | ((u_int32_t)t_cp[2] << 8) \ | ((u_int32_t)t_cp[3]) \ ; \ (cp) += NS_INT32SZ; \}#define NS_PUT16(s, cp) { \+ register u_int16_t t_s = (u_int16_t)(s); \. register __u_char *t_cp = (__u_char *)(cp); \ *t_cp++ = t_s >> 8; \ *t_cp = t_s; \ (cp) += NS_INT16SZ; \}#define NS_PUT32(l, cp) { \+ register u_int32_t t_l = (u_int32_t)(l); \. register __u_char *t_cp = (__u_char *)(cp); \ *t_cp++ = t_l >> 24; \ *t_cp++ = t_l >> 16; \ *t_cp++ = t_l >> 8; \ *t_cp = t_l; \ (cp) += NS_INT32SZ; \}*#if defined __TCPIP_NO_NS_TRANSLITERATIONS/*' * For naked nameserver (ns_*) routines */#else.# if defined __TCPIP_NO_RES_TRANSLITERATIONS#define ns_get16 res$$ns_get16#define ns_get32 res$$ns_get32#define ns_put16 res$$ns_put16#define ns_put32 res$$ns_put3 2'#define ns_initparse res$$ns_initparse##define ns_parserr res$$ns_parserr%#define ns_sprintrr res$$ns_sprintrr'#define ns_sprintrrf res$$ns_sprintrrf)#define ns_format_ttl res$$ns_format_ttl'#define ns_parse_ttl res$$ns_parse_ttl'#define ns_name_ntop res$$ns_name_ntop'#define ns_name_pton res$$ns_name_pton+#define ns_name_unpack res$$ns_name_unpack'#define ns_name_pack res$$ns_name_pack.#define ns_name_compress res$$ns_name_compress2#define ns_name_uncompress res$$ns _name_uncompress# else/*A * If the user has not defined __TCPIP_NO_NS_TRANSLITERATIONS orB * __TCPIP_NO_RES_TRANSLITERATIONS we will define these functionsG * with the TCPIP$ prefix so that the TCPIP$IPC_SHR interface is used. */.#define ns_get16 TCPIP$NS_GET16.#define ns_get32 TCPIP$NS_GET32.#define ns_put16 TCPIP$NS_PUT16.#define ns_put32 TCPIP$NS_PUT322#define ns_initparse TCPIP$NS_INITPARSE0#define ns_par serr TCPIP$NS_PARSERR1#define ns_sprintrr TCPIP$NS_SPRINTRR2#define ns_sprintrrf TCPIP$NS_SPRINTRRF3#define ns_format_ttl TCPIP$NS_FORMAT_TTL2#define ns_parse_ttl TCPIP$NS_PARSE_TTL2#define ns_name_ntop TCPIP$NS_NAME_NTOP2#define ns_name_pton TCPIP$NS_NAME_PTON4#define ns_name_unpack TCPIP$NS_NAME_UNPACK2#define ns_name_pack TCPIP$NS_NAME_PACL6#define ns_name_compress TCPIP$NS_NAME_COMP RESS8#define ns_name_uncompress TCPIP$NS_NAME_UNCOMPRESS/# endif /* __TCPIP_NO_RES_TRANSLITERATIONS */+#endif /* __TCPIP_NO_NS_TRANSLITERATIONS */%__u_int ns_get16 (const __u_char *);&__u_long ns_get32 (const __u_char *);%void ns_put16 (__u_int, __u_char *);&void ns_put32 (__u_long, __u_char *);4int ns_initparse (const __u_char *, int, ns_msg *);2int ns_parserr (ns_msg *, ns_sect, int, ns_rr *);0int ns_sprintrr (const ns_msg *, const ns_rr *,3 const char *, const cha r *, char *, __size_t);<int ns_sprintrrf (const __u_char *, __size_t, const char *,4 ns_class, ns_type, __u_long, const __u_char *,+ __size_t, const char *, const char *, char *, __size_t);0int ns_format_ttl (__u_long, char *, __size_t);-int ns_parse_ttl (const char *, __u_long *);7int ns_name_ntop (const __u_char *, char *, __size_t);7int ns_name_pton (const char *, __u_char *, __size_t);8int ns_name_unpack (const __u_char *, const __u_char *,0 const __u_char *, __u_char *, __size_t);5int ns_name_pack (const __u_char *, __u_char *, int,, const __u_char **, const __u_char **);<int ns_name_uncompress (const __u_char *, const __u_char *,) const __u_char *, char *, __size_t);:int ns_name_compress (const char *, __u_char *, __size_t,0 const __u_char **, const __u_char **);8int ns_name_skip (const __u_char **, const __u_char *);#ifdef BIND_4_COMPAT#include #endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#pragma __standard#endif /* __NAMESER_LOADED */wwB4ԗ#ifndef _ARPA_NAMESER_COMPAT_#define _ARPA_NAMESER_COMPAT_M/******************************************************************************=** Copyright 2004 Hewlett-Packard Development Company, L.P.**@** Confidential computer software. Valid license from HP and/or=** its subsidiaries required for possession, use, or copying.**G** Consistent with FAR 12.211 and 12.212, Commercial Computer Software,E** Computer Software Documentation, and Technical Data for CommercialD** Items are licensed to the U.S. Government under vendor's standard** commercial license.**G** Neither HP nor any of its subsidiaries shall be liable for technicalF** or editorial errors or omissions contained herein. The informationH** in this document is provided "as is" without warranty of any kind andG** is subject to change without notice. The warranties for HP productsH** are set forth in the express limited warranty statements accompanyingH** such products. Nothing herein should be construed as constituting an** additional warranty.**M********************************************************************************* Copyright (c) 1983, 1989H** The Regents of the University of California. All rights reserved.** E** Redistribution and use in source and binary forms, with or withoutE** modification, are permitted provided that the following conditions ** are met:D** 1. Redistributions of source code must retain the above copyrightC** notice, this list of conditions and the following disclaimer.G** 2. Redistributions in binary form must reproduce the above copyrightI** notice, this list of conditions and the following disclaimer in theJ** documentation and/or other materials provided with the distribution.K ** 3. All advertising materials mentioning features or use of this software1** must display the following acknowledgement:A** This product includes software developed by the University of.** California, Berkeley and its contributors.J** 4. Neither the name of the University nor the names of its contributorsK** may be used to endorse or promote products derived from this software0** without specific prior written permission.** J** THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' ANDH** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THEM** IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSEK** ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLEM** FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIALJ** DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODSH** OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)M** HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICTL** LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAYI** OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF** SUCH DAMAGE.****-** from nameser.h 8.1 (Berkeley) 6/2/93D** $Id: nameser_compat.h,v 8.9 1998/03/20 23:25:10 halley Exp $**N*******************************************************************************/ >#define __BIND 19950621 /* (DEAD) interface version stamp. */#ifndef BYTE_ORDER#if (BSD >= 199103)# include #else #ifdef linux# include #elseG#define LITTLE_ENDIAN 1234 /* least-significant byte first (vax, pc) */D#define BIG_ENDIAN 4321 /* most-significant byte first (IBM, net) */G#define PDP_ENDIAN 3412 /* LSB first in word, MSW first in long (pdp)*/M#if defined(vax) || defined(ns32000) || defined(sun386) || defined(i386) || \J defined(MIPSEL) || defined(_MIPSEL) || defined(BIT_ZERO_ON_R IGHT) || \/ defined(__alpha__) || defined(__alpha) || \+ (defined(__Lynx__) && defined(__x86__))%#define BYTE_ORDER LITTLE_ENDIAN#endif K#if defined(sel) || defined(pyr) || defined(mc68000) || defined(sparc) || \O defined(is68k) || defined(tahoe) || defined(ibm032) || defined(ibm370) || \O defined(MIPSEB) || defined(_MIPSEB) || defined(_IBMR2) || defined(DGUX) ||\A defined(apollo) || defined(__convex__) || defined(_CRAY) || \- defined(__hppa) || defined(__hp9000) || \7 defined(__hp9000s300) || defined(__hp9000s700) || \4 defined (BIT_ZERO_ON_LEFT) || defined(m68k) || \ (defined(__Lynx__) && \F (defined(__68k__) || defined(__sparc__) || defined(__powerpc__)))"#define BYTE_ORDER BIG_ENDIAN#endif#endif /* linux */#endif /* BSD */#endif /* BYTE_ORDER */ #if !defined(BYTE_ORDER) || \A (BYTE_ORDER != BIG_ENDIAN && BYTE_ORDER != LITTLE_ENDIAN && \ BYTE_ORDER != PDP_ENDIAN)8 /* you must determine what the correct bit order is for9 * your compiler - the next line is an intentional error8 * which will force your compiles to bomb until you fix * the above macros. */* error "Undefined or invalid BYTE_ORDER";#endif/*G * Structure for query header. The order of the fields is machine- andE * compiler-dependent, depending on the byte/bit order and the layoutC * of bit fields. We use bit fields only in int variables, as thisK * is all ANSI requires. This requires a somewhat confusing rearrangement. */typedef struct {4 unsigned id :16; /* query identification number */#if BYTE_ORDER == BIG_ENDIAN /* fields in third byte */% unsigned qr: 1; /* response flag */- unsigned opcode: 4; /* purpose of message */* unsigned aa: 1; /* authoritive answer */) unsigned tc: 1; /* truncated message */) unsigned rd: 1; /* recursion desired */ /* fields in fourth byte */+ unsigned ra: 1; /* recursion available */: unsigned unused :1; /* unused bits (MBZ as of 4.9.3a3) */1 unsigned ad: 1; /* authentic data from named */5 unsigned cd: 1; /* checking disabled by resolver */' unsigned rcode :4; /* response code */#endif;#if BYTE_ORDER == LITTLE_ENDIAN || BYTE_ORDER == PDP_ENDIAN /* fields in third byte */) unsigned rd :1; /* recursion desired */) unsigned tc :1; /* truncated message */* unsigned aa :1; /* authoritive answer */- unsigned opcode :4; /* purpose of message */% unsigned qr :1; /* res ponse flag */ /* fields in fourth byte */' unsigned rcode :4; /* response code */5 unsigned cd: 1; /* checking disabled by resolver */1 unsigned ad: 1; /* authentic data from named */: unsigned unused :1; /* unused bits (MBZ as of 4.9.3a3) */+ unsigned ra :1; /* recursion available */#endif /* remaining bytes */7 unsigned qdcount :16; /* number of question entries */5 unsigned ancount :16; /* number of answer entries */8 unsigned nscount :16; /* number of authority entries */7 unsigned arcount :16; /* number of resource entries */ } HEADER;#define PACKETSZ NS_PACKETSZ#define MAXDNAME NS_MAXDNAME#define MAXCDNAME NS_MAXCDNAME#define MAXLABEL NS_MAXLABEL#define HFIXEDSZ NS_HFIXEDSZ#define QFIXEDSZ NS_QFIXEDSZ#define RRFIXEDSZ NS_RRFIXEDSZ#define INT32SZ NS_INT32SZ#define INT16SZ NS_INT16SZ#define INADDRSZ NS_INADDRSZ#define IN6ADDRSZ NS_IN6ADDRSZ#define INDIR_MASK NS_CMPRSFLGS&#define NAMESERVER_PORT NS_DEFAULTPORT#define S_ZONE ns_s_zn#define S_PREREQ ns_s_pr#define S_UPDATE ns_s_ud#define S_ADDT ns_s_ar#define QUERY ns_o_query#define IQUERY ns_o_iquery#define STATUS ns_o_status #define NS_NOTIFY_OP ns_o_notify #define NS_UPDATE_OP ns_o_update#define NOERROR ns_r_noerror#define FORMERR ns_r_formerr#define SERVFAIL ns_r_servfail#define NXDOMAIN ns_r_nxdomain#define NOTIMP ns_r_notimpl#define REFUSED ns_r_refused#define YXDOMAIN ns_r_yxdomain#define YXRRSET ns_r_yxrrset#define NXRRSET ns_r_nxrrset#define NOTAUTH ns_r_notauth#define NOTZONE ns_r_notzone#define DELETE ns_uop_delete#define ADD ns_uop_add#define T_A ns_t_a#define T_NS ns_t_ns#define T_MD ns_t_md#define T_MF ns_t_mf#define T_CNAME ns_t_cname#define T_SOA ns_t_soa#define T_MB ns_t_mb#define T_MG ns_t_mg#define T_MR ns_t_mr#define T_NULL ns_t_null#define T_WKS ns_t_wks#define T_PTR ns_t_ptr#define T_HINFO ns_t_hinfo#define T_MINFO ns_t_minfo#define T_MX ns_t_mx#define T_TXT ns_t_txt#define T_RP ns_t_rp#define T_AFSDB ns_t_afsdb#define T_X25 ns_t_x25#define T_ISDN ns_t_isdn#define T_RT ns_t_rt#define T_NSAP ns_t_nsap #define T_NSAP_PTR ns_t_nsap_ptr#define T_SIG ns_t_sig#define T_KEY ns_t_key#define T_PX ns_t_px#define T_GPOS ns_t_gpos#define T_AAAA ns_t_aaaa#define T_LOC ns_t_loc#define T_NXT ns_t_nxt#define T_EID ns_t_eid#define T_NIMLOC ns_t_nimloc#define T_SRV  ns_t_srv#define T_ATMA ns_t_atma#define T_NAPTR ns_t_naptr#define T_IXFR ns_t_ixfr#define T_AXFR ns_t_axfr#define T_MAILB ns_t_mailb#define T_MAILA ns_t_maila#define T_ANY ns_t_any#define C_IN ns_c_in#define C_CHAOS ns_c_chaos#define C_HS ns_c_hs/* BIND_UPDATE */#define C_NONE ns_c_none#define C_ANY ns_c_any#define GETSHORT NS_GET16#define GETLONG NS_GET32#define PUTSHORT NS_PUT16#define PUTLONG NS_PUT32"#endif /* _ARPA_NAMESER_ COMPAT_ */ww4ԗ#ifndef __NETDB_LOADED#define __NETDB_LOADED 1M/******************************************************************************-** - Network database library info**M*****************************************************************************I** Header introduced by the X/Open CAE Specification, Issue 4, Version 2M*****************************************************************************I**  I** Copyright 2007 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and  I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*E** All includes of other header files must be done prior to altering** the pointer size mode. */#include #include #include /*H** IPv6: Include these here for now so res_init() and RES_USE_INET6 will0** be available for gethostbyname() users.*/#include #include #include /*.** Start processing in 32-bit addressing mode*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*O** Those socket structures allocated by the DEC C RTL or the underlying tcp/ipM** layer are always 32 bit pointers. Declare typedefs which are pointers toM** these structures while in 32 bit pointer context. We will then use theseG** typedefs in the function prototypes when in 64 bit pointer context.*/1typedef struct hostent * __struct_hostent_ptr32;1typedef struct servent * __struct_servent_ptr32;0typedef struct netent * __struct_netent_ptr32;2typedef struct protoent * __struct_protoent_ptr32;/*I** The OpenVMS V7.0 release added a second implementation of the socket F** functions which is compatible with BSD 4.4. Define a local to be C** used throughout the remaining header file which reflects which !** implementation is being used.**I** An application program enables this support by defining _SOCKADDR_LEN(** prior to including this header file.*/#ifdef _SOCKADDR_LEN# if (__CRTL_VER < 70000000)H# error " BSD 4.4 Socket package not available before OpenVMS V7.0"# undef _SOCKADDR_LEN # endif#endif/*7** Set __nomember_alignment to avoid internal and tail2** padding in structures; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment/*8** Conditionally define in_addr_t and size_t structures*/5#if !defined __IN_ADDR_T && !defined _DECC_V4_SOURCE# define __IN_ADDR_T" typedef __in_addr_t in_addr_t;#endif#ifndef __SIZE_T# define __SIZE_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __size_t size_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::size_t;#endif#endif/*5** Internal Constants for Reentrant Socket Functions*/#ifdef _REENTRANT#define _MAXALIASES 35#define _MAXLINELEN 1024#define _MAXADDRS 35$#define _HOSTBUFSIZE (BUFSIZ + 1)struct hostent_data {" struct in_addr host_addr;4 char *h_addr_ptrs[_MAXADDRS + 1];, char hostaddr[_MAXADDRS];. char hostbuf[_HOSTBUFSIZE];3 char *host_aliases[_MAXALIASES];' char *host_addrs[2]; FILE *hostf;( int svc_gethostflag;( int svc_gethostbind;};struct netent_data { FILE *net_fp;" char line[_MAXLINELEN];* char *net_aliases[_MAXALIASES]; int _net_stayopen; int svc_getnetflag;};struct protoent_data { FILE *proto_fp; char line[1024];, char *proto_aliases[_MAXALIASES]; int _proto_stayopen;! int svc_getprotoflag;};struct servent_data { FILE *serv_fp;" char line[_MAXLINELEN];+ char *serv_aliases[_MAXALIASES]; int  _serv_stayopen; int svc_getservflag;};#endif /* _REENTRANT */0#define _PATH_HOSTS "TCPIP$SYSTEM:HOSTS.DAT"3#define _PATH_NETWORKS "TCPIP$SYSTEM:NETWORKS.DAT"4#define _PATH_PROTOCOLS "TCPIP$SYSTEM:PROTOCOLS.DAT"0#define _PATH_SERVICES "TCPIP$ETC:SERVICES.DAT"/*G** Structures returned by network data base library. All addresses areF** supplied in host order, and returned in network order (suitable for** use in system calls).**//*** Hostent Structure**E** This structure specifies or obtains a host name, a list of aliases<** associated with the host, and the host's number specifiedH** as an Internet address from the host database. An entry in the host 2** database is created with the following command:**** TCPIP> SET HOST XXXX**?** See the HP TCP/IP Services for OpenVMS Management Guide for &** a description of the host database.*/struct hostent {* char *h_name; /* official name of host */# char **h_aliases; /* alias list */( int h_addrtype; /* host address type */& int h_length; /* length of address */= char **h_addr_list; /* list of addresses from name server */F#define h_addr h_addr_list[0] /* address, for backward compatiblity */};/*** Netent Structure**H** This structure specifies or obtains a network name, a list of aliasesB** associated with the network, and the network's number specifiedM** as an Internet address from the network database. An entry in the network2** database is created with the following command:**** TCPIP> SET NETWORK XXXX**>** See the HP TCP/IP Services for OpenVMS Management Guide for)** a description of the network database.***//*+ * Assumption here is that a network number* * fits in 32 bits -- probably a poor one. */struct netent {* char *n_name; /* official name of net */$ char **n_aliases; /* alias list */( int n_addrtype; /* net address type */$ __in_addr_t n_net; /* network # */};/*** Servent Structure**H**  This structure specifies or obtains a service name, a list of aliasesB** associated with the service, and the service's number specifiedO** as an Internet address from the services database. An entry in the services2** database is created with the following command:**** TCPIP> SET SERV XXXX**>** See the HP TCP/IP Services for OpenVMS Management Guide for*** a description of the services database.*/struct servent {* char *s_name; /* official service name */# char **s_aliases; /* alias list */ int s_port; /* port # */% char *s_proto; /* protocol to use */};struct protoent {+ char *p_name; /* official protocol name */# char **p_aliases; /* alias list */ int p_proto; /* protocol # */};/* * Flag values for getaddrinfo() */F#define AI_PASSIVE 0x00000001 /* socket address intended for bind() */@#define AI_CANONNAME 0x00000002 /* request for canonical name */I#define AI_NUMERICHOST 0x00000004 /* numeric host address string */=#define AI_ALL 0x00000008 /* Both AAAA and A records */N#define AI_V4MAPPED 0x00000010 /* request IPV4 mapped IPV6 address */O#define AI_ADDRCONFIG 0x00000020 /* Address Family must be configured */D#define AI_NUMERICSERV 0x00000040 /* numeric service string */N#define AI_DEFAULT (AI_V4MAPPED | AI_ADDRCONFIG) /* Default behavior */A#define AI_MASK (AI_PASSIVE|AI_CANONNAME|AI_NUMERICHOST|\I AI_V4MAPPED|AI_ALL|AI_ADDRCONFIG|AI_NUMERICSERV)/* * Flag values for getnameinfo() */"#define NI_DGRAM 0x00000001"#define NI_NAMEREQD 0x00000002"#define NI_NOFQDN 0x00000004"#define NI_NUMERICHOST 0x00000008"#define NI_NUMERICSERV 0x00000010"#define NI_NUMERICSCOPE 0x00000020"#define NI_WITHSCOPEID 0x00000040#define NI_MAXHOST 1025#define NI_MAXSERV 32/* * Scope delimit character */#define SCOPE_DELIMITER '%'/* ** DEC C extensions*/ ##if !defined _XOPEN_SOURCE_EXTENDED /* ** Rpcent Structures */ struct rpcent {; char *r_name; /* name of server for rpc program */; char **r_aliases; /* alias list */; int r_number; /* rpc program number */ };#endif/*N** Error return codes from gethostbyname and gethostbyaddr (left in h_errno).*//#define NETDB_INTERNAL -1 /* see errno */0#define NETDB_SUCCESS 0 /* no problem */C#define HOST_NOT_FOUND 1 /* Authoritative Answer Host not  found */M#define TRY_AGAIN 2 /* Non-Authoritive Host not found, or SERVERFAIL */P#define NO_RECOVERY 3 /* Non recoverable errors, FORMERR, REFUSED, NOTIMP */L#define NO_DATA 4 /* Valid name, no data record of requested type */L#define NO_ADDRESS NO_DATA /* no address, look for MX record *//*8 ** As of OpenVMS V7.0, the DEC C RTL supports h_errno. */!int *decc$h_errno_get_addr(void);*#define h_errno (*decc$h_errno_get_addr())#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64/* * 64-bit addrinfo structure */struct __addrinfo64 {$ int ai_flags; /* input flags */0 int ai_family; /* protofamily for socket */' int ai_socktype; /* socket type *// int ai_protocol; /* protocol for socket */6 size_t ai_addrlen; /* length of socket-address */> char *ai_canonname; /* service location canonical name */= struct sockaddr *ai_addr; /* socket-address for socket */< struct __addrinfo64 *ai_next; /* pointer to next in list */};. typedef struct addrinfo *__addrinfo_ptr64;: typedef const struct addrinfo *__const_addrinfo_ptr64;5 typedef __addrinfo_ptr64 *__addrinfo_ptr64_ptr64;4 typedef struct __addrinfo64 *__addrinfo64_ptr64;9 typedef __addrinfo64_ptr64 *__addrinfo64_ptr64_ptr64;@ typedef const struct __addrinfo64 *__const_addrinfo64_ptr64;# pragma __pointer_size 32/* * 32-bit addrinfo structure */struct __addrinfo32 {$ int ai_flags; /* input flags */0  int ai_family; /* protofamily for socket */' int ai_socktype; /* socket type *// int ai_protocol; /* protocol for socket */6 size_t ai_addrlen; /* length of socket-address */> char *ai_canonname; /* service location canonical name */= struct sockaddr *ai_addr; /* socket-address for socket */< struct __addrinfo32 *ai_next; /* pointer to next in list */};. typedef struct addrinfo *__addrinfo_ptr32;: typedef const struct addrinfo *__const_addrinfo_ptr32;5 typedef __addrinfo_ptr32 *__addrinfo_ptr32_ptr32;4 typedef struct __addrinfo32 *__addrinfo32_ptr32;9 typedef __addrinfo32_ptr32 *__addrinfo32_ptr32_ptr32;@ typedef const struct __addrinfo32 *__const_addrinfo32_ptr32;##endif /* __INITIAL_POINTER_SIZE *//* * addrinfo structure */struct addrinfo {9 int ai_flags; /* input flags */D int ai_family; /* protofamily for socket */9 int ai_socktype; /* soc ket type */A int ai_protocol; /* protocol for socket */F size_t ai_addrlen; /* length of socket-address */U char *ai_canonname; /* service location canonical name */G struct sockaddr *ai_addr; /* socket-address for socket */E struct addrinfo *ai_next; /* pointer to next in list */};, typedef struct addrinfo *__addrinfo_ptr;/ typedef __addrinfo_ptr *__addrinfo_ptr_ptr;8 typedef const struct addrinfo *__const_addrinfo_ptr;#if __CRTL_VER >= 70300000 # if __INITIAL_POINTER_SIZE# pragma __pointer_size 64 # endifXint getaddrinfo(const char *, const char *, const struct addrinfo *, __addrinfo_ptr * );aint getaddrinfo_compat43(const char *, const char *, const struct addrinfo *, __addrinfo_ptr * );%void freeaddrinfo(struct addrinfo *);Wint getnameinfo (const struct sockaddr *, size_t, char *, size_t, char *, size_t, int);# if __INITIAL_POINTER_SIZE# pr agma __pointer_size 32 # endifconst char *gai_strerror (int);#endif5#if __INITIAL_POINTER_SIZE && __CRTL_VER >= 70311000pint __getaddrinfo32(__const_char_ptr32, __const_char_ptr32, __const_addrinfo32_ptr32, __addrinfo32_ptr32_ptr32);yint __getaddrinfo_compat4332(__const_char_ptr32, __const_char_ptr32, __const_addrinfo32_ptr32, __addrinfo32_ptr32_ptr32);*void __freeaddrinfo32(__addrinfo32_ptr32);pint __getaddrinfo64(__const_char_ptr64, __const_char_ptr64, __const_addrinfo64_ptr 64, __addrinfo64_ptr64_ptr64);yint __getaddrinfo_compat4364(__const_char_ptr64, __const_char_ptr64, __const_addrinfo64_ptr64, __addrinfo64_ptr64_ptr64);*void __freeaddrinfo64(__addrinfo64_ptr64);#endif:#if __INITIAL_POINTER_SIZE == 64 && __CRTL_VER >= 70311000Q# define getaddrinfo(__P1,__p2,__P3,__P4) __getaddrinfo64(__P1,__p2,__P3,__P4)b# define getaddrinfo_compat43(__P1,__p2,__P3,__P4) __getaddrinfo_compat4364(__P1,__p2,__P3,__P4)7# define freeaddrinfo(__P1) __freeaddrinfo64(__P1)#endif#if !defined(_SOCKADDR_LEN) # if __CRTL_VER >= 70300000# ifdef getaddrinfo# undef getaddrinfo# endifS# define getaddrinfo(__p1,__p2,__p3,__p4) getaddrinfo_compat43(__p1,__p2,__p3,__p4) # endif8# if __INITIAL_POINTER_SIZE && __CRTL_VER >= 70311000[# define __getaddrinfo32(__P1,__p2,__P3,__P4) __getaddrinfo_compat4332(__P1,__p2,__P3,__P4)[# define __getaddrinfo64(__P1,__p2,__P3,__P4) __getaddrinfo_compat4364(__P1,__p2,__P3,__P4) # endif#endif/* ! * Error values for getaddrinfo() */M#define EAI_ADDRFAMILY 1 /* address family for hostname not supported */H#define EAI_AGAIN 2 /* temporary failure in name resolution */>#define EAI_BADFLAGS 3 /* invalid value for ai_flags */N#define EAI_FAIL 4 /* non-recoverable failure in name resolution */;#define EAI_FAMILY 5 /* ai_family not supported */=#define EAI_MEMORY 6 /* memory allocation failure */G#define EAI_NODATA 7 /* no ad dress associated with hostname */P#define EAI_NONAME 8 /* hostname nor servname provided, or not known */J#define EAI_SERVICE 9 /* servname not supported for ai_socktype */=#define EAI_SOCKTYPE 10 /* ai_socktype not supported */B#define EAI_SYSTEM 11 /* system error returned in errno */#define EAI_BADHINTS 12#define EAI_PROTOCOL 13#define EAI_MAX 14/*O** If the user has used /pointer_size=32 or /pointer_size=64, we will allow 64.** bit pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*L** The following functions return pointers to memory allocated by the DEC CI** RTL or the underlying tcp/ip layer. These pointers are always 32 bit@** pointers, while the pointer parameters may be 32 or 64 bits.*/I__struct_netent_ptr32 getnetbyaddr (__in_addr_t __net, int __type);0__struct_netent_ptr32 getnetent (void);7__struct_protoent_ptr32 getprotobynumb er (int __proto);0__struct_protoent_ptr32 getprotoent (void); >__struct_netent_ptr32 getnetbyname (const char *__name);S__struct_servent_ptr32 getservbyname (const char *__name, const char *__proto);K__struct_servent_ptr32 getservbyport (int __port, const char *__proto);>__struct_protoent_ptr32 getprotobyname (const char *__name);#if __CRTL_VER >= 700000004 __struct_hostent_ptr32 gethostent (void);4 __struct_servent_ptr32 getservent (void); void endnetent (void); void endprotoent (void); void endhostent (void); void endservent (void);& void sethostent (int __stayopen);& void setservent (int __stayopen);& void setnetent (int __stayopen);& void setprotoent (int __stayopen);#endif/*2** These functions have new semantics for BSD 4.4*/#ifdef _SOCKADDR_LEN# if __CAN_USE_EXTERN_PREFIX%# pragma __extern_prefix __save)# pragma __extern_prefix "__bsd44_"# elseT#  define gethostbyaddr(__p1,__p2,__p3) __bsd44_gethostbyaddr(__p1,__p2,__p3)J# define gethostbyname(__p1) __bsd44_gethostbyname(__p1) # endif#endifT__struct_hostent_ptr32 gethostbyaddr (const void *__addr, size_t __len, int __type);:__struct_hostent_ptr32 gethostbyname (const char *__name);:__struct_hostent_ptr32 gethostbyname2 (const char *, int);#ifdef _SOCKADDR_LEN# if __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __restore # endif#endif/* ** DEC C Extensions*/ =#if !defined _XOPEN_SOURCE_EXTENDED && __CRTL_VER >= 70000000# void herror (const char *__s1); /*> ** The hstrerror function always returns a 32 bit pointer */% __char_ptr32 hstrerror (int __n);#endif)#define NETDB_INTERNAL -1 /* see errno */(#define NETDB_SUCCESS 0 /* no problem */B#define HOST_NOT_FOUND 1 /* Authoritative Answer Host not found */G#define TRY_AGAIN 2 /* Non-Authoritive Host not found, or SERVERFAIL */L#define NO_RECOVERY 3 /* Non recoverable errors, FORMERR, REFUSED, NOTIMP */E#define NO_DATA 4 /* Valid name, no data record of requested type */@#define NO_ADDRESS NO_DATA /* no address, look for MX record *//*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#pragma __standard#endif /* __NETDB_LOADED */wwV5ԗ#ifndef __NL_TYPES_LOADED#define __NL_TYPES_LOADED 1#pragma __nostandard#include A#if __CRTL_VER >= 60200000 /* Support added in OpenVMS V6.2 */M/******************************************************************************** - data types**M*****************************************************************************>** Header introduced by the X/Open CAE Specification, Issue 4M*****************************************************************************I**  I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M***************************************************************************** */#ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*"** Define structures and typedefs*/'typedef struct _nl_catdstruct *nl_catd;typedef int nl_item;/*** Define constants*/#define NL_CAT_LOCALE 1#define NL_SETD 1/*G** When compiling with /POINTER_SIZE, change to long pointers so that I** prototypes reflect the implementation for widened pointers. W hen notG** using /POINTER_SIZE, the prototypes do not allow for long pointers.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*** Function prototypes*/2nl_catd catopen (const char *__name, int __oflag);int catclose (nl_catd __catd);/*K** The following functions default the parameters and return values to theI** pointer_size used in the command line. Two additional functions are L** provided if the application needs to specically use the 32 bit o r 64 bit** interfaces.*/ #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 32#endifKchar *catgets(nl_catd __catd, int __set_id, int __msg_id, const char* __s); #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 64#endif4#if __INITIAL_POINTER_SIZE && __CRTL_VER >= 70000000# pragma __pointer_size 328 char * _catgets32 (nl_catd, int, int, const char *);# pragma __pointer_size 648 char * _catgets64 (nl_catd, int, int, const char *);#endif/*%**  Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#endif#pragma __standard #endif /* __NL_TYPES_LOADED */ww{'5ԗM/******************************************************************************** **M*******************************************************************************=** Copyright 2005 Hewlett-Packard Development Company, L.P.**@** Confide ntial computer software. Valid license from HP and/or=** its subsidiaries required for possession, use, or copying.**G** Consistent with FAR 12.211 and 12.212, Commercial Computer Software,E** Computer Software Documentation, and Technical Data for CommercialD** Items are licensed to the U.S. Government under vendor's standard** commercial license.**G** Neither HP nor any of its subsidiaries shall be liable for technicalF** or editorial errors or omissions contained herein. The infor mationH** in this document is provided "as is" without warranty of any kind andG** is subject to change without notice. The warranties for HP productsH** are set forth in the express limited warranty statements accompanyingH** such products. Nothing herein should be construed as constituting an** additional warranty.**M******************************************************************************//*-? * Copyright (c) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997E * The Regents o f the University of California. All rights reserved. *A * This code is derived from the Stanford/CMU enet packet filter,C * (net/enet.c) distributed as part of 4.3BSD, and code contributedC * to Berkeley by Steven McCanne and Van Jacobson both of Lawrence  * Berkeley Laboratory. *E * Redistribution and use in source and binary forms, with or withoutE * modification, are permitted provided that the following conditions * are met:D * 1. Redistributions of source code must retain the above copyrightC * notice, this list of conditions and the following disclaimer.G * 2. Redistributions in binary form must reproduce the above copyrightI * notice, this list of conditions and the following disclaimer in theJ * documentation and/or other materials provided with the distribution.K * 3. All advertising materials mentioning features or use of this software1 * must display the following acknowledgement:E * This product includes software developed by the Univ ersity of2 * California, Berkeley and its contributors.J * 4. Neither the name of the University nor the names of its contributorsK * may be used to endorse or promote products derived from this software0 * without specific prior written permission. *J * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' ANDH * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THEM * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSEK * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLEM * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIALJ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODSH * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)M * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICTL * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAYI * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. *- * @(#)bpf.h 7.1 (Berkeley) 5/7/91 *d * @(#) $Header: /tcpdump/master/libpcap/pcap-bpf.h,v 1.9.2.9 2004/03/28 21:45:32 fenner Exp $ (LBL) *//*@ * This is libpcap's cut-down version of bpf.h; it includes only? * the stuff needed for the code generator and the userland BPF? * interpreter, and the libpcap APIs for setting filters, etc.. *D * "pcap-bpf.c" will include the native OS version, as it deals with * the OS's BPF implementation. *3 * XXX - should this all just be moved to "pcap.h"? */#ifndef BPF_MAJOR_VERSION#ifdef __cplusplus extern "C" {#endif #ifdef __VMS/*7** Set __nomember_alignment to avoid internal and tail2** padding in structures; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment#endif /* __VMS *//* BSD style release date */#define BPF_RELEASE 199606typedef int bpf_int32;typedef u_int bpf_u_int32;/*: * Alignment macros. BPF_WORDALIGN rounds up to the next # * even multiple of BPF_ALIGNMENT.  */#ifndef __NetBSD__'#define BPF_ALIGNMENT sizeof(bpf_int32)#else"#define BPF_ALIGNMENT sizeof(long)#endifE#define BPF_WORDALIGN(x) (((x)+(BPF_ALIGNMENT-1))&~(BPF_ALIGNMENT-1))#define BPF_MAXINSNS 512#define BPF_MAXBUFSIZE 0x8000#define BPF_MINBUFSIZE 32/*< * Structure for "pcap_compile()", "pcap_setfilter()", etc.. */ struct bpf_program { u_int bf_len; struct bpf_insn *bf_insns;}; /*H * Struct return by BIOCVERSION. This represents the version number of D * the filter language described by the instruction encodings below.@ * bpf understands a program iff kernel_major == filter_major &&F * kernel_minor >= filter_minor, that is, if the value returned by theD * running kernel has the same major number and a minor number equalE * equal to or less than the filter being downloaded. Otherwise, theE * results are undefined, meaning an error may be returned or packets * may be accepted haphazardly.5 * It has nothing to do with the source code version. */struct bpf_version { u_short bv_major; u_short bv_minor;};4/* Current version number of filter architecture. */#define BPF_MAJOR_VERSION 1#define BPF_MINOR_VERSION 1/* * Data-link level type codes. *6 * Do *NOT* add new values to this list without askingE * "tcpdump-workers@tcpdump.org" for a value. Otherwise, you run theJ * risk of using a value that's already being used for some other purpose,G * and of having tools that read libpcap-format captures not being ableF * to handle captures with your new DLT_ value, with no hope that theyE * will ever be changed to do so (as that would destroy their ability= * to read captures using that value for that other purpose). *//*C * These are the types that are the same on all platforms, and that- * have been defined by for ages. */4#d efine DLT_NULL 0 /* no link-layer encapsulation */*#define DLT_EN10MB 1 /* Ethernet (10Mb) */5#define DLT_EN3MB 2 /* Experimental Ethernet (3Mb) */,#define DLT_AX25 3 /* Amateur Radio AX.25 */4#define DLT_PRONET 4 /* Proteon ProNET Token Ring */#define DLT_CHAOS 5 /* Chaos */-#define DLT_IEEE802 6 /* IEEE 802 Networks */8#define DLT_ARCNET 7 /* ARCNET, with BSD-style header */'#define DLT_SLIP 8 /* Serial Line IP */0#define DLT_PPP 9 /* Point-to-point Protocol */#define DLT_FDDI 10 /* FDDI *//*A * These are types that are different on some platforms, and that@ * have been defined by for ages. We use #ifdefs toD * detect the BSDs that define them differently from the traditional * libpcap  *F * XXX - DLT_ATM_RFC1483 is 13 in BSD/OS, and DLT_RAW is 14 in BSD/OS,9 * but I don't know what the right #define is for BSD/OS. */:#define DLT_ATM_RFC1483 11 /* LLC/SNAP encapsulated atm */#ifdef __OpenBSD__ #define DLT_RAW 14 /* raw IP */#else #define DLT_RAW 12 /* raw IP */#endif/*E * Given that the only OS that currently generates BSD/OS SLIP or PPPE * is, well, BSD/OS, arguably everybody should have chosen its valuesF * for DLT_SLIP_BSDOS and DLT_PPP_BSDOS, which are 15 and 16, but they * didn't. So it goes. *//#if defined(__NetBSD__) || defined(__FreeBSD__)#ifndef DLT_SLIP_BSDOS5#define DLT_SLIP_BSDOS 13 /* BSD/OS Serial Line IP */=#define DLT_PPP_BSDOS 14 /* BSD/OS Point-to-point Protocol */#endif#else5#define DLT_SLIP_BSDOS 15 /* BSD/OS Serial Line IP */=#define DLT_PPP_BSDOS 16 /* BSD/OS Point-to-point Protocol */#endif/*+ * 17 is used for DLT_OLD_PFLOG in OpenBSD;D * OBSOLETE: DLT_PFLOG is 117 in OpenBSD now as well. See below.H * 18 is used for DLT_PFSYNC in OpenBSD; don't use it for anything else. */9#define DLT_ATM_CLIP 19 /* Linux Classical-IP over ATM *//*J * These values are defined by NetBSD; other platforms should refrain fromD * using them for other purp oses, so that NetBSD savefiles with link? * types of 50 or 51 can be read as this type on all platforms. */G#define DLT_PPP_SERIAL 50 /* PPP over serial with HDLC encapsulation */0#define DLT_PPP_ETHER 51 /* PPP over Ethernet *//*J * The Axent Raptor firewall - now the Symantec Enterprise Firewall - usesG * a link-layer type of 99 for the tcpdump it supplies. The link-layerF * header has 6 bytes of unknown data, something that appears to be anJ * Ethernet type, and 36 bytes that appear to be 0 in at least one capture * I've seen. */ #define DLT_SYMANTEC_FIREWALL 99/*A * Values between 100 and 103 are used in capture file headers as; * link-layer types corresponding to DLT_ types that differD * between platforms; don't use those values for new DLT_ new types. *//*E * This value was defined by libpcap 0.5; platforms that have definedD * it with a different value should define it here with that value -B * a link type of 104 in a save file will be mapped to  DLT_C_HDLC,@ * whatever value that happens to be, so programs will correctly> * handle files with that link type regardless of the value of * DLT_C_HDLC. *F * The name DLT_C_HDLC was used by BSD/OS; we use that name for source2 * compatibility with programs written for BSD/OS. *D * libpcap 0.5 defined it as DLT_CHDLC; we define DLT_CHDLC as well,B * for source compatibility with programs written for libpcap 0.5. */'#define DLT_C_HDLC 104 /* Cisco HDLC */#define DLT_CHDLC DLT_C_HDLC 5#define DLT_IEEE802_11 105 /* IEEE 802.11 wireless *//*F * 106 is reserved for Linux Classical IP over ATM; it's like DLT_RAW,@ * except when it isn't. (I.e., sometimes it's just raw IP, andA * sometimes it isn't.) We currently handle it as DLT_LINUX_SLL,? * so that we don't have to worry about the link-layer header.) *//*I * Frame Relay; BSD/OS has a DLT_FR with a value of 11, but that collides * with other values.H * DLT_FR and DLT_FRELAY packets start with the Q.922 Fr!ame Relay header * (DLCI, etc.). */#define DLT_FRELAY 107/*E * OpenBSD DLT_LOOP, for loopback devices; it's like DLT_NULL, exceptG * that the AF_ type in the link-layer header is in network byte order. *B * OpenBSD defines it as 12, but that collides with DLT_RAW, so weC * define it as 108 here. If OpenBSD picks up this file, it shouldC * define DLT_LOOP as 12 in its version, as per the comment above -* * and should not use 108 as a DLT_ value. */#define DLT_LOOP 108/*"G * Encapsulated packets for IPsec; DLT_ENC is 13 in OpenBSD, but that'sD * DLT_SLIP_BSDOS in NetBSD, so we don't use 13 for it in OSes other * than OpenBSD. */#ifdef __OpenBSD__#define DLT_ENC 13#else#define DLT_ENC 109#endif/*J * Values between 110 and 112 are reserved for use in capture file headersD * as link-layer types corresponding to DLT_ types that might differ? * between platforms; don't use those values for new DLT_ types+ * other than the corresponding DLT_ t#ypes. *//*$ * This is for Linux cooked sockets. */#define DLT_LINUX_SLL 113/* * Apple LocalTalk hardware. */#define DLT_LTALK 114/* * Acorn Econet. */#define DLT_ECONET 115/** * Reserved for use with OpenBSD ipfilter. */#define DLT_IPFILTER 116/*I * OpenBSD DLT_PFLOG; DLT_PFLOG is 17 in OpenBSD, but that's DLT_LANE8023B * in SuSE 6.3, so we can't use 17 for it in capture-file headers. *7 * XXX: is there a conflict with DLT_PFSYNC 18 as well?$ */#ifdef __OpenBSD__#define DLT_OLD_PFLOG 17#define DLT_PFSYNC 18#endif#define DLT_PFLOG 117/*% * Registered for Cisco-internal use. */#define DLT_CISCO_IOS 118/*? * For 802.11 cards using the Prism II chips, with a link-layerA * header including Prism monitor mode information plus an 802.11 * header. */#define DLT_PRISM_HEADER 119/*G * Reserved for Aironet 802.11 cards, with an Aironet link-layer header) * (see Doug Ambrisko's FreeBSD patches). */%#define DLT_AIRONET_HEADER 120/*$ * Reserved for Siemens HiPath HDLC. */#define DLT_HHDLC 121/*. * This is for RFC 2625 IP-over-Fibre Channel. *C * This is not for use with raw Fibre Channel, where the link-layerH * header starts with a Fibre Channel frame header; it's for IP-over-FC,E * where the link-layer header starts with an RFC 2625 Network_Header * field. */#define DLT_IP_OVER_FC 122/*> * This is for Full Frontal ATM on Solaris with SunATM, with a) * pseud &o-header followed by an AALn PDU. *> * There may be other forms of Full Frontal ATM on other OSes,! * with different pseudo-headers. *C * If ATM software returns a pseudo-header with VPI/VCI informationA * (and, ideally, packet type information, e.g. signalling, ILMI,: * LANE, LLC-multiplexed traffic, etc.), it should not use? * DLT_ATM_RFC1483, but should get a new DLT_ value, so tcpdump@ * and the like don't have to infer the presence or absence of a3 * pseudo-header and the form of' the pseudo-header. */,#define DLT_SUNATM 123 /* Solaris+SunATM *//* @ * Reserved as per request from Kent Dahlgren  * for private use. */5#define DLT_RIO 124 /* RapidIO */9#define DLT_PCI_EXP 125 /* PCI Express */F#define DLT_AURORA 126 /* Xilinx Aurora link layer *//*H * BSD header for 802.11 plus a number of bits of link-layer information * including radio information. */C#define DLT_IEEE802_11(_RADIO 127 /* 802.11 plus BSD radio header *//*; * Reserved for the TZSP encapsulation, as per request from3 * Chris Waters ; * TZSP is a generic encapsulation for any other link type,5 * which includes a means to include meta-information4 * with the packet, e.g. signal strength and channel * for 802.11 packets. */E#define DLT_TZSP 128 /* Tazmen Sniffer Protocol *//*? * BSD's ARCNET headers have the source host, destinatio)n host,@ * and type at the beginning of the packet; that's what's handed * up to userland via BPF. *> * Linux's ARCNET headers, however, have a 2-byte offset field= * between the host IDs and the type; that's what's handed up% * to userland via PF_PACKET sockets. *; * We therefore have to have separate DLT_ values for them. */)#define DLT_ARCNET_LINUX 129 /* ARCNET *//*7 * Juniper-private data link types, as per request from; * Hannes Gredler . The DLT_s* are used: * for passing on chassis-internal metainformation such as * QOS profiles, etc.. */##define DLT_JUNIPER_MLPPP 130##define DLT_JUNIPER_MLFR 131##define DLT_JUNIPER_ES 132##define DLT_JUNIPER_GGSN 133##define DLT_JUNIPER_MFR 134##define DLT_JUNIPER_ATM2 135##define DLT_JUNIPER_SERVICES 136##define DLT_JUNIPER_ATM1 137/*A * Apple IP-over-IEEE 1394, as per a request from Dieter SiegmundG * . Th+e header that's presented is an Ethernet-like * header: * * #define FIREWIRE_EUI64_LEN 8 * struct firewire_header {/ * u_char firewire_dhost[FIREWIRE_EUI64_LEN];/ * u_char firewire_shost[FIREWIRE_EUI64_LEN]; * u_short firewire_type; * }; *B * with "firewire_type" being an Ethernet type value, rather than,0 * for example, raw GASP frames being handed up. */&#define DLT_APPLE_IP_OVER_IEEE1394 138/*( * 139 through 142 are reserved for SS7. *//*" * Reserved fo ,r DOCSIS MAC frames. */#define DLT_DOCSIS 143/*? * Linux-IrDA packets. Protocol defined at http://www.irda.org.@ * Those packets include IrLAP headers and above (IrLMP...), butG * don't include Phy framing (SOF/EOF/CRC & byte stuffing), because PhyD * framing can be handled by the hardware and depend on the bitrate.E * This is exactly the format you would get capturing on a Linux-IrDA3 * interface (irdaX), but not on a raw serial port.J * Note the capture is done in "Linux-cooked-" mode, so each packet includeH * a fake packet header (struct sll_header). This is because IrDA packetE * decoding is dependant on the direction of the packet (incomming or * outgoing).D * When/if other platform implement IrDA capture, we may revisit the& * issue and define a real DLT_IRDA... * Jean II */#define DLT_LINUX_IRDA 144/*= * Reserved for IBM SP switch and IBM Next Federation switch. */#define DLT_IBM_SP 145#define DLT_IBM_SN 146/*E * Reserved for priv .ate use. If you have some link-layer header typeH * that you want to use within your organization, with the capture filesB * using that link-layer header type not ever be sent outside your* * organization, you can use these values. *B * No libpcap release will use these for any purpose, nor will any$ * tcpdump release use them, either. *H * Do *NOT* use these in capture files that you expect anybody not usingB * your private versions of capture-file-reading tools to read; inI * particula /r, do *NOT* use them in products, otherwise you may find thatG * people won't be able to use tcpdump, or snort, or Ethereal, or... toD * read capture files from your firewall/intrusion detection/trafficG * monitoring/etc. appliance, or whatever product uses that DLT_ value,G * and you may also find that the developers of those applications will3 * not accept patches to let them read those files. *H * Also, do not use them if somebody might send you a capture using themH * for *their* pri0vate type and tools using them for *your* private type * would have to read them. *C * Instead, ask "tcpdump-workers@tcpdump.org" for a new DLT_ value,; * as per the comment above, and use the type you're given. */#define DLT_USER0 147#define DLT_USER1 148#define DLT_USER2 149#define DLT_USER3 150#define DLT_USER4 151#define DLT_USER5 152#define DLT_USER6 153#define DLT_USER7 154#define DLT_USER8 155#define DLT_USER9 156#define DLT_USER10 157#define DLT_1USER11 158#define DLT_USER12 159#define DLT_USER13 160#define DLT_USER14 161#define DLT_USER15 162/*A * For future use with 802.11 captures - defined by AbsoluteValue> * Systems to store a number of bits of link-layer information * including radio information: *9 * http://www.shaftnet.org/~pizza/software/capturefrm.txt *> * but could and arguably should also be used by non-AVS Linux1 * 802.11 drivers; that may happen in the future. */G#define DLT_IEEE802_11_RAD2IO_AVS 163 /* 802.11 plus AVS radio header *//*6 * Juniper-private data link type, as per request from; * Hannes Gredler . The DLT_s are used: * for passing on chassis-internal metainformation such as * QOS profiles, etc.. */##define DLT_JUNIPER_MONITOR 164/* * The instruction encodings. *//* instruction classes */'#define BPF_CLASS(code) ((code) & 0x07)#define BPF_LD 0x00#define BPF_LDX 0x01#define BPF_ST 0x02#define BPF_STX 0x303#define BPF_ALU 0x04#define BPF_JMP 0x05#define BPF_RET 0x06#define BPF_MISC 0x07/* ld/ldx fields */&#define BPF_SIZE(code) ((code) & 0x18)#define BPF_W 0x00#define BPF_H 0x08#define BPF_B 0x10&#define BPF_MODE(code) ((code) & 0xe0)#define BPF_IMM 0x00#define BPF_ABS 0x20#define BPF_IND 0x40#define BPF_MEM 0x60#define BPF_LEN 0x80#define BPF_MSH 0xa0/* alu/jmp fields */$#define BPF_OP(code) ((code) & 0xf0)#define BPF_ADD 0x00#defin4e BPF_SUB 0x10#define BPF_MUL 0x20#define BPF_DIV 0x30#define BPF_OR 0x40#define BPF_AND 0x50#define BPF_LSH 0x60#define BPF_RSH 0x70#define BPF_NEG 0x80#define BPF_JA 0x00#define BPF_JEQ 0x10#define BPF_JGT 0x20#define BPF_JGE 0x30#define BPF_JSET 0x40%#define BPF_SRC(code) ((code) & 0x08)#define BPF_K 0x00#define BPF_X 0x08&/* ret - BPF_K and BPF_X also apply */&#define BPF_RVAL(code) ((code) & 0x18)#define BPF_A 0x10 /* misc */5(#define BPF_MISCOP(code) ((code) & 0xf8)#define BPF_TAX 0x00#define BPF_TXA 0x80/*" * The instruction data structure. */struct bpf_insn { u_short code; u_char jt; u_char jf; bpf_int32 k;};/*& * Macros for insn array initializers. */6#define BPF_STMT(code, k) { (u_short)(code), 0, 0, k }@#define BPF_JUMP(code, k, jt, jf) { (u_short)(code), jt, jf, k }$#if __STDC__ || defined(__cplusplus)0extern int bpf_validate(struct bpf_insn *, int);Cextern u_int bpf_f6ilter(struct bpf_insn *, u_char *, u_int, u_int);#elseextern int bpf_validate();extern u_int bpf_filter();#endif/*B * Number of scratch memory words (for BPF_LD|BPF_MEM and BPF_ST). */#define BPF_MEMWORDS 16 #ifdef __VMS$#pragma __member_alignment __restore#endif /* __VMS */#ifdef __cplusplus}#endif#endifww5ԗM/****************************************************************************** ** **M******************************** 7***********************************************=** Copyright 2005 Hewlett-Packard Development Company, L.P.**@** Confidential computer software. Valid license from HP and/or=** its subsidiaries required for possession, use, or copying.**G** Consistent with FAR 12.211 and 12.212, Commercial Computer Software,E** Computer Software Documentation, and Technical Data for CommercialD** Items are licensed to the U.S. Government under vendor's standard** commercial license.**G** Neith 8er HP nor any of its subsidiaries shall be liable for technicalF** or editorial errors or omissions contained herein. The informationH** in this document is provided "as is" without warranty of any kind andG** is subject to change without notice. The warranties for HP productsH** are set forth in the express limited warranty statements accompanyingH** such products. Nothing herein should be construed as constituting an** additional warranty.**M****************************************** 9************************************/L/* -*- Mode: c; tab-width: 8; indent-tabs-mode: 1; c-basic-offset: 8; -*- *//*- * Copyright (c) 1993, 1994, 1995, 1996, 1997E * The Regents of the University of California. All rights reserved. *E * Redistribution and use in source and binary forms, with or withoutE * modification, are permitted provided that the following conditions * are met:D * 1. Redistributions of source code must retain the above copyrightC * notice, this list of con:ditions and the following disclaimer.G * 2. Redistributions in binary form must reproduce the above copyrightI * notice, this list of conditions and the following disclaimer in theJ * documentation and/or other materials provided with the distribution.K * 3. All advertising materials mentioning features or use of this software1 * must display the following acknowledgement:C * This product includes software developed by the Computer Systems5 * Engineering Group at Lawrence Berkele ;y Laboratory.J * 4. Neither the name of the University nor of the Laboratory may be usedG * to endorse or promote products derived from this software without( * specific prior written permission. *J * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' ANDH * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THEM * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSEK * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTOR <S BE LIABLEM * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIALJ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODSH * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)M * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICTL * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAYI * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. *^ * @(#=) $Header: /tcpdump/master/libpcap/pcap.h,v 1.45.2.4 2004/01/27 22:56:20 guy Exp $ (LBL) */#ifndef lib_pcap_h#define lib_pcap_h #ifdef WIN32#include #else /* WIN32 */#include #include #endif /* WIN32 */$#ifndef PCAP_DONT_INCLUDE_PCAP_BPF_H#include #endif#include #ifdef __cplusplus extern "C" {#endif #ifdef __VMS/*7** Set __nomember_alignment to avoid internal and tail2** padding in structu>res; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment#endif /* __VMS */#define PCAP_VERSION_MAJOR 2#define PCAP_VERSION_MINOR 4#define PCAP_ERRBUF_SIZE 256/*3 * Compatibility for systems that have a bpf.h that0 * predates the bpf typedefs for 64-bit support. */#if BPF_RELEASE - 0 < 199406typedef int bpf_int32;typedef u_int bpf_u_int32;#endiftypedef struct pcap pcap ?_t;)typedef struct pcap_dumper pcap_dumper_t;!typedef struct pcap_if pcap_if_t;%typedef struct pcap_addr pcap_addr_t;/*> * The first record in the file contains saved values for some7 * of the flags used in the printout phases of tcpdump.F * Many fields here are 32 bit ints so compilers won't insert unwantedH * padding; these files need to be interchangeable across architectures. *H * Do not change the layout of this structure, in any way (this includesD * changes that only affect @the length of fields in this structure). *G * Also, do not change the interpretation of any of the members of this? * structure, in any way (this includes using values other thanB * LINKTYPE_ values, as defined in "savefile.c", in the "linktype" * field). * * Instead: *> * introduce a new structure for the new format, if the layout * of the structure changed; *? * send mail to "tcpdump-workers@tcpdump.org", requesting a new; * magic number for your new capture file format, and, A when8 * you get the new magic number, put it in "savefile.c"; *= * use that magic number for save files with the changed file * header; *> * make the code in "savefile.c" capable of reading files with@ * the old file header as well as files with the new file header; * (using the magic number to determine the header format). *C * Then supply the changes to "patches@tcpdump.org", so that futureF * versions of libpcap and programs that use it (such as tcpdump) will0 * be able to readB your new capture file format. */struct pcap_file_header { bpf_u_int32 magic; u_short version_major; u_short version_minor;2 bpf_int32 thiszone; /* gmt to local correction */2 bpf_u_int32 sigfigs; /* accuracy of timestamps */@ bpf_u_int32 snaplen; /* max length saved portion of each pkt */8 bpf_u_int32 linktype; /* data link type (LINKTYPE_*) */};/*F * Each packet in the dump file is prepended with this generic header.B * This gets around the problem of different headers forC different * packet interfaces. */struct pcap_pkthdr {$ struct timeval ts; /* time stamp */4 bpf_u_int32 caplen; /* length of portion present */5 bpf_u_int32 len; /* length this packet (off wire) */};/*" * As returned by the pcap_stats() */struct pcap_stat {1 u_int ps_recv; /* number of packets received */0 u_int ps_drop; /* number of packets dropped */@ u_int ps_ifdrop; /* drops by interface XXX not yet supported */ #ifdef WIN32C u_int bs_capt; /* number of packets thDat reach the application */#endif /* WIN32 */};/* * Item in a list of interfaces. */struct pcap_if { struct pcap_if *next;6 char *name; /* name to hand to "pcap_open_live()" */C char *description; /* textual description of interface, or NULL */ struct pcap_addr *addresses;2 bpf_u_int32 flags; /* PCAP_IF_ interface flags */};?#define PCAP_IF_LOOPBACK 0x00000001 /* interface is loopback *//** * Representation of an interface address. */struct pcap_addr { struc Et pcap_addr *next;& struct sockaddr *addr; /* address */9 struct sockaddr *netmask; /* netmask for that address */E struct sockaddr *broadaddr; /* broadcast address for that address */I struct sockaddr *dstaddr; /* P2P destination address for that address */};Btypedef void (*pcap_handler)(u_char *, const struct pcap_pkthdr *, const u_char *);char *pcap_lookupdev(char *);Gint pcap_lookupnet(const char *, bpf_u_int32 *, bpf_u_int32 *, char *);<pcap_t *pcap_open_live(const c Fhar *, int, int, int, char *);!pcap_t *pcap_open_dead(int, int);0pcap_t *pcap_open_offline(const char *, char *);void pcap_close(pcap_t *);5int pcap_loop(pcap_t *, int, pcap_handler, u_char *);9int pcap_dispatch(pcap_t *, int, pcap_handler, u_char *); const u_char*+ pcap_next(pcap_t *, struct pcap_pkthdr *);Dint pcap_next_ex(pcap_t *, struct pcap_pkthdr **, const u_char **);void pcap_breakloop(pcap_t *);-int pcap_stats(pcap_t *, struct pcap_stat *);3int pcap_setfilter(pcap_t *, strGuct bpf_program *);'int pcap_getnonblock(pcap_t *, char *);,int pcap_setnonblock(pcap_t *, int, char *);#void pcap_perror(pcap_t *, char *);char *pcap_strerror(int);char *pcap_geterr(pcap_t *);=int pcap_compile(pcap_t *, struct bpf_program *, char *, int, bpf_u_int32);7int pcap_compile_nopcap(int, int, struct bpf_program *, char *, int, bpf_u_int32);)void pcap_freecode(struct bpf_program *);int pcap_datalink(pcap_t *);*int pcap_list_datalinks(pcap_t *, int **);%int pcHap_set_datalink(pcap_t *, int);,int pcap_datalink_name_to_val(const char *);+const char *pcap_datalink_val_to_name(int);2const char *pcap_datalink_val_to_description(int);int pcap_snapshot(pcap_t *);int pcap_is_swapped(pcap_t *);!int pcap_major_version(pcap_t *);!int pcap_minor_version(pcap_t *);6int pcap_sendpacket(pcap_t *p, u_char *buf, int size); /* XXX */FILE *pcap_file(pcap_t *);int pcap_fileno(pcap_t *);6pcap_dumper_t *pcap_dump_open(pcap_t *, const char *);%int pcap_dumIp_flush(pcap_dumper_t *);&void pcap_dump_close(pcap_dumper_t *);Evoid pcap_dump(u_char *, const struct pcap_pkthdr *, const u_char *);&FILE *pcap_dump_file(pcap_dumper_t *);+int pcap_findalldevs(pcap_if_t **, char *);#void pcap_freealldevs(pcap_if_t *);#const char *pcap_lib_version(void);(/* XXX this guy lives in the bpf tree */<u_int bpf_filter(struct bpf_insn *, u_char *, u_int, u_int);.int bpf_validate(struct bpf_insn *f, int len);(char *bpf_image(struct bpf_insn *, int);)voidJ bpf_dump(struct bpf_program *, int); #ifdef WIN32/* * Win32 definitions */%int pcap_setbuff(pcap_t *p, int dim);&int pcap_setmode(pcap_t *p, int mode);6int pcap_sendpacket(pcap_t *p, u_char *buf, int size);+int pcap_setmintocopy(pcap_t *p, int size); #ifdef WPCAP5/* Include file with the wpcap-specific extensions */#include #endif#define MODE_CAPT 0#define MODE_STAT 1#define MODE_MON 2#else/* * UN*X definitions */%int pcap_getK_selectable_fd(pcap_t *);#endif /* WIN32 */ #ifdef __VMS$#pragma __member_alignment __restore#endif /* __VMS */#ifdef __cplusplus}#endif#endifwwY 6ԗ#ifndef __PERROR_LOADED#define __PERROR_LOADED 1M/******************************************************************************)** - error message variables **M******************************************************************************* Header is nonstandardM********************L*********************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** M I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contNained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M**************O****************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*?** sys_nerr and sys_errlist are implemented as of OpenVMS V6.2*/#if __CRTL_VER >= 60200000 /*) ** Real values in the DECC$SHR image */ # pragma __extern_model __save*# pragma __extern_model __relaxePd_refdef extern int sys_nerr; extern char *sys_errlist[];## pragma __extern_model __restore#else /*- ** Pre-V6.2 Stub values resolved in OLBs */#if !defined(__VAX) # pragma __extern_model __save*# pragma __extern_model __relaxed_refdef extern int sys_nerr; extern char *sys_errlist[];## pragma __extern_model __restore#else # pragma __extern_model __save(# pragma __extern_model __common_block extern int sys_nerr; extern chaQr *sys_errlist[];## pragma __extern_model __restore#endif#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __PERROR_LOADED */wwX6ԗ#ifndef _POLL_LOADED#define _POLL_LOADED#pragma __nostandard#include #if __CRTL_VER >= 70311000M/******************************************************************* R***********2** - definitions for the poll() function**M*****************************************************************************H** Header introduced by the X/Open CAE Specification, Issue 4, Version 2M*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** S I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license.T I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanyingU I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endif/*** pollfd structure*/structV pollfd { int fd; short events; short revents;};/*?** Declare type nfds_t used for the number of file descriptors.*/typedef unsigned int nfds_t;/*A** The following symbolic constants may be OR'ed together to form1** the events or revents in the pollfd structure.*/Y#define POLLIN 01 /* Data other than high-priority data may be read without blocking. */;#define POLLNORM POLLIN /* Legacy - Equivalent to POLLIN */G#define POLLRDNORM 0100 /* Normal data mWay be read without blocking. */I#define POLLRDBAND 0200 /* Priority data may be read without blocking. */J#define POLLPRI 02 /* High priority data may be read without blocking. */F#define POLLOUT 04 /* Normal data may be written without blocking. */7#define POLLWRNORM POLLOUT /* Equivalent to POLLOUT. */<#define POLLWRBAND 01000 /* Priority data may be written. */@#define POLLERR 010 /* An error has occurred (revents only). */G#define POLLHUP 020 /* Device has been disconneXcted (revents only). */<#define POLLNVAL 040 /* Invalid fd member (revents only). */0#define INFTIM (-1) /* Infinite poll timeout */Cint poll(struct pollfd __fd_array[], nfds_t __nfds, int __timeout);/*&** Restore the user's pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus}#endif#endif#pragma __standard#endif /* _POLL_LOADED */ww~6ԗ#ifndef __PROCESSES_LOADED#define __PROCESSES_LO YADED 1M/******************************************************************************)** - Sub process functions**M*****************************************************************************I** I** Copyright 2004 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP Zand/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** [ I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** add\itional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {!#define __decc$unknown_params ...#else#define __decc$unknown_params#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif]/* "** Public typedefs -- 32-bit mode*/ 1#if !defined __PID_T && !defined _DECC_V4_SOURCE# define __PID_T 1 typedef __pid_t pid_t;#endif/*I** We are done defining things which must always be 32 bit pointers. IfC** the user has used /pointer_size=32 or /pointer_size=64, we will7** allow 64 bit pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/* M** DEC C V4 defined execl, execle and execlp without ^the required arg0. The2** old prototypes are retained for compatibility.*/ #ifdef _DECC_V4_SOURCE# int execl (char *__name, ...);# int execle (char *__name, ...);# int execlp (char *__name, ...);#else; int execl (const char *__path, const char *arg0, ...);; int execle (const char *__path, const char *arg0, ...);; int execlp (const char *__file, const char *arg0, ...);#endif/*J** The following functions take an array of pointers as arguments. These_7** arrays are restricted to arrays of 32 bit pointers.*/Cint execv (const char *__path, __char_ptr_const_ptr32 __argv);bint execve (const char *__path, __char_ptr_const_ptr32 __argv, __char_ptr_const_ptr32 __envp);Cint execvp (const char *__file, __char_ptr_const_ptr32 __argv);/*G** The pipe function optionally takes additional arguments when not in** standard compilation.*/#ifdef _POSIX_C_SOURCE ( int pipe (int __array_fdscptr[2]);#else- int pipe ` (int __array_fdscptr[2], ...);#endif/*** Function prototypes*/1#if defined _POSIX_EXIT && __CRTL_VER >= 70000000# if __CAN_USE_EXTERN_PREFIX# pragma __extern_prefix __save## pragma __extern_prefix "__posix_"# else&# define wait(__p1) __posix_wait(__p1)*# define system(__p1) __posix_system(__p1) # endif#endif__pid_t wait(int *__stat_loc);"int system (const char *__string);1#if defined _POSIX_EXIT && __CRTL_VER >= 70000000# if __CAN_USE_EXTERN_PREFIXa"# pragma __extern_prefix __restore # endif#endif/*6** The definition of vfork() is architecture specific*/#if defined(__ALPHA)/ __int64_ptr32 decc$$get_vfork_jmpbuf(void); # ifdef __INITIAL_POINTER_SIZE)# pragma __required_pointer_size __save)# pragma __required_pointer_size __long # endif> int LIB$GET_CURRENT_INVO_CONTEXT(__int64 *__invo_context); # ifdef __INITIAL_POINTER_SIZE,# pragma __required_pointer_size __restore # endif' int debcc$$alloc_vfork_blocks(void);7# define vfork() (decc$$alloc_vfork_blocks() >= 0 ? \@ LIB$GET_CURRENT_INVO_CONTEXT(decc$$get_vfork_jmpbuf()) : -1)#elif defined(__ia64)/ __int64_ptr32 decc$$get_vfork_jmpbuf(void);' int decc$$alloc_vfork_blocks(void);% int decc$setjmp1(__int64 *__env);7# define vfork() (decc$$alloc_vfork_blocks() >= 0 ? \0 decc$setjmp1(decc$$get_vfork_jmpbuf()) : -1)#else# ifndef _DECC_V4_SOURCE __pid_t vfork(void);# else intc vfork(void); # endif#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard #endif /* __PROCESSES_LOADED */ww6ԗ#ifndef __PWD_LOADED#define __PWD_LOADED 1/*,** Header may contain non-ANSI C extensions.*/#pragma __nostandard#include >#if __CRTL_VER >= 70000000 /* Only OpenVMS V7.0 or later */N/*************** d****************************************************************,** - Password file access functions**N******************************************************************************1** Header introduced by the ISO POSIX-1 StandardM*****************************************************************************I** I** Copyright 2004 Hewlett-Packard Development Company, L.P. I** e I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard fI** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warrantyg statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#ifdef __cplusplus extern "C" {#endif/**** Naturally align data structure members*/!#pragma __member_alignment __save#pragma __member_alignment/*h ** X/Open extensions for types*/5#if defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCE# if !defined __UID_T# define __UID_T 1 typedef __uid_t uid_t; # endif# if !defined __GID_T# define __GID_T 1 typedef __gid_t gid_t; # endif#endif#define __PASSWD_MEMBERS \ char *pw_name;\ __uid_t pw_uid;\ __gid_t pw_gid;\ char *pw_dir;\ char *pw_shell;#if __INITIAL_POINTER_SIZE# pragma __pointer_size __save#endif#iif __INITIAL_POINTER_SIZE# pragma __pointer_size 32#endif4typedef struct passwd {__PASSWD_MEMBERS} __passwd;#if __INITIAL_POINTER_SIZE typedef __passwd __passwd32;# pragma __pointer_size 648typedef struct __passwd64 {__PASSWD_MEMBERS} __passwd64;#endif#if __INITIAL_POINTER_SIZE# pragma __pointer_size 32)typedef __passwd ** __passwd_ptr32_ptr32;%typedef __passwd64 *__passwd64_ptr32;#endif!typedef __passwd *__passwd_ptr32;#if __INITIAL_POINTER_SIZE# pragma __jpointer_size 64?typedef __passwd64 *__passwd64_ptr64, **__passwd64_ptr64_ptr64;#endif.typedef __passwd_ptr32 * __passwd_ptr32_ptr64; #if __INITIAL_POINTER_SIZE == 32# pragma pointer_size __short#endifR#define __USE_64BIT_FUNCS (__CRTL_VER >= 70312000 && __INITIAL_POINTER_SIZE == 64))#if __USE_LONG_GID_T || __USE_64BIT_FUNCS # pragma __extern_prefix __save#endif#if __USE_LONG_GID_T# if __USE_64BIT_FUNCS.# pragma __extern_prefix "__long_gid___64_"# else)# prakgma __extern_prefix "__long_gid_"# endif#else# if __USE_64BIT_FUNCS## pragma __extern_prefix "__64_"# endif#endif#if __USE_64BIT_FUNCS__passwd64_ptr32#else__passwd_ptr32 #endif getpwnam(__const_char_ptr647#if !defined(_POSIX_C_SOURCE) && __CRTL_VER >= 70100000 , ...#endif );#if __USE_64BIT_FUNCS__passwd64_ptr32#else__passwd_ptr32#endif getpwuid(__uid_t);)#if __USE_LONG_GID_T || __USE_64BIT_FUNCS## pragma __extern_prefix __restlore#endif#if __USE_LONG_GID_T # pragma __extern_prefix __save'# pragma __extern_prefix "__long_gid_"#endif#if __CRTL_VER >= 70312000 # if __INITIAL_POINTER_SIZE /__passwd_ptr32 __32_getpwnam(__const_char_ptr64;# if !defined(_POSIX_C_SOURCE) && __CRTL_VER >= 70100000 , ... # endif );1__passwd64_ptr32 __64_getpwnam(__const_char_ptr64;# if !defined(_POSIX_C_SOURCE) && __CRTL_VER >= 70100000 , ... # endif );(__passwd_ptr32 __32_getpwuid(__uidm_t);(__passwd64_ptr32 __64_getpwuid(__uid_t);# endifint getpwnam_r("# if __INITIAL_POINTER_SIZE == 64U __const_char_ptr64, __passwd64_ptr64, __char_ptr64, __size_t, __passwd64_ptr64_ptr64# elseQ __const_char_ptr64, __passwd_ptr32, __char_ptr32, __size_t, __passwd_ptr32_ptr64# endif# if !defined(_POSIX_C_SOURCE)N , ... /* Optional extra argument specifies OpenVMS format for pw_dir field */# endif );int getpwuid_r(__uid_t uic, "# if __INITIAL_POINTER_SIZE == 64Cn __passwd64_ptr64, __char_ptr64, __size_t, __passwd64_ptr64_ptr64);# else? __passwd_ptr32, __char_ptr32, __size_t, __passwd_ptr32_ptr64);# endif# if __INITIAL_POINTER_SIZE # if __USE_LONG_GID_T +# pragma __extern_prefix "___long_gid" # endifbint _getpwnam_r32(__const_char_ptr64, __passwd_ptr32, __char_ptr32, __size_t, __passwd_ptr32_ptr64!# if !defined(_POSIX_C_SOURCE) , ... # endif );fint _getpwnam_r64(__const_char_ptr64, __passwd64_ptr64, __char_ptro64, __size_t, __passwd64_ptr64_ptr64!# if !defined(_POSIX_C_SOURCE) , ... # endif );Yint _getpwuid_r32(__uid_t, __passwd_ptr32, __char_ptr32, __size_t, __passwd_ptr32_ptr64);]int _getpwuid_r64(__uid_t, __passwd64_ptr64, __char_ptr64, __size_t, __passwd64_ptr64_ptr64);%# endif /* __INITIAL_POINTER_SIZE */"#endif /* __CRTL_VER > 70312000 */#if __USE_LONG_GID_T## pragma __extern_prefix __restore#endif/*M** getpwent, setpwent, & endpwent were added for OpenVMS V7.p2-6C1, and V7.3-1*/#if __CRTL_VER >= 70301000,# if !__USE_LONG_GID_T || __USE_64BIT_FUNCS# if __CAN_USE_EXTERN_PREFIX$# pragma __extern_prefix __save# if __USE_64BIT_FUNCS# if !__USE_LONG_GID_T5# pragma __extern_prefix "__short_gid___64_" # else)# pragma __extern_prefix "__64_"# endif # else# if !__USE_LONG_GID_T0# pragma __extern_prefix "__short_gid_"# endif # endif # else # q if __USE_64BIT_FUNCS# if !__USE_LONG_GID_T8# define getpwent() __short_gid___64_getpwent() # else,# define getpwent() __64_getpwent()# endif # else# if !__USE_LONG_GID_T3# define getpwent() __short_gid_getpwent()# endif # endif # endif# endif# if __USE_64BIT_FUNCS__passwd64_ptr32# else__passwd_ptr32 # endif getpwent(void);I# if __CAN_USE_EXTERN_PREFIX && (!__USE_LONG_GIrD_T || __USE_64BIT_FUNCS)%# pragma __extern_prefix __restore# endif# if !__USE_LONG_GID_T# if __CAN_USE_EXTERN_PREFIX$# pragma __extern_prefix __save,# pragma __extern_prefix "__short_gid_" # else9# define __32_getpwent() __short_gid___32_getpwent()9# define __64_getpwent() __short_gid___64_getpwent() # endif# endif6# if __INITIAL_POINTER_SIZE && __CRTL_VER >= 70312000%__passwd_ptr32 __32_getpwent(void);%__passwd64_ptr32 __64_getpwents(void);# endif2# if __CAN_USE_EXTERN_PREFIX && !__USE_LONG_GID_T%# pragma __extern_prefix __restore# endifvoid setpwent(void);void endpwent(void);##endif /* __CRTL_VER >= 70301000 */#if __INITIAL_POINTER_SIZE "# pragma __pointer_size __restore#endif$#pragma __member_alignment __restore#ifdef __cplusplus }#endif$#endif /* __CRTL_VER >= 70000000 */#pragma __standard#endif /* __PWD_LOADED */ww\7ԗ#ifndef __REENTRANCY_LOADED t#define __REENTRANCY_LOADED 1M/******************************************************************************F** - definitions needed for using DECC$SET_REENTRANCY **M******************************************************************************* Header is nonstandardM*******************************************************************************M** Copyright Digital Equipment Corporation 1993, 1997. All rights reserved.**B** Restricted Rights: Use, duplicat uion, or disclosure by the U.S.F** Government is subject to restrictions as set forth in subparagraphF** (c) (1) (ii) of DFARS 252.227-7013, or in FAR 52.227-19, or in FAR&** 52.227-14 Alt. III, as applicable.**A** This software is proprietary to and embodies the confidentialD** technology of Digital Equipment Corporation. Possession, use, orG** copying of this software and media is authorized only pursuant to aD** valid written license from Digital or an authorized sublicensor.**Nv*******************************************************************************/#pragma __nostandard#ifdef __cplusplus extern "C" {#endif/*8** Define literals used in the decc$set_reentrancy call*/#define C$C_TOLERANT 0#define C$C_AST 1#define C$C_MULTITHREAD 2#define C$C_NONE 4/*** Function prototypes*/$int decc$set_reentrancy(int __type);#ifdef __cplusplus }#endif#pragma __standard #endif /* __REENTRANCY_LOADED */www=7ԗ#ifndef __RESOLV_LOADED#define __RESOLV_LOADED 1#pragma __nostandard#include >#if __CRTL_VER >= 70000000 /* Only OpenVMS V7.0 or later */M/******************************************************************************,** - Resolver configuration file**M******************************************************************************* Header is nonstandardM******************************************************************x***********I** I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12y.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in thisz document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M************************************************************{******************/#ifdef __cplusplus extern "C" {#endif#include #include #include #include #include /*7** Set __nomember_alignment to avoid internal and tail2** padding in structures; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment/*6** Enable 64 bit pointers for the prototype when the 3** user has specified| the /pointer_size qualifier.*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endif/*** Function prototype*/&__char_ptr32 hostalias (const char *);/*B** Rest of the functions and data structures declared in this file%** currently require 32 bit pointers.*/#if __INITIAL_POINTER_SIZE#pragma __pointer_size 32#endif/*F * Revision information. This is the release date in YYYYMMDD format.E * It can change every day so the ri}ght thing to do with it is use itE * in preprocessor commands such as "#if (__RES > 19931104)". Do notJ * compare for equality; rather, use it to determine whether your resolver. * is new enough to contain a certain feature. */#define __RES 20030124/*@ * This used to be defined in res_query.c, now it's in herror.c.- * [XXX no it's not. It's in irs/irs_data.c] * It wasH * never extern'd by any *.h file before it was placed here. For threadH * aware programs, the last h_errno ~value set is stored in res->h_errno. *K * XXX: There doesn't seem to be a good reason for exposing RES_SET_H_ERRNO9 * (and __h_errno_set) to the public via .F * XXX: __h_errno_set is really part of IRS, not part of the resolver.K * If somebody wants to build and use a resolver that doesn't use IRS,0 * what do they do? Perhaps something like * #ifdef WANT_IRS@ * # define RES_SET_H_ERRNO(r,x) __h_errno_set(r,x) * #elseP * # define RES_SET_H_ERRNO(r,x) (h_errno = (r)->res_h_errno = (x)) * #endif *//#define RES_SET_H_ERRNO(r,x) __h_errno_set(r,x)!struct __res_state; /* forward */5void __h_errno_set(struct __res_state *res, int err);/* * Resolver configuration file.; * Normally not present, but may contain the address of the> * initial name server(s) to query and the domain search list. */#ifndef _PATH_RESCONF4#define _PATH_RESCONF "tcpip$etc:resolv.conf"#endifKtypedef enum { res_goahead, res_nextns, res_modified, res_done, res_error } res_sendhookact;Jtypedef res_sendhookact (*res_send_qhook) (struct sockaddr_in * const *ns, const u_char **query, int *querylen, u_char *ans, int anssiz, int *resplen);Etypedef res_sendhookact (*res_send_rhook) (const struct sockaddr *ns, const u_char *query, int querylen, u_char *ans, int anssiz, int *resplen);struct res_sym {5 int number; /* Identifying number, like T_MX */: const char * name; /* Its symbolic name, like "MX" */C const char * humanname; /* Its fun name, like "mail exchanger" */};/*2 * Global defines and variables for resolver stub. */6#define MAXNS 3 /* max # name servers we'll track */:#define MAXDFLSRCH 3 /* # default domain levels to try */7#define MAXDNSRCH 6 /* max # domains in search path */C#define LOCALDOMAINPARTS 2  /* min levels in name that is "local" */J#define RES_TIMEOUT 5 /* min. seconds between retries */F#define MAXRESOLVSORT 10 /* number of net to sort on */K#define RES_MAXNDOTS 15 /* should reflect bit field size */N#define RES_MAXRETRANS 30 /* only for resolv.conf/RES_OPTIONS */N#define RES_MAXRETRY 5 /* only for resolv.conf/RES_OPTIONS */>#define RES_DFLRETRY 2 /* Default #/tries. */H#define RE S_MAXTIME 65535 /* Infinity, in milliseconds. */struct __res_state_ext;struct __res_state {J int retrans; /* retransmission time interval */K int retry; /* number of times to retransmit */G u_long options; /* option flags - see below. */D int nscount; /* number of name servers */ struct sockaddr_inD nsaddr_list[MAXNS]; /* address of name server */H#define nsaddr nsaddr_list[0] /* for backward compatibility */@ u_short id; /* current message id */L char *dnsrch[MAXDNSRCH+1]; /* components of domain to search */I char defdname[256]; /* default domain (deprecated) */I u_long pfcode; /* RES_PRF_ flags - see below. */N unsigned ndots:4; /* threshold for initial abs. query */O unsigned nsort:4; /* number of elements in sort_list[] */ char unused[3]; struct {% struct in_addr addr;% u_int32_t mask;# } sort_list[MAXRESOLVSORT];8 res_send_qhook qhook; /* query hook */; res_send_rhook rhook; /* response hook */K int res_h_errno; /* last one set for this context */J int _vcsock; /* PRIVATE: for res_send VC i/o */@ __u_int _flags;  /* PRIVATE: see below */D __u_int _pad; /* make _u 64 bit aligned */ union {> /* On an 32-bit arch this means 512b total. */E char pad[72 - 4*sizeof (int) - 2*sizeof (void *)]; struct {8 u_int16_t nscount;I u_int16_t nstimes[MAXNS]; /* ms. */? int nssocks[MAXNS];P struct __res_state_ext *ext; /* extention for IPv6 */J /* the server we just talked to */7 struct sockaddr_in last_nsaddr; } _ext; } _u;##define last_ns _u._ext.last_nsaddr};&typedef struct __res_state *res_state;union res_sockaddr_union {$ struct sockaddr_in sin;#ifdef IN6ADDR_ANY_INIT% struct sockaddr_in6 sin6;#endif#ifdef ISC_ALIGN64E int64_t  __align64; /* 64bit alignment */#elseE int32_t __align32; /* 32bit alignment */#endif> char __space[128]; /* max size */};/*@ * Resolver flags (used to be discrete per-module statics ints). */;#define RES_F_VC 0x00000001 /* socket is TCP */A#define RES_F_CONN 0x00000002 /* socket is connected */A#define RES_F_EDNS0ERR 0x00000004 /* EDNS0 caused errors */6#define RES_F__UNUSED 0x0000 0008 /* (unused) */N#define RES_F_LASTMASK 0x000000F0 /* ordinal server of last res_nsend */M#define RES_F_LASTSHIFT 4 /* bit position of LASTMASK "flag" */M#define RES_GETLAST(res) (((res)._flags & RES_F_LASTMASK) >> RES_F_LASTSHIFT) /* res_findzonecut2() options */C#define RES_EXHAUSTIVE 0x00000001 /* always do all queries */7#define RES_IPV4ONLY 0x00000002 /* IPv4 only */7#define RES_IPV6ONLY 0x00000004 /* IPv6 only *//*B * Resolver options (keep these in synch with res_debug.c, please) */A#define RES_INIT 0x00000001 /* address initialized */B#define RES_DEBUG 0x00000002 /* print debug messages */O#define RES_AAONLY 0x00000004 /* authoritative answers only (!IMPL)*/A#define RES_USEVC 0x00000008 /* use virtual circuit */O#define RES_PRIMARY 0x00000010 /* query primary server only (!IMPL) */E#define RES_IGNTC 0x00000020 /* ignore trucation errors */?#define RES_RECURSE 0x00000040 /* recursion desired */E#define RES_DEFNAMES 0x00000080 /* use default domain name */B#define RES_STAYOPEN 0x00000100 /* Keep TCP socket open */I#define RES_DNSRCH 0x00000200 /* search up local domain tree */F#define RES_INSECURE1 0x00000400 /* type 1 security disabled */F#define RES_INSECURE2 0x00000800 /* type 2 security disabled */K#define RES_NOALIASES 0x00001000 /* shuts off HOSTALIASES feature */M#define RES_USE_INET6 0x00002000 /* use/map IPv6 in gethostbyname() */M#define RES_ROTATE 0x00004000 /* rotate ns list after each query */L#define RES_NOCHECKNAME 0x00008000 /* do not check names for sanity. */G#define RES_KEEPTSIG 0x00010000 /* do not strip TSIG records */I#define RES_BLAST 0x00020000 /* blast all recursive servers */M#define RES_NOTLDQUERY 0x00100000 /* don't unqualified name as a tld */L#define RES_USE_DNSSEC 0x00200000 /* u se DNSSEC using OK bit in OPT */D/* KAME extensions: use higher bit to avoid conflict with ISC use */7#define RES_USE_DNAME 0x10000000 /* use DNAME */E#define RES_USE_EDNS0 0x40000000 /* use EDNS0 if configured */M#define RES_NO_NIBBLE2 0x80000000 /* disable alternate nibble lookup */7#define RES_DEFAULT (RES_RECURSE | RES_DEFNAMES | \5 RES_DNSRCH | RES_NO_NIBBLE2)/** * Resolver "pfcode" values. Used by dig. */"#define RES_PRF_STATS 0x00000001"#define RES_PRF_UPDATE 0x00000002"#define RES_PRF_CLASS 0x00000004"#define RES_PRF_CMD 0x00000008"#define RES_PRF_QUES 0x00000010"#define RES_PRF_ANS 0x00000020"#define RES_PRF_AUTH 0x00000040"#define RES_PRF_ADD 0x00000080"#define RES_PRF_HEAD1 0x00000100"#define RES_PRF_HEAD2 0x00000200"#define RES_PRF_TTLID 0x00000400"#define RES_PRF_HEADX 0x00000800"#define RES_PRF_QUERY 0x00001000"#define RES_PRF_REPLY 0x00002000"#define RES_PRF_INIT  0x00004000"#define RES_PRF_TRUNC 0x00008000*/* 0x00010000 */#ifdef _REENTRANT&#ifdef __TCPIP_NO_RES_TRANSLITERATIONS-extern struct __res_state *__res_state(void);#define _res (*__res_state())#else3extern struct __res_state *TCPIP$__RES_STATE(void);##define _res (*TCPIP$__RES_STATE()),#endif /* __TCPIP_NO_RES_TRANSLITERATIONS */#else#ifndef __BIND_NOSTATICextern struct __res_state _res;#endif#endif /* _REENTRANT *//*F** The followin g functions are not defined in the DECC$SHR image, but3** instead must be resolved with the TCPIP images.**@** If the user has not defined __TCPIP_NO_RES_TRANSLITERATIONS,@** we will define these functions as their TCPIP$ replacements.*/+#if defined __TCPIP_NO_RES_TRANSLITERATIONS-extern const struct res_sym __p_class_syms[];,extern const struct res_sym __p_type_syms[];#else2extern const struct res_sym *TCPIP$P_CLASS_SYMS();1extern const struct res_sym *TCPIP$P_TYPE_SYMS(); #define res_hnok TCPIP$RES_HNOK"#define res_ownok TCPIP$RES_OWNOK$#define res_mailok TCPIP$RES_MAILOK #define res_dnok TCPIP$RES_DNOK #define sym_ston TCPIP$SYM_STON #define sym_ntos TCPIP$SYM_NTOS #define sym_ntop TCPIP$SYM_NTOP #define b64_ntop TCPIP$B64_NTOP #define b64_pton TCPIP$B64_PTON #define loc_ntoa TCPIP$LOC_NTOA #define loc_aton TCPIP$LOC_ATON$#define fp_resstat TCPIP$FP_RESSTAT#define p_query TCPIP$P_QUERY&#define dn_skipname TCPIP$DN_SKIPNAME$#define fp_resstat TCPIP$FP_RESSTAT #define fp_query TCPIP$FP_QUERY"#define fp_nquery TCPIP$FP_NQUERY#define putlong TCPIP$PUTLONG #define putshort TCPIP$PUTSHORT#define p_class TCPIP$P_CLASS#define p_time TCPIP$P_TIME#define p_type TCPIP$P_TYPE#define p_query TCPIP$P_QUERY"#define p_cdnname TCPIP$P_CDNNAME"#define p_section TCPIP$P_SECTION #define p_cdname TCPIP$P_CDNAME"#define p_fqnname TCPIP$P_FQNNAME #define p_fqname TCPIP$P_FQNAME #define p_option TCPIP$P_OPTION(#defin e p_secstodate TCPIP$P_SECSTODATE.#define dn_count_labels TCPIP$DN_COUNT_LABELS#define dn_comp TCPIP$DN_COMP"#define dn_expand TCPIP$DN_EXPAND #define res_init TCPIP$RES_INIT5#define res_init_access TCPIP$RES_INIT_ACCESS(#define res_randomid TCPIP$RES_RANDOMID"#define res_query TCPIP$RES_QUERY$#define res_search TCPIP$RES_SEARCH.#define res_querydomain TCPIP$RES_QUERYDOMAIN&#define res_mkquery TCPIP$RES_MKQUERY #define res_send TCPIP$RES_SEND.#define res_isourserver  TCPIP$RES_ISOURSERVER.#define res_nameinquery TCPIP$RES_NAMEINQUERY/#define res_queriesmatch TCPIP$RES_QUERIESMATCH"#define res_close TCPIP$RES_CLOSE$#define res_update TCPIP$RES_UPDATE(#define res_mkupdate TCPIP$RES_MKUPDATE(#define res_mkupdrec TCPIP$RES_MKUPDREC,#define res_freeupdrec TCPIP$RES_FREEUPDREC6#define res_alloc_updrec TCPIP$RES_ALLOC_UPDREC5#define res_zone_update TCPIP$RES_ZONE_UPDATE.#define __p_class_syms (TCPIP$P_CLASS_SYMS()),#define __p_type_syms (TCPIP$P_TYPE_SYMS())'#define _res_opcodes TCPIP$RES_OPCODES1#define _res_sectioncodes TCPIP$RES_SECTION_CODES#/* hostalias defined in decc rtl */-#endif /* __TCPIP_NO_RES_TRANSLITERATIONS *//*** Function prototypes*/int res_hnok (const char *);int res_ownok (const char *);int res_mailok (const char *);int res_dnok (const char *);<int sym_ston (const struct res_sym *, const char *, int *);A__const_char_ptr32 sym_ntos (const struct res_sym *, int, int *);A__co nst_char_ptr32 sym_ntop (const struct res_sym *, int, int *);7int b64_ntop (u_char const *, size_t, char *, size_t);/int b64_pton (char const *, u_char *, size_t);2int loc_aton (const char *ascii, u_char *binary);@__const_char_ptr32 loc_ntoa (const u_char *binary, char *ascii);2int dn_skipname (const u_char *, const u_char *);0void fp_resstat (struct __res_state *, FILE *);(void fp_query (const u_char *, FILE *);.void fp_nquery (const u_char *, int, FILE *);$void putlong (u_int32_t , u_char *);%void putshort (u_int16_t, u_char *);__char_ptr32 p_class (int); __char_ptr32 p_time (u_int32_t);__char_ptr32 p_type (int);void p_query (const u_char *);G__u_char_ptr32 p_cdnname (const u_char *, const u_char *, int, FILE *);A__u_char_ptr32 p_cdname (const u_char *, const u_char *, FILE *);>__u_char_ptr32 p_fqnname (const u_char *cp, const u_char *msg, int, char *, int);G__const_u_char_ptr32 p_fqname (const u_char *, const u_char *, FILE *);&__char_ptr32 p_o ption (u_long option);#__char_ptr32 p_secstodate (u_long);$int dn_count_labels (const char *);*int dn_comp (const char *, u_char *, int, u_char **, u_char **);?int dn_expand (const u_char *, const u_char *, const u_char *, char *, int);int res_init (void);__u_int res_randomid (void);7int res_query (const char *, int, int, u_char *, int);8int res_search (const char *, int, int, u_char *, int);;int res_querydomain (const char *, const char *, int, int,  u_char *, int);>int res_mkquery (int, const char *, int, int, const u_char *,) int, const u_char *, u_char *, int);3int res_send (const u_char *, int, u_char *, int);2int res_isourserver (const struct sockaddr_in *);-int res_nameinquery (const char *, int, int,) const u_char *, const u_char *);6int res_queriesmatch (const u_char *, const u_char *,* const u_char *, const u_char *);void res_close (void);1__char_ptr32 p_section (int section, int opcode);int res_update (ns_updrec *);/int res_mkupdate (ns_updrec *, u_char *, int);Gns_updrec * res_mkupdrec (int, const char *, __u_int, __u_int, u_long);#void res_freeupdrec (ns_updrec *);Ans_updrec * res_alloc_updrec (__u_int, __u_int, const char *,M __u_int, __u_int, u_long, __u_int, char *);.int res_zone_update (ns_updrec *);/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#endif /* __CRTL_VER */#pragma __standard#endif /* __RESOLV_LOADED */ww7ԗ#ifndef __RESOURCE_LOADED#define __RESOURCE_LOADED 1M/******************************************************************************;** - Declarations for resource operations**M*****************************************************************************I** Header introduced by the X/Open CAE Specification, Issue 4, Version 2M*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I**  M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/* E** For the moment, the only part implemented is the rusage structure** used by wait3.*/ /*A** All structures should be member aligned on natural boundaries*/!#pragma __member_alignment __save#pragma __member_alignment/*** Public typedefs */2#if !defined __TIME_T && !defined _DECC_V4_SOURCE# define __TIME_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __time_t time_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::time_t;#endif#endif#ifndef __TIMEVAL# define __TIMEVAL 1A# if defined _XOPEN_SOURCE_EXTENDED || !defined _DECC_V4_SOURCE struct timeval {C __time_t tv_sec; /* seconds since Jan. 1, 1970 */5 long tv_usec; /* microseconds */ };# else struct timeval {C long tv_sec; /* seconds since Jan. 1, 1970 */5 long tv_usec; /* microseconds */ }; # endif#endifstruct rusage {H struct timeval ru_utime; /* user time used */H struct timeval ru_stime; /* system time used -- not implemented */};$#pragma __member_alignment __restore#ifdef __cplusplus }#endif#pragma __standard#endif /* __RESOURCE_LOADED */ww7ԗ/*-G * Copyright (c) 2001-2007, by Cisco Systems, Inc. All rights reserved. *E * Redistribution and use in source and binary forms, with or withoutN * modification, are permitted provided that the following conditions are met: *L * a) Redistributions of source code must retain the above copyright notice,: * this list of conditions and the following disclaimer. *G * b) Redistributions in binary form must reproduce the above copyrightE *  notice, this list of conditions and the following disclaimer inM * the documentation and/or other materials provided with the distribution. *B * c) Neither the name of Cisco Systems, Inc. nor the names of itsE * contributors may be used to endorse or promote products derivedC * from this software without specific prior written permission. *F * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORSP * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,Q * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSEK * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BEF * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, ORG * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OFK * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESSJ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER INJ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)I * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF" * THE POSSIBILITY OF SUCH DAMAGE. */</* $KAME: sctp.h,v 1.18 2005/03/06 16:04:16 itojun Exp $ */#if !defined(__VMS)#include R__FBSDID("$FreeBSD: src/sys/netinet/sctp.h,v 1.26 2008/07/31 11:08:30 rrs Exp $");#endif#ifndef _NETINET_SCTP_H_#define _NETINET_SCTP_H_#include #if !defined(__VMS)+#define SCTP_PACKED __attribute__((packed))#else /* __VMS */!#pragma __member_alignment __save#pragma __nomember_alignment#define SCTP_PACKED#endif /* __VMS *//* * SCTP protocol - RFC2960. */struct sctphdr {% uint16_t src_port; /* source port */+ uint16_t dest_port; /* destination port */2 uint32_t v_tag; /* verification tag of packet */' uint32_t checksum; /* Adler32 C-Sum */ /* chunks follow... */} SCTP_PACKED;/* * SCTP Chunks */struct sctp_chunkhdr {% uint8_t chunk_type; /* chunk type */' uint8_t chunk_flags; /* chunk flags */* uint16_t chunk_length; /* chunk length */ /* optional params follow */} SCTP_PACKED;/* * SCTP chunk parameters */struct sctp_paramhdr {* uint16_t param_type; /* parameter type */. uint16_t param_length; /* parameter length */} SCTP_PACKED;/** * user socket options: socket API defined *//* * read-write options */!#define SCTP_RTOINFO 0x00000001##define SCTP_ASSOCINFO 0x00000002! #define SCTP_INITMSG 0x00000003!#define SCTP_NODELAY 0x00000004##define SCTP_AUTOCLOSE 0x00000005-#define SCTP_SET_PEER_PRIMARY_ADDR 0x00000006%#define SCTP_PRIMARY_ADDR 0x00000007)#define SCTP_ADAPTATION_LAYER 0x00000008/* same as above */'#define SCTP_ADAPTION_LAYER 0x00000008*#define SCTP_DISABLE_FRAGMENTS 0x00000009*#define SCTP_PEER_ADDR_PARAMS 0x0000000a+#define SCTP_DEFAULT_SEND_PARAM 0x0000000b2/* ancillary data/notification interest options */ #define SCTP_E VENTS 0x0000000cJ/* Without this applied we will give V4 and V6 addresses on a V6 socket */-#define SCTP_I_WANT_MAPPED_V4_ADDR 0x0000000d!#define SCTP_MAXSEG 0x0000000e2#define SCTP_DELAYED_SACK 0x0000000f2#define SCTP_FRAGMENT_INTERLEAVE 0x000000102#define SCTP_PARTIAL_DELIVERY_POINT 0x00000011/* authentication support */$#define SCTP_AUTH_CHUNK 0x00000012##define SCTP_AUTH_KEY 0x00000013$#define SCTP_HMAC_IDENT 0x00000014)#define SCTP_AUTH_ACTIVE_KEY 0x00000015)#define SCTP_AUTH_DELETE_KEY 0x00000016(#define SCTP_USE_EXT_RCVINFO 0x00000017-#define SCTP_AUTO_ASCONF 0x00000018 /* rw */+#define SCTP_MAXBURST 0x00000019 /* rw */,#define SCTP_MAX_BURST 0x00000019 /* rw *//* assoc level context */;#define SCTP_CONTEXT 0x0000001a /* rw *//* explict EOR signalling */2#define SCTP_EXPLICIT_EOR 0x0000001b;#define SCTP_REUSE_PORT 0x0000001c /* rw *//* * read-only options */ #define SCTP_STATUS 0x00000100+#define SCTP_GET_PEER_ADDR_INFO 0x00000101/* authentication support */*#define SCTP_PEER_AUTH_CHUNKS 0x00000102+#define SCTP_LOCAL_AUTH_CHUNKS 0x00000103;#define SCTP_GET_ASSOC_NUMBER 0x00000104 /* ro */;#define SCTP_GET_ASSOC_ID_LIST 0x00000105 /* ro *//*3 * user socket options: BSD implementation specific *//*I * Blocking I/O is enabled on any TCP type socket by default. For the UDPG * model if this is turned on then the socket buffer is shared for sendM * resources amongst all associations. The default for the UDP model is thatH * is SS_NBIO is set. Which means all associations have a seperate sendH * limit BUT they will NOT ever BLOCK instead you will get an error backL * EAGAIN if you try to send to much. If you want the blocking symantics youM * set this option at the cost of sharing one socket send buffer size amongstK * all associations. Peeled off sockets turn this option off and block. ButL * since both TCP and peeled off sockets have only one assoc per socket thisK * is fine. It probably does NOT make sense to set this on SS_NBIO on a TCPL * model OR peeled off UDP model, but we do allow you to do so. You just use9 * the normal syscall to toggle SS_NBIO the way you want. *M * Blocking I/O is controled by the SS_NBIO flag on the socket state so_state * field. *///* these should probably go into sockets API *//#define SCTP_RESET_STREAMS 0x00001004 /* wo */3/*  here on down are more implementation specific */(#define SCTP_SET_DEBUG_LEVEL 0x000010052#define SCTP_CLR_STAT_LOG 0x00001007/* CMT ON/OFF socket option */2#define SCTP_CMT_ON_OFF 0x000012002#define SCTP_CMT_USE_DAC 0x000012016/* JRS - Pluggable Congestion Control Socket option */'#define SCTP_PLUGGABLE_CC 0x00001202/* read only */'#define SCTP_GET_SNDBUF_USE 0x00001101%#define SCTP_GET_STAT_LOG 0x00001103$#define SCTP_PCB_STATUS  0x000011042#define SCTP_GET_NONCE_VALUES 0x00001105@/* Special hook for dynamically setting primary for all assoc's,< * this is a write only option that requires root privledge. */2#define SCTP_SET_DYNAMIC_PRIMARY 0x000020015/* VRF (virtual router feature) and multi-VRF support0 * options. VRF's provide splits within a router- * that give the views of multiple routers. A. * standard host, without VRF support, is just, * a single VRF. If VRF's are supported then.  * the transport must be VRF aware. This means4 * that every socket call coming in must be directed5 * within the endpoint to one of the VRF's it belongs/ * to. The endpoint, before binding, may select3 * the "default" VRF it is in by using a set socket* * option with SCTP_VRF_ID. This will also. * get propegated to the default VRF. Once the/ * endpoint binds an address then it CANNOT add3 * additional VRF's to become a Multi-VRF endpoint. *4 * Before BINDING additional VRF's can be added with+ * the SCTP_ADD_VRF_ID call or deleted with * SCTP_DEL_VRF_ID. *4 * Associations are ALWAYS contained inside a single; * VRF. They cannot reside in two (or more) VRF's. Incoming8 * packets, assuming the router is VRF aware, can always: * tell us what VRF they arrived on. A host not supporting= * any VRF's will find that the packets always arrived on the * single VRF that the host has. * */ #define SCTP_VRF_ID 0x00003001$#define SCTP_ADD_VRF_ID 0x00003002$#define SCTP_GET_VRF_IDS 0x000030032#define SCTP_GET_ASOC_VRF 0x000030042#define SCTP_DEL_VRF_ID 0x00003005/*+ * If you enable packet logging you can get( * a poor mans ethereal output in binary) * form. Note this is a compile option to( * the kernel, SCTP_PACKET_LOGGING, and * without it in your kernel you * will get a EOPNOTSUPP */2#define SCTP_GET_PACKET_LOG 0x00004001/*L * hidden implementation specific options these are NOT user visible  (should * move out of sctp.h) */1/* sctp_bindx() flags as hidden socket options */'#define SCTP_BINDX_ADD_ADDR 0x00008001'#define SCTP_BINDX_REM_ADDR 0x000080022/* Hidden socket option that gets the addresses */+#define SCTP_GET_PEER_ADDRESSES 0x00008003+#define SCTP_GET_LOCAL_ADDRESSES 0x00008004N/* return the total count in bytes needed to hold all local addresses bound */+#define SCTP_GET_LOCAL_ADDR_SIZE 0x00008005G/* Return the total count in bytes needed to hold the remote  address */,#define SCTP_GET_REMOTE_ADDR_SIZE 0x00008006 /* hidden option for connectx */##define SCTP_CONNECT_X 0x000080077/* hidden option for connectx_delayed, part of sendx */*#define SCTP_CONNECT_X_DELAYED 0x000080082#define SCTP_CONNECT_X_COMPLETE 0x00008009-/* hidden socket option based sctp_peeloff */2#define SCTP_PEELOFF 0x0000800a+/* the real worker for sctp_getaddrlen() */2#define SCTP_GET_ADDR_LEN 0x0000800bA/* temporary workaround for Apple listen() issue, no args used */$#define SCTP_LISTEN_FIX 0x0000800c)/* Debug things that need to be purged */+#define SCTP_SET_INITIAL_DBG_SEQ 0x00009f00;/* JRS - Supported congestion control modules for pluggable * congestion control */%/* Standard TCP Congestion Control */##define SCTP_CC_RFC2581 0x00000000//* High Speed TCP Congestion Control (Floyd) */!#define SCTP_CC_HSTCP 0x00000001/* HTCP Congestion Control */ #define SCTP_CC_HTCP 0x00000002 /* fragment interleave constants" * setting must be one of these or * EINVAL returned. */'#define SCTP_FRAG_LEVEL_0 0x00000000'#define SCTP_FRAG_LEVEL_1 0x00000001'#define SCTP_FRAG_LEVEL_2 0x00000002/* * user state values */#define SCTP_CLOSED 0x0000#define SCTP_BOUND 0x1000#define SCTP_LISTEN 0x2000 #define SCTP_COOKIE_WAIT 0x0002"#define SCTP_COOKIE_ECHOED 0x0004 #define SCTP_ESTABLISHED 0x0008"#define SCTP_SHUTDOWN_SENT 0x0010&#define SCTP_SHUTDOWN_RECEIVED 0x0020&#define SCTP_SHUTDOWN_ACK_SENT 0x0040%#define SCTP_SHUTDOWN_PENDING 0x0080/*. * SCTP operational error codes (user visible) */##define SCTP_CAUSE_NO_ERROR 0x0000(#define SCTP_CAUSE_INVALID_STREAM 0x0001'#define SCTP_CAUSE_MISSING_PARAM 0x0002'#define SCTP_CAUSE_STALE_COOKIE 0x0003&#define SCTP_CAUSE_OUT_OF_RESC 0x0004+#define SCTP_CAUSE_UNRESOLVABLE_ADDR 0x0005'#define SCTP_CAUSE_UNRECOG_CHUNK 0x0006'#define SCTP_CAUSE_INVALID_PARAM 0x0007'#define SCTP_C AUSE_UNRECOG_PARAM 0x0008'#define SCTP_CAUSE_NO_USER_DATA 0x0009,#define SCTP_CAUSE_COOKIE_IN_SHUTDOWN 0x000a+#define SCTP_CAUSE_RESTART_W_NEWADDR 0x000b,#define SCTP_CAUSE_USER_INITIATED_ABT 0x000c,#define SCTP_CAUSE_PROTOCOL_VIOLATION 0x000d/* Error causes from RFC5061 */*#define SCTP_CAUSE_DELETING_LAST_ADDR 0xa0)#define SCTP_CAUSE_RESOURCE_SHORTAGE 0xa1)#define SCTP_CAUSE_DELETING_SRC_ADDR 0xa2*#define SCTP_CAUSE_ILLEGAL_ASCONF_ACK 0xa3'#define SCTP_CAUSE_REQUEST_REFUSED 0xa4/* Error causes from RFC4895 */,#define SCTP_CAUSE_UNSUPPORTED_HMACID 0x0105/*) * error cause parameters (user visisble) */struct sctp_error_cause { uint16_t code; uint16_t length;. /* optional cause-specific info may follow */} SCTP_PACKED;"struct sctp_error_invalid_stream {D struct sctp_error_cause cause; /* code=SCTP_ERROR_INVALID_STREAM */9 uint16_t stream_id; /* stream id of the DATA in error */ uint16_t reserved;&} SCTP_PACKED;!struct sctp_error_missing_param {C struct sctp_error_cause cause; /* code=SCTP_ERROR_MISSING_PARAM */@ uint32_t num_missing_params; /* number of missing parameters */# /* uint16_t param_type's follow */%} SCTP_PACKED; struct sctp_error_stale_cookie {B struct sctp_error_cause cause; /* code=SCTP_ERROR_STALE_COOKIE */5 uint32_t stale_time; /* time in usec of staleness */$} SCTP_PACKED;#struct sctp_error_out_of_resource {F struct sctp_error_cause cause; /* code=SCTP_ERROR_OUT_OF_RESOURCES */'} SCTP_PACKED;!struct sctp_error_unresolv_addr {G struct sctp_error_cause cause; /* code=SCTP_ERROR_UNRESOLVABLE_ADDR */%} SCTP_PACKED;&struct sctp_error_unrecognized_chunk {C struct sctp_error_cause cause; /* code=SCTP_ERROR_UNRECOG_CHUNK */9 struct sctp_chunkhdr ch;/* header from chunk in error */*} SCTP_PACKED;#if defined(__VMS)$#pragma __member_alignment __restore#endif /* __VMS *//*K * Main SCTP chunk types we place these here so natd and f/w's in user land * can find them. */%/************0x00 series ***********/#define SCTP_DATA 0x00#define SCTP_INITIATION 0x01 #define SCTP_INITIATION_ACK 0x02#define SCTP_SELECTIVE_ACK 0x03##define SCTP_HEARTBEAT_REQUEST 0x04#define SCTP_HEARTBEAT_ACK 0x05##define SCTP_ABORT_ASSOCIATION 0x06#define SCTP_SHUTDOWN 0x07#define SCTP_SHUTDOWN_ACK 0x08!#define SCTP_OPERATION_ERROR 0x09#define SCTP_COOKIE_ECHO 0x0a#define SCTP_COOKIE_ACK 0x0b#define SCTP_ECN_ECHO 0x0c#define SCTP_ECN_CWR 0x0d##define SCTP_SHUTDOWN_COMPLETE 0x0e /* RFC4895 */$#define SCTP_AUTHENTICATION 0x0f%/************0x40 series ***********/%/************0x80 series ***********/ /* RFC5061 */#define SCTP_ASCONF_ACK 0x80#/* draft-ietf-stewart-pktdrpsctp */ #define SCTP_PACKET_DROPPED 0x81%/* draft-ietf-stewart-strreset-xxx */$#define SCTP_STREAM_RESET 0x82%/* RFC4820 */$#define SCTP_PAD_CHUNK 0x84%/************0xc0 series ***********/ /* RFC3758 */!#define SCTP_FORWARD_CUM_TSN 0xc0 /* RFC5061 */#define SCTP_ASCONF 0xc1&/* ABORT and SHUTDOWN COMPLETE FLAG */#define SCTP_HAD_NO_TCB 0x01/* Packet dropped flags */,#define SCTP_FROM_MIDDLE_BOX SCTP_HAD_NO_TCB#define SCTP_BADCRC 0x02"#define SCTP_PACKET_TRUNCATED 0x04C#define SCTP_SAT_NETWORK_MIN 400 /* min ms for RTT to set satellite * time */M#define SCTP_SAT_NETWORK_BURST_INCR 2 /* how many times to multiply maxburst * in sat *//* Data Chuck Specific Flags */'#define SCTP_DATA_FRAG_MASK 0x03'#define SCTP_DATA_MIDDLE_FRAG 0x00'#define SCTP_DATA_LAST_FRAG 0x01'#define SCTP_DATA_FIRST_FRAG 0x02'#define SCTP_DATA_NOT_FRAG 0x03'#define SCTP_DATA_UNORDERED 0x04'#define SCTP_DATA_SACK_IMMEDIATELY 0x08*/* ECN Nonce: SACK Chunk Specific Flags */'#define SCTP_SACK_NONCE_SUM 0x01!/* CMT DAC algorithm SACK flag */'#define SCTP_SACK_CMT_DAC 0x80/*% * PCB flags (in sctp_flags bitmask).( * Note the features and flags are meant * for use by netstat. */*#define SCTP_PCB_FLAGS_UDPTYPE 0x00000001*#define SCTP_PCB_FLAGS_TCPTYPE 0x00000002+#define SCTP_PCB_FLAGS_BOUNDALL 0x00000004+#define SCTP_PCB_FLAGS_ACCEPTING 0x00000008*#define SCTP_PCB_FLAGS_UNBOUND 0x000000102#define SCTP_PCB_FLAGS_CLOSE_IP 0x 000400002#define SCTP_PCB_FLAGS_WAS_CONNECTED 0x000800002#define SCTP_PCB_FLAGS_WAS_ABORTED 0x00100000/* TCP model support */+#define SCTP_PCB_FLAGS_CONNECTED 0x00200000,#define SCTP_PCB_FLAGS_IN_TCPPOOL 0x00400000+#define SCTP_PCB_FLAGS_DONT_WAKE 0x00800000,#define SCTP_PCB_FLAGS_WAKEOUTPUT 0x01000000+#define SCTP_PCB_FLAGS_WAKEINPUT 0x02000000+#define SCTP_PCB_FLAGS_BOUND_V6 0x04000000-#define SCTP_PCB_FLAGS_BLOCKING_IO 0x08000000-#define SCTP_PCB_FLAGS_SOCKET_GONE 0x100000000#define SCTP_PCB_FLAGS_SOCKET_ALLGONE 0x20000000/* flags to copy to new PCB */7#define SCTP_PCB_COPY_FLAGS (SCTP_PCB_FLAGS_BOUNDALL|\ SCTP_PCB_FLAGS_WAKEINPUT|\ SCTP_PCB_FLAGS_BOUND_V6)/** * PCB Features (in sctp_features bitmask) */2#define SCTP_PCB_FLAGS_EXT_RCVINFO 0x000000022#define SCTP_PCB_FLAGS_DONOT_HEARTBEAT 0x000000042#define SCTP_PCB_FLAGS_FRAG_INTERLEAVE 0x000000082#define SCTP_PCB_FLAGS_INTERLEAVE_STRMS 0x00000010+#define SCTP_PCB_FLAGS_DO_ ASCONF 0x00000020-#define SCTP_PCB_FLAGS_AUTO_ASCONF 0x000000402#define SCTP_PCB_FLAGS_ZERO_COPY_ACTIVE 0x00000080/* socket options */*#define SCTP_PCB_FLAGS_NODELAY 0x00000100+#define SCTP_PCB_FLAGS_AUTOCLOSE 0x000002000#define SCTP_PCB_FLAGS_RECVDATAIOEVNT 0x00000400/#define SCTP_PCB_FLAGS_RECVASSOCEVNT 0x00000800/#define SCTP_PCB_FLAGS_RECVPADDREVNT 0x00001000-#define SCTP_PCB_FLAGS_RECVPEERERR 0x000020002#define SCTP_PCB_FLAGS_RECVSENDFAILEVNT 0x000040002#define SCTP_PCB_FLAGS_R ECVSHUTDOWNEVNT 0x000080000#define SCTP_PCB_FLAGS_ADAPTATIONEVNT 0x00010000+#define SCTP_PCB_FLAGS_PDAPIEVNT 0x00020000+#define SCTP_PCB_FLAGS_AUTHEVNT 0x000400002#define SCTP_PCB_FLAGS_STREAM_RESETEVNT 0x00080000-#define SCTP_PCB_FLAGS_NO_FRAGMENT 0x001000002#define SCTP_PCB_FLAGS_EXPLICIT_EOR 0x004000001#define SCTP_PCB_FLAGS_NEEDS_MAPPED_V4 0x008000002#define SCTP_PCB_FLAGS_MULTIPLE_ASCONFS 0x010000002#define SCTP_PCB_FLAGS_PORTREUSE 0x02000000/*-1 * mobility_features parameters (by micchie).Note) * these features are applied against the7 * sctp_mobility_features flags.. not the sctp_features * flags. */&#define SCTP_MOBILITY_BASE 0x00000001,#define SCTP_MOBILITY_FASTHANDOFF 0x00000002-#define SCTP_MOBILITY_PRIM_DELETED 0x00000004K#define SCTP_SMALLEST_PMTU 512 /* smallest pmtu allowed when disabling PMTU * discovery */#include '/* This dictates the size of the packet' * collection buffer. This only applies' * if SCTP_PACKET_LOGGING is enabled in * your config. */"#define SCTP_PACKET_LOG_SIZE 65536:/* Maximum delays and such a user can set for options that * take ms. */1#define SCTP_MAX_SACK_DELAY 500 /* per RFC4960 */9#define SCTP_MAX_HB_INTERVAL 14400000 /* 4 hours in ms */8#define SCTP_MAX_COOKIE_LIFE 3600000 /* 1 hour in ms */</* Types of logging/KTR tracing that can be enabled via the: * sysctl net.inet.sctp.sctp_logging. You must also enable * SUBSYS tracing.8 * N ote that you must have the SCTP option in the kernel * to enable these as well. */-#define SCTP_BLK_LOGGING_ENABLE 0x00000001-#define SCTP_CWND_MONITOR_ENABLE 0x00000002-#define SCTP_CWND_LOGGING_ENABLE 0x000000040#define SCTP_EARLYFR_LOGGING_ENABLE 0x00000010/#define SCTP_FLIGHT_LOGGING_ENABLE 0x00000020,#define SCTP_FR_LOGGING_ENABLE 0x00000040-#define SCTP_LOCK_LOGGING_ENABLE 0x00000080-#define SCTP_MAP_LOGGING_ENABLE 0x00000100.#define SCTP_MBCNT_LOGGING_ENA BLE 0x00000200-#define SCTP_MBUF_LOGGING_ENABLE 0x00000400.#define SCTP_NAGLE_LOGGING_ENABLE 0x000008001#define SCTP_RECV_RWND_LOGGING_ENABLE 0x00001000/#define SCTP_RTTVAR_LOGGING_ENABLE 0x00002000-#define SCTP_SACK_LOGGING_ENABLE 0x000040001#define SCTP_SACK_RWND_LOGGING_ENABLE 0x00008000,#define SCTP_SB_LOGGING_ENABLE 0x00010000-#define SCTP_STR_LOGGING_ENABLE 0x00020000-#define SCTP_WAKE_LOGGING_ENABLE 0x00040000-#define SCTP_LOG_MAXBURST_ENABLE 0x00080000-#define SCTP_LOG_RWND_ENABLE 0x001000006#define SCTP_LOG_SACK_ARRIVALS_ENABLE 0x002000006#define SCTP_LTRACE_CHUNK_ENABLE 0x004000006#define SCTP_LTRACE_ERROR_ENABLE 0x008000006#define SCTP_LAST_PACKET_TRACING 0x010000006#define SCTP_THRESHOLD_LOGGING 0x020000006#define SCTP_LOG_AT_SEND_2_SCTP 0x040000006#define SCTP_LOG_AT_SEND_2_OUTQ 0x08000000#undef SCTP_PACKED!#endif /* !_NETINET_SCTP_H_ */w wn8ԗ/*-G * Copyright (c) 2001-2007, by Cisco Systems, Inc. All rights reserved. *E * Redistribution and use in source and binary forms, with or withoutN * modification, are permitted provided that the following conditions are met: *L * a) Redistributions of source code must retain the above copyright notice,: * this list of conditions and the following disclaimer. *G * b) Redistributions in binary form must reproduce the above copyrightE * notice, this list of c onditions and the following disclaimer inM * the documentation and/or other materials provided with the distribution. *B * c) Neither the name of Cisco Systems, Inc. nor the names of itsE * contributors may be used to endorse or promote products derivedC * from this software without specific prior written permission. *F * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORSP * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,Q * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSEK * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BEF * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, ORG * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OFK * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESSJ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER INJ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)I * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF" * THE POSSIBILITY OF SUCH DAMAGE. */@/* $KAME: sctp_uio.h,v 1.11 2005/03/06 16:04:18 itojun Exp $ */#if !defined(__VMS)#include V__FBSDID("$FreeBSD: src/sys/netinet/sctp_uio.h,v 1.33 2008/10/18 15:55:15 rrs Exp $");#endif#ifndef __sctp_uio_h__#define __sctp_uio_h__#if defined(__VMS)#ifdef __cplusplus#pragma __message __save)#pragma __message __disable(arraysizepos)#endif#endif /* __VMS */#if ! defined(_KERNEL)#if ! defined(__VMS)#include #else#include #endif /* __VMS */#endif /* _KERNEL */#include #include #include typedef uint32_t sctp_assoc_t;-/* On/Off setup for subscription to events */struct sctp_event_subscribe { uint8_t sctp_data_io_event; uint8_t sctp_association_event; uint8_t sctp_address_event;! uint8_t sctp_send_failure_event; uint8_t sctp_peer_error_event; uint8_t sctp_shutdown_event;% uint8_t sctp_partial_delivery_event;% uint8_t sctp_adaptation_layer_event;# uint8_t sctp_authentication_event;" uint8_t sctp_stream_reset_events;};/* ancillary data types */#define SCTP_INIT 0x0001#define SCTP_SNDRCV 0x0002#define SCTP_EXTRCV 0x0003/* * ancillary data structures */struct sctp_initmsg { uint32_t sinit_num_ostreams; uint32_t sinit_max_instreams; uint16_t sinit_max_attempts; uint16_t sinit_max_init_timeo;};2/* We add 96 bytes to the size of sctp_sndrcvinfo.2 * This makes the current structure 128 bytes long3 * which is nicely 64 bit aligned but also has room1 * for us to add more and keep ABI compatability.3 * For example, already we have the sctp_extrcvinfo" * when enabled which is 48 bytes. *//* * The assoc up needs a verfid4 * all sendrcvinfo's need a verfid for SENDING only. */#define SCTP_ALIGN_RESV_PAD 96$#define SCTP_ALIGN_RESV_PAD_SHORT 80struct sctp_sndrcvinfo { uint16_t sinfo_stream; uint16_t sinfo_ssn; uint16_t sinfo_flags; uint16_t sinfo_pr_policy; uint32_t sinfo_ppid; uint32_t sinfo_context; uint32_t sinfo_timetolive; uint32_t sinfo_tsn; uint32_t sinfo_cumtsn; sctp_assoc_t sinfo_assoc_id;, uint8_t __reserve_pad[SCTP_ALIGN_RESV_PAD];};struct sctp_extrcvinfo { uint16_t sinfo_stream; uint16_t sinfo_ssn; uint16_t sinfo_flags; uint16_t sinfo_pr_policy; uint32_t sinfo_ppid; uint32_t sinfo_context; uint32_t sinfo_timetolive; uint32_t sinfo_tsn; uint32_t sinfo_cumtsn; sctp_assoc_t sinfo_assoc_id; uint16_t sreinfo_next_flags; uint16_t sreinfo_next_stream; uint32_t sreinfo_next_aid; uint32_t sreinfo_next_length; uint32_t sreinfo_next_ppid;2 uint8_t __reserve_pad[SCTP_ALIGN_RESV_PAD_SHORT];};)#define SCTP_NO_NEXT_MSG 0x0000)#define SCTP_NEXT_MSG_AVAIL 0x0001)#define SCTP_NEXT_MSG_ISCOMPLETE 0x0002)#define SCTP_NEXT_MSG_IS_UNORDERED 0x0004,#define SCTP_NEXT_MSG_IS_NOTIFICATION 0x0008struct sctp_snd_all_completes { uint16_t sall_stream; uint16_t sall_flags; uint32_t sall_ppid; uint32_t sall_context; uint32_t sall_num_sent; uint32_t sall_num_failed;};5/* Flags that go into the sinfo->sinfo_flags field */9#define SCTP_EOF 0x0100/* Start shutdown procedures */6#define SCTP_ABORT 0x0200/* Send an ABORT to peer */;#define SCTP_UNORDERED 0x0400/* Message is un-ordered */A#define SCTP_ADDR_OVER 0x0800/* Override the primary-address */C#define SCTP_SENDALL 0x1000/* Send this on all associations */;#define SCTP_EOR 0x2000/* end of message signal */>#define SCTP_PR_POLICY_VALID 0x4000 /* pr sctp policy valid */2#define INVALID_SINFO_FLAG(x) (((x) & 0xffffff00 \Q & ~(SCTP_EOF | SCTP_ABORT | SCTP_UNORDERED |\< SCTP_ADDR_OVER | SCTP_SENDALL | SCTP_EOR)) != 0)/* for the endpoint */:/* The lower byte is an enumeration of PR-SCTP pol icies */8#define SCTP_PR_SCTP_TTL 0x0001/* Time based PR-SCTP */:#define SCTP_PR_SCTP_BUF 0x0002/* Buffer based PR-SCTP */M#define SCTP_PR_SCTP_RTX 0x0003/* Number of retransmissions based PR-SCTP */.#define PR_SCTP_POLICY(x) ((x) & 0xff):#define PR_SCTP_ENABLED(x) (PR_SCTP_POLICY(x) != 0)I#define PR_SCTP_TTL_ENABLED(x) (PR_SCTP_POLICY(x) == SCTP_PR_SCTP_TTL)I#define PR_SCTP_BUF_ENABLED(x) (PR_SCTP_POLICY(x) == SCTP_PR_SCTP_BUF)I#define PR_SCTP_RTX_ENABLED(x) (PR_SCTP_POLICY(x) == SCTP_PR_SCTP_RTX)H#define PR_SCTP_INVALID_POLICY(x) (PR_SCTP_POLICY(x) > SCTP_PR_SCTP_RTX) /* Stat's */struct sctp_pcbinfo { uint32_t ep_count; uint32_t asoc_count; uint32_t laddr_count; uint32_t raddr_count; uint32_t chk_count; uint32_t readq_count; uint32_t free_chunks; uint32_t stream_oque;};struct sctp_sockstat { sctp_assoc_t ss_assoc_id; uint32_t ss_total_sndbuf; uint32_t ss_total_recv_buf;};/* * notification event structures *//* * association change event */struct sctp_assoc_change { uint16_t sac_type; uint16_t sac_flags; uint32_t sac_length; uint16_t sac_state; uint16_t sac_error; uint16_t sac_outbound_streams; uint16_t sac_inbound_streams; sctp_assoc_t sac_assoc_id;};/* sac_state values */#define SCTP_COMM_UP 0x0001#define SCTP_COMM_LOST 0x0002#define SCTP_RESTART 0x0003!#define SCTP_SHUTDOWN_COMP 0x0004"#define SCTP_CANT_STR_ASSOC 0x0005/* * Address event */struct sctp_paddr_change { uint16_t spc_type; uint16_t spc_flags; uint32_t spc_length;# struct sockaddr_storage spc_aaddr; uint32_t spc_state; uint32_t spc_error; sctp_assoc_t spc_assoc_id; uint8_t spc_padding[4];};/* paddr state values */"#define SCTP_ADDR_AVAILABLE 0x0001$#define SCTP_ADDR_UNREACHABLE 0x0002 #define SCTP_ADDR_REMOVED 0x0003#define SCTP_ADDR_ADDED 0x0004"#define SCTP_ADDR_MADE_PRIM 0x0005"#define SCTP_ADDR_CONFIRMED 0x0006/*H * CAUTION: these are user exposed SCTP addr reachability states must be7 * compatible with SCTP_ADDR states in sctp_constants.h */#ifdef SCTP_ACTIVE#undef SCTP_ACTIVE#endif5#define SCTP_ACTIVE 0x0001 /* SCTP_ADDR_REACHABLE */#ifdef SCTP_INACTIVE#undef SCTP_INACTIVE#endif;#define SCTP_INACTIVE 0x0002 /* SCTP_ADDR_NOT_REACHABLE */#ifdef SCTP_UNCONFIRMED#undef SCTP_UNCONFIRMED#endif;#define SCTP_UNCONFIRMED 0x0200 /* SCTP_ADDR_UNCONFIRMED */#ifdef SCTP_NOHEARTBEAT#undef SCTP_NOHEARTBEAT#endif4#define SCTP_NOHEARTBEAT 0x0040 /* SCTP_ADDR_NOHB *//* remote error events */struct sctp_remote_error { uint16_t sre_type; uint16_t sre_flags; uint32_t sre_length; uint16_t sre_error; sctp_assoc_t sre_assoc_id; uint8_t sre_data[4];};/* data send failure event */struct sctp_send_failed { uint16_t ssf_type; uint16_t ssf_flags; uint32_t ssf_length; uint32_t ssf_error;! struct sctp_sndrcvinfo ssf_info; sctp_assoc_t ssf_assoc_id;#if !defined(__VMS) uint8_t ssf_data[0];#else uint8_t ssf_data[];#endif /* !defined(__VMS) */};'/* flag that indicates state of data */;#define SCTP_DATA_UNSENT 0x0001 /* inqueue never on wire */7#define SCTP_DATA_SENT 0x0002 /* on wire at failure *//* shutdown event */struct sctp_shutdown_event { uint16_t sse_type; uint16_t sse_flags; uint32_t sse_length; sctp_assoc_t sse_assoc_id;};'/* Adaptation layer indication stuff */struct sctp_adaptation_event { uint16_t sai_type; uint16_t sai_flags; uint32_t sai_length; uint32_t sai_adaptation_ind; sctp_assoc_t sai_assoc_id;};struct sctp_setadaptation { uint32_t ssb_adaptation_ind;};/* compatable old spelling */struct sctp_adaption_event { uint16_t sai_type; uint16_t sai_flags; uint32_t sai_length; uint32_t sai_adaption_ind; sctp_assoc_t sai_assoc_id;};struct sctp_setadaption { uint32_t ssb_adaption_ind;};/* * Partial Delivery API event */struct sctp_pdapi_event { uint16_t pdapi_type; uint16_t pdapi_flags; uint32_t pdapi_length; uint32_t pdapi_indication; uint16_t pdapi_stream; uint16_t pdapi_seq; sctp_assoc_t pdapi_assoc_id;};/* indication values */,#define SCTP_PARTIAL_DELIVERY_ABORTED 0x0001/* * authentication key event */struct sctp_authkey_event { uint16_t auth_type; uint16_t auth_flags; uint32_t auth_length; uint16_t auth_keynumber; uint16_t auth_altkeynumber; uint32_t auth_indication; sctp_assoc_t auth_assoc_id;};/* indication values */#define SCTP_AUTH_NEWKEY 0x0001/* * stream reset event */ struct sctp_stream_reset_event { uint16_t strreset_type; uint16_t strreset_flags; uint32_t strreset_length; sctp_assoc_t strreset_assoc_id;#if !defined(__VMS) uint16_t strreset_list[0];#else uint16_t strreset_list[];#endif /* !defined(__VMS) */};#/* flags in strreset_flags field */)#define SCTP_STRRESET_INBOUND_STR 0x0001)#define SCTP_STRRESET_OUTBOUND_STR 0x0002)#define SCTP_STRRESET_ALL_STREAMS 0x0004)#define SCTP_STRRESET_STREAM_LIST 0x0008)#define SCTP_STRRESET_FAILED 0x0010/* SCTP notification event */struct sctp_tlv { uint16_t sn_type; uint16_t sn_flags; uint32_t sn_length;};union sctp_notification { struct sctp_tlv sn_header;* struct sctp_assoc_change sn_assoc_change;* struct sctp_paddr_change sn_paddr_change;* struct sctp_remote_error sn_remote_error;( struct sctp_send_failed sn_send_failed;. struct sctp_shutdown_event sn_shutdown_event;2 struct sctp_adaptation_event sn_adaptation_event;" /* compatability same as above */. struct sctp_adaption_event sn_adaption_event;( struct sctp_pdapi_event sn_pdapi_event;) struct sctp_authkey_event sn_auth_event;2 struct sctp_stream_reset_event sn_strreset_event;};/* notification types */!#define SCTP_ASSOC_CHANGE 0x0001%#define SCTP_PEER_ADDR_CHANGE 0x0002!#define SCTP_REMOTE_ERROR 0x0003 #define SCTP_SEND_FAILED 0x0004##define SCTP_SHUTDOWN_EVENT 0x0005)#define SCTP_ADAPTATION_INDICATION 0x0006/* same as above */'#define SCTP_ADAPTION_INDICATION 0x0006*#define SCTP_PARTIAL_DELIVERY_EVENT 0x0007(#define SCTP_AUTHENTICATION_EVENT 0x0008'#define SCTP_STREAM_RESET_EVENT 0x0009/* * socket option structs */struct sctp_paddrparams {% struct sockaddr_storage spp_address; sctp_assoc_t spp_assoc_id; uint32_t spp_hbinterval; uint32_t spp_pathmtu; uint32_t spp_flags; uint32_t spp_ipv6_flowlabel; uint16_t spp_pathmaxrxt; uint8_t spp_ipv4_tos;};!#define SPP_HB_ENABLE 0x00000001"#define SPP_HB_DISABLE 0x00000002!#define SPP_HB_DEMAND 0x00000004##define SPP_PMTUD_ENABLE 0x00000008$#define SPP_PMTUD_DISABLE 0x00000010*#define SPP_HB_TIME_IS_ZERO 0x00000080*#define SPP_IPV6_FLOWLABEL 0x00000100*#define SPP_IPV4_TOS 0x00000200struct sctp_paddrinfo {( struct sockaddr_storage spinfo_address; sctp_assoc_t spinfo_assoc_id; int32_t spinfo_state; uint32_t spinfo_cwnd; uint32_t spinfo_srtt; uint32_t spinfo_rto; uint32_t spinfo_mtu;};struct sctp_rtoinfo { sctp_assoc_t srto_assoc_id; uint32_t srto_initial; uint32_t srto_max; uint32_t srto_min;};struct sctp_assocparams { sctp_assoc_t sasoc_assoc_id; uint32_t sasoc_peer_rwnd; uint32_t sasoc_local_rwnd; uint32_t sasoc_cookie_life; uint16_t sasoc_asocmaxrxt;) uint16_t sasoc_number_peer_destinations;};struct sctp_setprim {" struct sockaddr_storage ssp_addr; sctp_assoc_t ssp_assoc_id; uint8_t ssp_padding[4];};struct sctp_setpeerprim {# struct sockaddr_storage sspp_addr; sctp_assoc_t sspp_assoc_id; uint8_t sspp_padding[4];};struct sctp_getaddresses { sctp_assoc_t sget_assoc_id;1 /* addr is filled in for N * sockaddr_storage */ struct sockaddr addr[1];};struct sctp_setstrm_timeout { sctp_assoc_t ssto_assoc_id; uint32_t ssto_timeout; uint32_t ssto_streamid_start; uint32_t ssto_streamid_end;};struct sctp_status { sctp_assoc_t sstat_assoc_id; int32_t sstat_state; uint32_t sstat_rwnd; uint16_t sstat_unackdata; uint16_t sstat_penddata; uint16_t sstat_instrms; uint16_t sstat_outstrms;$ uint32_t sstat_fragmentation_point;% struct sctp_paddrinfo sstat_primary;};/* * AUTHENTICATION support *//* SCTP_AUTH_CHUNK */struct sctp_authchunk { uint8_t sauth_chunk;};/* SCTP_AUTH_KEY */struct sctp_authkey { sctp_assoc_t sca_assoc_id; uint16_t sca_keynumber;#if !defined(__VMS) uint8_t sca_key[0];#else uint8_t sca_key[];#endif /* !defined(__VMS) */};/* SCTP_HMAC_IDENT */struct sctp_hmacalgo {! uint32_t shmac_number_of_idents;#if !defined(__VMS) uint16_t shmac_idents[0];#else uint16_t shmac_idents[];#endif /* !defined(__VMS) */};/* AUTH hmac_id */&#define SCTP_AUTH_HMAC_ID_RSVD 0x0000?#define SCTP_AUTH_HMAC_ID_SHA1 0x0001 /* default, mandatory */6#define SCTP_AUTH_HMAC_ID_MD5 0x0002 /* deprecated */'#define SCTP_AUTH_HMAC_ID_SHA256 0x0003'#define SCTP_AUTH_HMAC_ID_SHA224 0x0004'#define SCTP_AUTH_HMAC_ID_SHA384 0x0005'#define SCTP_AUTH_HMAC_ID_SHA512 0x00061/* SCTP_AUTH_ACTIVE_KEY / SCTP_AUTH_DELETE_KEY */struct sctp_authkeyid { sctp_assoc_t scact_assoc_id; uint16_t scact_keynumber;};4/* SCTP_PEER_AUTH_CHUNKS / SCTP_LOCAL_AUTH_CHUNKS */struct sctp_authchunks { sctp_assoc_t gauth_assoc_id;#if !defined(__VMS) uint8_t gauth_chunks[0];#else uint8_t gauth_chunks[];#endif /* !defined(__VMS) */};struct sctp_assoc_value { sctp_assoc_t assoc_id; uint32_t assoc_value;};struct sctp_assoc_ids {#if !defined(__VMS) sctp_assoc_t gaids_assoc_id[0];#else sctp_assoc_t gaids_assoc_id[];#endif /* !defined(__VMS) */};struct sctp_sack_info { sctp_assoc_t sack_assoc_id; uint32_t sack_delay; uint32_t sack_freq;};struct sctp_cwnd_args {? struct sctp_nets *net; /* network to *//* FIXME: LP64 issue */( uint32_t cwnd_new_value;/* cwnd in k */) uint32_t inflight; /* flightsize in k */ uint32_t pseudo_cumack;- uint32_t cwnd_augment; /* increment to it */ uint8_t meets_pseudo_cumack; uint8_t need_new_pseudo_cumack; uint8_t cnt_in_send; uint8_t cnt_in_str;};struct sctp_blk_args {" uint32_t onsb; /* in 1k bytes */3 uint32_t sndlen; /* len of send being attempted */' uint32_t peer_rwnd; /* rwnd of peer */' uint16_t send_sent_qcnt;/* chnk cnt */% uint16_t stream_qcnt; /* chnk cnt */) uint16_t chunks_on_oque;/* chunks out */- uint16_t flight_size; /* flight size in k */};/*K * Max we can reset in one setting, note this is dictated not by the defineK * but the size of a mbuf cluster so don't change this define and think youJ * can specify more. You must do multiple resets if you want to reset more$ * than SCTP_MAX_EXPLICIT_STR_RESET. */)#define SCTP_MAX_EXPLICT_STR_RESET 1000%#define SCTP_RESET_LOCAL_RECV 0x0001%#define SCTP_RESET_LOCAL_SEND  0x0002%#define SCTP_RESET_BOTH 0x0003%#define SCTP_RESET_TSN 0x0004struct sctp_stream_reset { sctp_assoc_t strrst_assoc_id; uint16_t strrst_flags;, uint16_t strrst_num_streams; /* 0 == ALL */#if !defined(__VMS)B uint16_t strrst_list[0];/* list if strrst_num_streams is not 0 */#elseA uint16_t strrst_list[];/* list if strrst_num_streams is not 0 */#endif /* !defined(__VMS) */};struct sctp_get_nonce_values { sctp_assoc_t gn_assoc_id; uint32_t gn_peers_tag; uint32_t gn_local_tag;};/* Debugging logs */struct sctp_str_log {% void *stcb; /* FIXME: LP64 issue */ uint32_t n_tsn; uint32_t e_tsn; uint16_t n_sseq; uint16_t e_sseq; uint16_t strm;};struct sctp_sb_log {% void *stcb; /* FIXME: LP64 issue */ uint32_t so_sbcc; uint32_t stcb_sbcc; uint32_t incr;};struct sctp_fr_log { uint32_t largest_tsn; uint32_t largest_new_tsn; uint32_t tsn;};struct sctp_fr_map { uint32_t base; uint32_t cum; uint32_t high;};struct sctp_rwnd_log { uint32_t rwnd; uint32_t send_size; uint32_t overhead; uint32_t new_rwnd;};struct sctp_mbcnt_log { uint32_t total_queue_size; uint32_t size_change; uint32_t total_queue_mb_size; uint32_t mbcnt_change;};struct sctp_sack_log { uint32_t cumack; uint32_t oldcumack; uint32_t tsn; uint16_t numGaps; uint16_t numDups;};struct sctp_lock_log {% void *sock; /* FIXME: LP64 issue */$ void *inp; /* FIXME: LP64 issue */ uint8_t tcb_lock; uint8_t inp_lock; uint8_t info_lock; uint8_t sock_lock; uint8_t sockrcvbuf_lock; uint8_t socksndbuf_lock; uint8_t create_lock; uint8_t resv;};struct sctp_rto_log {$ void *net; /* FIXME: LP64 issue */ uint32_t rtt;};struct sctp_nagle_log {% void *stcb; /* FIXME: LP64 issue */ uint32_t total_flight; uint32_t total_in_queue; uint16_t count_in_queue; uint16_t count_in_flight;};struct sctp_sbwake_log {% void *stcb; /* FIXME: LP64 issue */ uint16_t send_q; uint16_t sent_q; uint16_t flight; uint16_t wake_cnt;$ uint8_t stream_qcnt; /* chnk cnt */) uint8_t chunks_on_oque; /* chunks out */ uint8_t sbflags; uint8_t sctpflags;};struct sctp_misc_info { uint32_t log1; uint32_t log2; uint32_t log3; uint32_t log4;};struct sctp_log_closing {$ void *inp; /* FIXME: LP64 issue */% void *stcb; /* FIXME: LP64 issue */ uint32_t sctp_flags; uint16_t state; int16_t loc;};struct sctp_mbuf_log {) struct mbuf *mp; /* FIXME: LP64 issue */ caddr_t ext; caddr_t data; uint16_t size; uint8_t refcnt; uint8_t mbuf_flags;};struct sctp_cwnd_log { uint64_t time_event; uint8_t from; uint8_t event_type; uint8_t resv[2]; union { struct sctp_log_closing close; struct sctp_blk_args blk; struct sctp_cwnd_args cwnd; struct sctp_str_log strlog; struct sctp_fr_log fr; struct sctp_fr_map map; struct sctp_rwnd_log rwnd; struct sctp_mbcnt_log mbcnt; struct sctp_sack_log sack; struct sctp_lock_log lock; struct sctp_rto_log rto; struct sctp_sb_log sb; struct sctp_nagle_log nagle; struct sctp_sbwake_log wake; struct sctp_mbuf_log mb; struct sctp_misc_info misc; } x;};struct sctp_cwnd_log_req {( int32_t num_in_log; /* Number in log */' int32_t num_ret; /* Number returned */* int32_t start_at; /* start at this one */' int32_t end_at; /* end at this one */#if !defined(__VMS) struct sctp_cwnd_log log[0];#else struct sctp_cwnd_log log[];#endif /* !defined(__VMS) */};struct sctp_timeval { uint32_t tv_sec; uint32_t tv_usec;};struct sctpstat {#if defined(__VMS) time_t time;N struct timeval sctps_discontinuitytime; /* sctpStats 18 (TimeStamp) */L /* fields below here must be longs - see sctp_usrreq.c: sctpstatbase() */#endif /* MIB according to RFC 3873 */9 uint32_t sctps_currestab; /* sctpStats 1 (Gauge32) */; uint32_t sctps_ac tiveestab; /* sctpStats 2 (Counter32) */ uint32_t sctps_restartestab; uint32_t sctps_collisionestab;< uint32_t sctps_passiveestab; /* sctpStats 3 (Counter32) */7 uint32_t sctps_aborted; /* sctpStats 4 (Counter32) */7 uint32_t sctps_shutdown;/* sctpStats 5 (Counter32) */< uint32_t sctps_outoftheblue; /* sctpStats 6 (Counter32) */> uint32_t sctps_checksumerrors; /* sctpStats 7 (Counter32) */@ uint32_t sctps_outcontrolchunks; /* sctpStats 8 (Counter64) */> uint32_t sctps_outorderch unks; /* sctpStats 9 (Counter64) */@ uint32_t sctps_outunorderchunks; /* sctpStats 10 (Counter64) */? uint32_t sctps_incontrolchunks; /* sctpStats 11 (Counter64) */= uint32_t sctps_inorderchunks; /* sctpStats 12 (Counter64) */? uint32_t sctps_inunorderchunks; /* sctpStats 13 (Counter64) */; uint32_t sctps_fragusrmsgs; /* sctpStats 14 (Counter64) */< uint32_t sctps_reasmusrmsgs; /* sctpStats 15 (Counter64) */: uint32_t sctps_outpackets; /* sctpStats 16 (Counter64) */9 uint32_t sctps_inpack ets; /* sctpStats 17 (Counter64) */ /* input statistics: */= uint32_t sctps_recvpackets; /* total input packets */? uint32_t sctps_recvdatagrams; /* total input datagrams */B uint32_t sctps_recvpktwithdata; /* total packets that had data */; uint32_t sctps_recvsacks; /* total input SACK chunks */9 uint32_t sctps_recvdata;/* total input DATA chunks */D uint32_t sctps_recvdupdata; /* total input duplicate DATA chunks */? uint32_t sctps_recvheartbeat; /* total input HB c hunks */B uint32_t sctps_recvheartbeatack; /* total input HB-ACK chunks */9 uint32_t sctps_recvecne;/* total input ECNE chunks */9 uint32_t sctps_recvauth;/* total input AUTH chunks */F uint32_t sctps_recvauthmissing; /* total input chunks missing AUTH */C uint32_t sctps_recvivalhmacid; /* total number of invalid HMAC ids * received */D uint32_t sctps_recvivalkeyid; /* total number of invalid secret ids * received */A uint32_t sctps_recvauthfailed; /* total numbe r of auth failed */@ uint32_t sctps_recvexpress; /* total fast path receives all one * chunk */C uint32_t sctps_recvexpressm; /* total fast path multi-part data */ /* output statistics: */= uint32_t sctps_sendpackets; /* total output packets */; uint32_t sctps_sendsacks; /* total output SACKs */9 uint32_t sctps_senddata;/* total output DATA chunks */C uint32_t sctps_sendretransdata; /* total output retransmitted DATA * chunks */C uint32_t sctps_sendfastre trans; /* total output fast retransmitted * DATA chunks */@ uint32_t sctps_sendmultfastretrans; /* total FR's that happened * more than once to same * chunk (u-del multi-fr * algo). */? uint32_t sctps_sendheartbeat; /* total output HB chunks */: uint32_t sctps_sendecne;/* total output ECNE chunks */? uint32_t sctps_sendauth;/* total output AUTH chunks FIXME */9 uint32_t sctps_senderrors; /* ip_output error counter */ /* PCKDROPREP statistics: */< u int32_t sctps_pdrpfmbox; /* Packet drop from middle box */5 uint32_t sctps_pdrpfehos; /* P-drop from end host */0 uint32_t sctps_pdrpmbda;/* P-drops with data */= uint32_t sctps_pdrpmbct;/* P-drops, non-data, non-endhost */@ uint32_t sctps_pdrpbwrpt; /* P-drop, non-endhost, bandwidth rep * only */D uint32_t sctps_pdrpcrupt; /* P-drop, not enough for chunk header */C uint32_t sctps_pdrpnedat; /* P-drop, not enough data to confirm */> uint32_t sctps_pdrppdbrk; /* P-drop, where process_ chunk_drop * said break */; uint32_t sctps_pdrptsnnf; /* P-drop, could not find TSN */C uint32_t sctps_pdrpdnfnd; /* P-drop, attempt reverse TSN lookup */B uint32_t sctps_pdrpdiwnp; /* P-drop, e-host confirms zero-rwnd */A uint32_t sctps_pdrpdizrw; /* P-drop, midbox confirms no space */= uint32_t sctps_pdrpbadd;/* P-drop, data did not match TSN */C uint32_t sctps_pdrpmark;/* P-drop, TSN's marked for Fast Retran */ /* timeouts */? uint32_t sctps_timoiterator; /* Number of iterato r timers that * fired */: uint32_t sctps_timodata;/* Number of T3 data time outs */F uint32_t sctps_timowindowprobe; /* Number of window probe (T3) timers * that fired */? uint32_t sctps_timoinit;/* Number of INIT timers that fired */? uint32_t sctps_timosack;/* Number of sack timers that fired */? uint32_t sctps_timoshutdown; /* Number of shutdown timers that * fired */A uint32_t sctps_timoheartbeat; /* Number of heartbeat timers that * fired */? uint32_t sctp s_timocookie; /* Number of times a cookie timeout * fired */B uint32_t sctps_timosecret; /* Number of times an endpoint changed * its cookie secret */C uint32_t sctps_timopathmtu; /* Number of PMTU timers that fired */F uint32_t sctps_timoshutdownack; /* Number of shutdown ack timers that * fired */> uint32_t sctps_timoshutdownguard; /* Number of shutdown guard * timers that fired */B uint32_t sctps_timostrmrst; /* Number of stream reset timers that * fired */> uint32_t sctps_timoearlyfr; /* Number of early FR timers that * fired */> uint32_t sctps_timoasconf; /* Number of times an asconf timer * fired */> uint32_t sctps_timodelprim; /* Number of times a prim_deleted * timer fired */B uint32_t sctps_timoautoclose; /* Number of times auto close timer * fired */G uint32_t sctps_timoassockill; /* Number of asoc free timers expired */D uint32_t sctps_timoinpkill; /* Number of inp free timers expired */) /* Early fast retransmission counters */ uint32_t sctps_earlyfrstart; uint32_t sctps_earlyfrstop;" uint32_t sctps_earlyfrmrkretrans; uint32_t sctps_earlyfrstpout;! uint32_t sctps_earlyfrstpidsck1;! uint32_t sctps_earlyfrstpidsck2;! uint32_t sctps_earlyfrstpidsck3;! uint32_t sctps_earlyfrstpidsck4; uint32_t sctps_earlyfrstrid; uint32_t sctps_earlyfrstrout; uint32_t sctps_earlyfrstrtmr; /* otheres */8 uint32_t sctps_hdrops; /* packet shorter than header */8 uint32_t sctps_badsum; /* checksum er ror */8 uint32_t sctps_noport; /* no endpoint for port */9 uint32_t sctps_badvtag; /* bad v-tag */8 uint32_t sctps_badsid; /* bad SID */7 uint32_t sctps_nomem; /* no memory */? uint32_t sctps_fastretransinrtt; /* number of multiple FR in a * RTT window */ uint32_t sctps_markedretrans;; uint32_t sctps_naglesent; /* nagle allowed sending */= uint32_t sctps_naglequeued; /* nagle does't allow sending */D uin t32_t sctps_maxburstqueued; /* max burst dosn't allow sending */B uint32_t sctps_ifnomemqueued; /* look ahead tells us no memory in) * interface ring buffer OR we had a& * send error and are queuing one * send. */F uint32_t sctps_windowprobed; /* total number of window probes sent */B uint32_t sctps_lowlevelerr; /* total times an output error causes. * us to clamp down on next user send. */C uint32_t sctps_lowlevelerrusr; /* total times sctp_senderrors were+ * caus ed from a user send from a user+ * invoked send not a sack response */A uint32_t sctps_datadropchklmt; /* Number of in data drops due to * chunk limit reached */D uint32_t sctps_datadroprwnd; /* Number of in data drops due to rwnd * limit reached */E uint32_t sctps_ecnereducedcwnd; /* Number of times a ECN reduced the * cwnd */? uint32_t sctps_vtagexpress; /* Used express lookup via vtag */= uint32_t sctps_vtagbogus; /* Collision in express lookup. */E uint32_t sctps_primary_randry; /* Number of times the sender ran dry" * of user data on primary */0 uint32_t sctps_cmt_randry; /* Same for above */7 uint32_t sctps_slowpath_sack; /* Sacks the slow way */B uint32_t sctps_wu_sacks_sent; /* Window Update only sacks sent */9 uint32_t sctps_sends_with_flags; /* number of sends with * sinfo_flags !=0 */C uint32_t sctps_sends_with_unord /* number of undordered sends */ ;G uint32_t sctps_sends_with_eof; /* number of sends with EOF flag set */ ? uint32_t sctps_sends_with_abort; /* number of sends with ABORT * flag set */A uint32_t sctps_protocol_drain_calls; /* number of times protocol * drain called */A uint32_t sctps_protocol_drains_done; /* number of times we did a * protocol drain */> uint32_t sctps_read_peeks; /* Number of times recv was called * with peek */> uint32_t sctps_cached_chk; /* Number of cached chunks used */F uint32_t sctps_cached_strmoq; /* Number of cached stream oq's used */D uin t32_t sctps_left_abandon; /* Number of unread message abandonded * by close */: uint32_t sctps_send_burst_avoid; /* Send burst avoidance,# * already max burst inflight * to net */F uint32_t sctps_send_cwnd_avoid; /* Send cwnd full avoidance, already$ * max burst inflight to net */E uint32_t sctps_fwdtsn_map_over; /* number of map array over-runs via * fwd-tsn's */3#if !defined(__VMS) /* moved to top of structure */= struct sctp_timeval sctps_discontinuitytime; /* sctpStats 18 * (TimeStamp) */#endif};2#define SCTP_STAT_INCR(_x) SCTP_STAT_INCR_BY(_x,1)2#define SCTP_STAT_DECR(_x) SCTP_STAT_DECR_BY(_x,1)H#define SCTP_STAT_INCR_BY(_x,_d) atomic_add_int(&SCTP_BASE_STAT(_x), _d)M#define SCTP_STAT_DECR_BY(_x,_d) atomic_subtract_int(&SCTP_BASE_STAT(_x), _d)7/* The following macros are for handling MIB values, */7#define SCTP_STAT_INCR_COUNTER32(_x) SCTP_STAT_INCR(_x)7#define SCTP_STAT_INCR_COUNTER64(_x) SCTP_STAT_INCR(_x)5#define SCTP_STAT_INCR_GAUGE32(_x) SCTP_STAT_INCR(_x)7#define SCTP_STAT_DECR_COUNTER32(_x) SCTP_STAT_DECR(_x)7#define SCTP_STAT_DECR_COUNTER64(_x) SCTP_STAT_DECR(_x)5#define SCTP_STAT_DECR_GAUGE32(_x) SCTP_STAT_DECR(_x)union sctp_sockstore {&#if defined(INET) || !defined(_KERNEL) struct sockaddr_in sin;#endif'#if defined(INET6) || !defined(_KERNEL) struct sockaddr_in6 sin6;#endif struct sockaddr sa;};struct xsctp_inpcb { uint32_t last; uint32_t flags; uint32_t features; uint32_t total_sends; uint32_t total_recvs; uint32_t total_nospaces; uint32_t fragmentation_point; uint16_t local_port; uint16_t qlen; uint16_t maxqlen;};struct xsctp_tcb {< union sctp_sockstore primary_addr; /* sctpAssocEntry 5/6 */ uint32_t last;6 uint32_t heartbeat_interval; /* sctpAssocEntry 7 */* uint32_t state; /* sctpAssocEntry 8 */. uint32_t in_streams; /* sctpAssocEntry 9 *// uint32_t out_streams; /* sctpAssocEntry 10 */1 uint32_t max_nr_retrans;/* sctpAssocEntry 11 */3 uint32_t primary_process; /* sctpAssocEntry 12 */1 uint32_t T1_expireries; /* sctpAssocEntry 13 */1 uint32_t T2_expireries; /* sctpAssocEntry 14 */6 uint32_t retransmitted_tsns; /* sctpAssocEntry 15 */ uint32_t total_sends; uint32_t total_recvs; uint32_t local_tag; uint32_t remote_tag; uint32_t initial_tsn; uint32_t highest_tsn; uint32_t cumulative_tsn; uint32_t cumulative_tsn_ack; uint32_t mtu; uint32_t peers_rwnd; uint32_t refcnt;. uint16_t  local_port; /* sctpAssocEntry 3 *// uint16_t remote_port; /* sctpAssocEntry 4 */9 struct sctp_timeval start_time; /* sctpAssocEntry 16 */A struct sctp_timeval discontinuity_time; /* sctpAssocEntry 17 */};struct xsctp_laddr {@ union sctp_sockstore address; /* sctpAssocLocalAddrEntry 1/2 */ uint32_t last;B struct sctp_timeval start_time; /* sctpAssocLocalAddrEntry 3 */};struct xsctp_raddr {? union sctp_sockstore address; /* sctpAssocLocalRemEntry 1/2 */ uint32_t last; 0 uint32_t rto; /* sctpAssocLocalRemEntry 5 */8 uint32_t max_path_rtx; /* sctpAssocLocalRemEntry 6 */0 uint32_t rtx; /* sctpAssocLocalRemEntry 7 */ uint32_t error_counter; /* */ uint32_t cwnd; /* */ uint32_t flight_size; /* */ uint32_t mtu; /* */2 uint8_t active; /* sctpAssocLocalRemEntry 3 */ uint8_t confirmed; /* */< uint8_t heartbeat_enabled; /* sctpAssocLocalRemEntry 4 */A struct sctp_timeval start_time; /* sctpAssocLocalRemEntry 8 */};##define SCTP_MAX_LOG GING_SIZE 30000<#define SCTP_TRACE_PARAMS 6 /* This number MUST be even */struct sctp_log_entry { uint64_t timestamp; uint32_t subsys; uint32_t padding;$ uint32_t params[SCTP_TRACE_PARAMS];};struct sctp_log {4 struct sctp_log_entry entry[SCTP_MAX_LOGGING_SIZE]; uint32_t index; uint32_t padding;};/* * Kernel defined for sctp_send */.#if defined(_KERNEL) || defined(__Userspace__)int$sctp_lower_sosend(struct socket *so, struct sockaddr *addr, struct  uio *uio, struct mbuf *i_pak, struct mbuf *control, int flags, int use_rcvinfo, struct sctp_sndrcvinfo *srcv ,struct thread *p);int!sctp_sorecvmsg(struct socket *so, struct uio *uio, struct mbuf **mp, struct sockaddr *from, int fromlen, int *msg_flags," struct sctp_sndrcvinfo *sinfo, int filling_sinfo);#endif/* * API system calls */4#if !(defined(_KERNEL)) && !(defined(__Userspace__))#if !defined(__VMS) __BEGIN_DECLS*int sctp_peeloff __P((int, sctp_assoc_t));7int sctp_bindx __P((int, struct sockaddr *, int, int));Kint sctp_connectx __P((int, const struct sockaddr *, int, sctp_assoc_t *));'int sctp_getaddrlen __P((sa_family_t));@int sctp_getpaddrs __P((int, sctp_assoc_t, struct sockaddr **));.void sctp_freepaddrs __P((struct sockaddr *));@int sctp_getladdrs __P((int, sctp_assoc_t, struct sockaddr **));.void sctp_freeladdrs __P((struct sockaddr *));Eint sctp_opt_info __P((int, sctp_assoc_t, int, void *, socklen_t *));ssize_t sctp_sendmsg __P((int, const void *, size_t, const struct sockaddr *,B socklen_t, uint32_t, uint32_t, uint16_t, uint32_t, uint32_t));< ssize_t sctp_send __P((int sd, const void *msg, size_t len,? const struct sctp_sndrcvinfo *sinfo, int flags));= ssize_t sctp_sendx __P((int sd, const void *msg, size_t len,3 struct sockaddr *addrs, int addrcnt,: struct sctp_sndrcvinfo *sinfo, int flags));9 ssize_t sctp_sendmsgx __P((int sd, const void *, size_t,) struct sockaddr *, int,E uint32_t, uint32_t, uint16_t, uint32_t, uint32_t));A sctp_assoc_t sctp_getassocid __P((int sd, struct sockaddr *sa));B ssize_t sctp_recvmsg __P((int, void *, size_t, struct sockaddr *,@ socklen_t *, struct sctp_sndrcvinfo *, int *)); __END_DECLS#else /* __VMS */%int sctp_peeloff (int, sctp_assoc_t);2int sctp_bindx (int, struct sockaddr *, int, int);F int sctp_connectx (int, const struct sockaddr *, int, sctp_assoc_t *);"int sctp_getaddrlen (sa_family_t);;int sctp_getpaddrs (int, sctp_assoc_t, struct sockaddr **);)void sctp_freepaddrs (struct sockaddr *);;int sctp_getladdrs (int, sctp_assoc_t, struct sockaddr **);)void sctp_freeladdrs (struct sockaddr *);@int sctp_opt_info (int, sctp_assoc_t, int, void *, socklen_t *);ssize_t sctp_sendmsg (int, const void *, size_t, const struct sockaddr *,A socklen_t, uint32_t, uint32_t,  uint16_t, uint32_t, uint32_t);8 ssize_t sctp_send (int sd, const void *msg, size_t len,> const struct sctp_sndrcvinfo *sinfo, int flags);9 ssize_t sctp_sendx (int sd, const void *msg, size_t len,3 struct sockaddr *addrs, int addrcnt,9 struct sctp_sndrcvinfo *sinfo, int flags);5 ssize_t sctp_sendmsgx (int sd, const void *, size_t,) struct sockaddr *, int,D uint32_t, uint32_t, uint16_t, uint32_t, uint32_t);< sctp_assoc_t sctp_getassocid (int sd, struct sockaddr *sa);> ssize_t sctp_recvmsg (int, void *, size_t, struct sockaddr *,? socklen_t *, struct sctp_sndrcvinfo *, int *);#ifdef __cplusplus#pragma __message __restore#endif#endif /* __VMS */#endif /* !_KERNEL */#endif /* !__sctp_uio_h__ */wwџ9ԗ#ifndef __SEM_LOADED#define __SEM_LOADEDM/******************************************************************************-** - System V semaphore system calls**M*****************************************************************************I** I** Copyright 2008 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I**  I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I**  M******************************************************************************/#pragma __nostandard #include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endif#include 1#if !defined __PID_T && !defined _DECC_V4_SOURCE# define __PID_T 1 typedef __pid_t pid_t; #endif5#if defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCE# ifndef __TIME_T# define __TIME_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __time_t time_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::time_t;#endif # endif#endif2#if !defined __SIZE_T && !defined _DECC_V4_SOURCE# define __SIZE_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __size_t size_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::size_t;#endif#endif/* Flags for `semop'. */9#define SEM_UNDO 0x1000 /* undo the operation on exit *//* Commands for `semctl'. */$#define GETPID 11 /* get sempid */$#define GETVAL 12 /* get semval */*#define GETALL 13 /* get all semval's */&#define GETNCNT 14 /* get semncnt */&#define GETZCNT 15 /* get semzcnt */$#define SETVAL 16 /* set semval */*#define SETALL 17 /* set all semval's */5/* Data structure describing a set of semaphores. */struct semid_ds{@ struct ipc_perm sem_perm; / * operation permission struct */C unsigned short int sem_nsems; /* number of semaphores in set */1 __time_t sem_otime; /* last semop() time */= __time_t sem_ctime; /* last time changed by semctl() */};5/* Anonymous structure associated with a semaphore */typedef struct {@ unsigned short semval; /* Semaphore value */O __pid_t sempid; /* Process ID of last operation. */a unsigned short semncnt; /* Number of processes waiting for semval to increase */b unsigned short semzcnt; /* Number of processes waiting for semval to become 0 */ } sem_ds;E/* Structure used for argument to `semop' to describe operations. */ struct sembuf{7 unsigned short int sem_num; /* semaphore number */1 short int sem_op; /* semaphore operation */- short int sem_flg; /* operation flag */};"/* Semaphore control operations */6int semctl(int __semid, int __semnum, int __cmd, ...);/* Get semaphore */3int semget(key_t __key, int __nsems, int __semflg);/* Operate on semaphore */?int semop(int __semid, struct sembuf *__sops, size_t __n_sops);/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __SEM_LOADED */ww9ԗ#ifndef __SEMAPHORE_LOADED#define __SEMAPHORE_LOADEDM/******************************************* ***********************************0** - POSIX semaphore system calls**M*****************************************************************************I** I** Copyright 2009 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty.  I** M******************************************************************************/#pragma __nostandard #include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endif#include #include #include /* Constants definition */ #define SEM_FAILED ((sem_t  *)-1)#define PSEM_MAX_PATHNAME 256#define PSEM_MAX_SECNAME 256#define SEM_VALUE_MAX INT_MAX./* Data structure describing a semaphores. */typedef struct {% unsigned int __unused1; // padding, char signature[24]; /* used internally */7 int sem_named_flag; /* 1 = named semaphore */8 int wait_count; /* used for unnamed semaphroes */X unsigned int sem_value; /* semaphore value (used only in case of unnamed semaphore) */F void *sem_internal_ptr; /* pointer t!o the internal semaphore struct 3 (used only in case of named semaphores) */% unsigned int __unused2; // padding}sem_t; /* Open a named semaphore */3sem_t *sem_open (const char *name, int oflag, ...); &/* Remove the name of the semaphore */"int sem_unlink (const char *name);1/* close the semaphore opened through sem_open */int sem_close (sem_t *sem);(/* Initialize the specified semaphore */7int sem_init (sem_t *sem, int pshared, unsigned value);/* Remove th"e semaphore */int sem_destroy (sem_t *sem);#/* Lock the semaphore (blocking) */int sem_wait (sem_t *sem); 1/* Lock the specified semaphore (non-blocking) */int sem_trywait (sem_t *sem);0/* Wait for semaphore (blocking with timeout) */Aint sem_timedwait (sem_t *sem, struct timespec * abs_timeout); $/* Unlock the specified semaphore */int sem_post (sem_t *sem); /* Get the semaphore value */*int sem_getvalue (sem_t *sem, int *sval); /*%** Restore the #users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard #endif /* __SEMAPHORE_LOADED */ww9ԗ#ifndef __SETJMP_LOADED#define __SETJMP_LOADED 1#ifndef __SETJMP_PROCESSED#define __SETJMP_PROCESSEDM/****************************************************************************I** I** Copyright 2$005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commerc%ial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. & The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern' "C" {!#define __decc$unknown_params ...#else#define __decc$unknown_params#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# if __CRTL_VER >= 70301000 # pragma __pointer_size 64# else # pragma __pointer_size 32 # endif#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*** Define data structures*/#if defined(__VAX) typedef int jmp_buf [15];# define __JMP_BUF_TYPE int *#else$# pragma __member_alignment __save (# pragma __member_alignmentW# if defined(__FAST_SETJMP) || defined(__UNIX_SETJMP) || defined(__FAST_POSIX_SETJMP)# if defined(__ALPHA)' typedef __int64 jmp_buf [25]; # elseI typedef __int64 jmp_buf [450]; /* same as invo block for now */ # endif# else# if defined(__ALPHA)V typedef __int64 jmp_buf [68]; /* 68 quadwords - standard invo cntxt block */ # elseX typedef __int64 jmp_buf [450]; /* 450 quadwords - standard) invo cntxt block */ # endif # endif'# pragma __member_alignment __restore## define __JMP_BUF_TYPE __int64 *#endif#ifdef __NAMESPACE_STD} /* namespace std */#endif/*I** This section is for functions and declarations which are pointer-size** dependent.*/)#if (defined(__ALPHA) || defined(__ia64))W# if defined(__FAST_SETJMP) || defined(__UNIX_SETJMP) || defined(__FAST_POSIX_SETJMP)= void decc$fast_longjmp(__int64 *__env, int __retval);'# if d*efined(__FAST_POSIX_SETJMP)T# define longjmp(env, retval) decc$fast_longjmp(env, retval ? retval : 1 ) # elseF# define longjmp(env, retval) decc$fast_longjmp(env, retval) # endif# if defined(__ALPHA), int decc$setjmp (__int64 *__env);.# define setjmp(env) decc$setjmp(env) # else1 int decc$fast_setjmp (__int64 *__env);3# define setjmp(env) decc$fast_setjmp(env) # endif# else8 void c$$es+tablish(__void_ptr32, unsigned short);# if defined(__ALPHA)(# ifdef __INITIAL_POINTER_SIZE1# pragma __required_pointer_size __save1# pragma __required_pointer_size __long# endifF int LIB$GET_CURRENT_INVO_CONTEXT(__int64 *__invo_context);(# ifdef __INITIAL_POINTER_SIZE4# pragma __required_pointer_size __restore# endifW# define setjmp(env) (c$$establish(0, 32 ),LIB$GET_CURRENT_INVO_,CONTEXT(env)) # else. int decc$setjmp1 (__int64 *__env);E# define setjmp(env) (c$$establish(0,32),decc$setjmp1(env)) # endif # endif#else int setjmp (jmp_buf __env);#endif#ifdef __NAMESPACE_STDnamespace std {#endif*void (longjmp) (jmp_buf __env, int __val);#ifdef __NAMESPACE_STD} /* namespace std */#endif#if __CRTL_VER >= 700000006# if _POSIX_C_SOURCE >= 1 || !defined _ANSI_C_SOURCE# if (defined(__ALPHA))- - typedef __int64 __sigjmp_buf[70];# elif (defined(__ia64)). typedef __int64 __sigjmp_buf[452]; # else) typedef int __sigjmp_buf[18]; # endif# if !defined _DECC_V4_SOURCE% typedef __sigjmp_buf sigjmp_buf;# endif1 void siglongjmp (__sigjmp_buf __env, int __val);6 int sigsetjmp (__sigjmp_buf __env, int __savemask);*# if (defined(__ALPHA) || defined(__ia64))< void c$$establish(__void_ptr32, unsigned short);K# de.fine sigsetjmp( p1, p2 ) ( c$$establish(0,32), (sigsetjmp)(p1,p2) )# endif # endif#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __SETJMP_PROCESSED */>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_SETJMP_NAMES # define __USING_SETJMP_NAMES using std::jmp_buf;Y# if !defined(__FAST_SETJMP/) && !defined(__UNIX_SETJMP) && !defined(__FAST_POSIX_SETJMP) using std::longjmp;# endif# endif#endif#endif /* __SETJMP_LOADED */wwe8:ԗ#ifndef __SIGINFO_LOADED#define __SIGINFO_LOADED 1M/******************************************************************************"** - Signal Handling **M*****************************************************************************I** 0I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technica1l Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to chang 2e without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************//*G** This header is provided as part of the signal.h header.3 Meaning thatI** signal.h #includes . This header should never provide any I** function prototype, structure, union or datatype that signal.h is not ** supposed to provide.*/#pragma __nostandard#include #if __CRTL_VER >= 70320000#ifdef __cplusplus extern "C" {#endif/*#** Naturally align data structures*/!#pragma __member_alignment __save#pragma __member_alignment#ifndef __UID_T# define __UID_T 1 typedef __uid_t uid_t4;#endif#ifndef __PID_T# define __PID_T 1 typedef __pid_t pid_t;#endif#ifndef __CLOCK_T# define __CLOCK_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef long int clock_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::clock_t;#endif#endifunion sigval {. int sival_int; /* integer signal value */ #if __INITIAL_POINTER_SIZE == 640 __void_ptr64 sival_ptr; /* pad to 64 bits */#else6 __void_ptr32 sival_ptr; /* pointer sig5nal value */4 __void_ptr32 _sival_fill[2];/* pad to 64 bits */#endif};/*K * Max siginfo size -- 128 bytes altogether (used to pad siginfo _sifields) */#define SI_MAX_SIZE (128)3#define SI_PAD_SIZE ((SI_MAX_SIZE/sizeof(int)) - 4)#ifndef __SIGINFO_T#define __SIGINFO_T 1typedef struct __siginfo {& int si_signo; /* signal number */% int si_errno; /* error number */# int si_code; /* signal code */ union {< int _sipad[SI_PAD_SIZE]; /* reserve space f6or new fields */ /* kill() or SIGCHLD */ struct {$ pid_t _pid; /* sender's pid */ union { /* kill() */ struct {% __uid_t _uid;/* sender's uid */ } _kill; /* SIGCHLD */ struct {' int _status;/* exitcode/signal */ clock_t _utime; clock_t _stime; } _sigchld; } _pinfo; /* POSIX.1b signals */ struct {! /* application-defined value */ union sigval _sigval; } _sigrt; } _sigproc;& /* SIGILL, SIGFPE, SIGS7EGV, SIGBUS */ struct { #if __INITIAL_POINTER_SIZE == 64? __void_ptr64 _addr; /* faulting instruction/memory ref. */#else? __void_ptr32 _addr; /* faulting instruction/memory ref. */6 __void_ptr32 _addr_fill; /* padding to 64 bits */#endif } _sigfault; /* SIGPOLL */ struct {3 long _band; /* POLL_IN, POLL_OUT, POLL_MSG */1 /* fd not currently available for SIGPOLL */$ int _fd; /* file descriptor */ } _sigpoll; } _sifields; } siginfo_t; #end 8if /* #ifndef __SIGINFO_T *//*3 * This is how users expect to access these fields. */-#define si_pid _sifields._sigproc._pid:#define si_uid _sifields._sigproc._pinfo._kill._uidA#define si_status _sifields._sigproc._pinfo._sigchld._status@#define si_utime _sifields._sigproc._pinfo._sigchld._utime@#define si_stime _sifields._sigproc._pinfo._sigchld._stime8#define si_value _sifields._sigproc._sigrt._sigvalA#define si_int _sifields._sigproc._si 9grt._sigval.sival_intA#define si_ptr _sifields._sigproc._sigrt._sigval.sival_ptr0#define si_addr _sifields._sigfault._addr/#define si_band _sifields._sigpoll._band+#define si_fd _sifields._sigpoll._fd5#define si_anonval _sifields._siganon._siganonval?#define si_anonint _sifields._siganon._siganonval.sival_int?#define si_anonptr _sifields._siganon._siganonval.sival_ptr/*  * values of si_code */?/* negative si_codes are reserved for user-g :enerated signals */3#define SI_QUEUE -1 /* signal sent by sigqueue() */B#define SI_USER 0 /* signal sent by kill, sigsend, raise, etc. */\#define SI_TIMER 0x10 /* signal generated by expiration of a timer set by timer_settime() */[#define SI_ASYNCIO 0x20 /* signal generated by completion of an asynchronous I/O request */^#define SI_MESGQ 0x40 /* signal generated by arrival of a message on an empty message queue *//* SIGILL si_codes */)#define ILL_ILLOPC 1 /* illegal opcode */*#define ;ILL_ILLOPN 2 /* illegal operand */2#define ILL_ILLADR 3 /* illegal addressing mode */'#define ILL_ILLTRP 4 /* illegal trap */,#define ILL_PRVOPC 5 /* privileged opcode */.#define ILL_PRVREG 6 /* privileged register */,#define ILL_COPROC 7 /* coprocessor error *//#define ILL_BADSTK 8 /* internal stack error */#define NSIGILL 8/* SIGFPE si_codes */1#define FPE_INTDIV 1 /* integer divide by zero */+#define FPE_INTOVF 2 /* integer overflow */8#define FPE_FLTDIV 3 /* floating point div <ide by zero */2#define FPE_FLTOVF 4 /* floating point overflow */3#define FPE_FLTUND 5 /* floating point underflow */8#define FPE_FLTRES 6 /* floating point inexact result */;#define FPE_FLTINV 7 /* invalid floating point operation */1#define FPE_FLTSUB 8 /* subscript out of range */#define NSIGFPE 8/* SIGSEGV si_codes */8#define SEGV_MAPERR 1 /* address not mapped to object */A#define SEGV_ACCERR 2 /* invalid permissions for mapped object */*#define SEGV_STKOVF 3 /* stack overflow =*/#define NSIGSEGV 3/* SIGBUS si_codes */4#define BUS_ADRALN 1 /* invalid address alignment */8#define BUS_ADRERR 2 /* non-existent physical address */9#define BUS_OBJERR 3 /* object specific hardware error */#define NSIGBUS 3/* SIGTRAP si_codes */-#define TRAP_BRKPT 1 /* process breakpoint */-#define TRAP_TRACE 2 /* process trace trap */#define NSIGTRAP 2/* SIGCHLD si_codes */+#define CLD_EXITED 1 /* child has exited */+#define CLD_KILLED 2 /* child was killed */6#def >ine CLD_DUMPED 3 /* child terminated abnormally */4#define CLD_TRAPPED 4 /* traced child has trapped */-#define CLD_STOPPED 5 /* child has stopped */9#define CLD_CONTINUED 6 /* stopped child has continued */B#define CLD_SIGEXITING 7 /* child is exiting via a fatal signal */#define NSIGCLD 7/* SIGPOLL si_codes */-#define POLL_IN 1 /* data input available */1#define POLL_OUT 2 /* output buffers available */0#define POLL_MSG 3 /* input message available */"#define POLL_ERR 4 /* I/O er?ror */6#define POLL_PRI 5 /* high priority input available */,#define POLL_HUP 6 /* device disconnected */#define NSIGPOLL 6#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#endif /* if __CRTL_VER */#pragma __standard#endif /* __SIGINFO_LOADED */ww:ԗ#ifndef __SIGNAL_LOADED#define __SIGNAL_LOADED 1#ifndef __SIGNAL_PROCESSED#define __SIGNAL_PROCESSEDM/**************************************************************************** @**!** - Signal Handling **M*****************************************************************************,** Header introduced by the ANSI C StandardM*****************************************************************************I** I** Copyright 2008 Hewlett-Packard Development Company, L.P. I** I** Confidential computer sAoftware. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. IB** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be constrCued as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include =#if defined _XOPEN_SOURCE_EXTENDED || !defined _ANSI_C_SOURCE+# include /* for siginfo_t */#endif#ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_DSIZE # pragma __pointer_size __save#endif/*#** Naturally align data structures*/!#pragma __member_alignment __save#pragma __member_alignment/* ** Private definitions*/ /*G** __sighnd_t is a pointer to function, where the function is declared** void f(int code);**C** __bsd_sighnd_t is a pointer to function, where the function is:** void f(int code, ... );** B** __vms_handler is a pointer to function, where the function is:.** unsigned int f(void *sigaErr, void *mecharr)**F** These definition are private to this header and subject to change.*/ #if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif#typedef void (*__sighnd64_t) (int);,typedef void (*__bsd_sighnd64_t)(int, ... );#if __INITIAL_POINTER_SIZE# pragma __pointer_size 32#endif!typedef void (*__sighnd_t) (int);*typedef void (*__bsd_sighnd_t)(int, ... );Jtypedef unsigned int (*__vms_handler) ( void *__sigarr, void *__mecharr );#if __CRTL_VER >= 70F000000# ifndef ____SIGSET_T# define ____SIGSET_T 1: typedef struct {unsigned int _set[2];} __sigset_t; # endif#endif# define _SIG_MIN 1#if __CRTL_VER >= 70000000# define _SIG_MAX 64#elif __CRTL_VER >= 60200000# define _SIG_MAX 17#else# define _SIG_MAX 15# endif/*3** ANSI C Public data definitions and declarations*/%#define SIG_ERR ((__sighnd_t)(-1))"#define SIG_DFL ((__sighnd_t)0)"#define SIG_IGN ((__sighnd_t)1)#ifdefG __NAMESPACE_STDnamespace std {#endiftypedef int sig_atomic_t;#ifdef __NAMESPACE_STD} /* namespace std */#endif/* 8** ISO POSIX-1 public data definitions and declarations*/ 6#if defined _POSIX_C_SOURCE || !defined _ANSI_C_SOURCE# if __CRTL_VER >= 70000000# define SIG_UNBLOCK 0# define SIG_BLOCK 1# define SIG_SETMASK 2# define SA_NOCLDSTOP 0x20K# if !defined __SIGSET_T && !defined _SIGSET_T_ && !defined _DECC_V4_SOURCE# define __SIGSET_T 1D# H define _SIGSET_T_ 1 /* uses this symbol */! typedef __sigset_t sigset_t;# endif# pragma __extern_model __save,# pragma __extern_model __common_block noshrC static const __sigset_t _SIG_EMPTY_SET = {0x00000000, 0x00000000},- _SIG_FULL_SET = {0xFFFFFFFF, 0xFFFFFFFF};!# pragma __extern_model __restoreK#define __SIGACT64 (__CRTL_VER >= 80200000 && __INITIAL_POINTER_SIZE == 64)/*J** Members for sigaction struct. This is complex due to "sigaction" bei IngF** both a struct and a function, can't use typedef to map general type ** onto 32/64 bit specific type.*/#define __SIGACTION32_MEMBERS \E __sighnd_t sa_handler; /* Signal-catching function or macro */ \D __sigset_t sa_mask; /* Set of signals to be blocked */ \) int sa_flags; /* Special flags */#define __SIGACTION64_MEMBERS \G __sighnd64_t sa_handler; /* Signal-catching function or macro */ \D __sigset_t sa_mask; /* Set of signals to be blocked J*/ \) int sa_flags; /* Special flags */4#if __CRTL_VER >= 80200000 && __INITIAL_POINTER_SIZE struct __sigaction32 { __SIGACTION32_MEMBERS }; struct __sigaction64 { __SIGACTION64_MEMBERS };#endif#if __SIGACT64 struct sigaction { __SIGACTION64_MEMBERS };#else struct sigaction { __SIGACTION32_MEMBERS };#endif # endif#endif/* 1** XPG4 public data definitions and declarations*/ 4#if defined _XOPEN_SOURCE || !Kdefined _ANSI_C_SOURCE4# if !defined __PID_T && !defined _DECC_V4_SOURCE# define __PID_T 1 typedef __pid_t pid_t; # endif#endif/* 4** XPG4 V2 public data definitions and declarations*/ =#if defined _XOPEN_SOURCE_EXTENDED || !defined _ANSI_C_SOURCE struct sigstack {) char *ss_sp; /* signal stack pointer */% int ss_onstack; /* current status */ };# if __CRTL_VER >= 70000000# define SA_ONSTACK 0x01# define SA_RESETHAND 0x02# define SA_NODEFER 0xL08 # endif#endif/* @** DEC C extensions -- public data definitions and declarations*/ #ifndef _ANSI_C_SOURCE struct sigvec {- void (*sv_handler)(); /* handler address */2 int sv_mask; /* mask of signals to be blocked */5 int sv_onstack; /* flag to indicate signal stack */ }; struct sigcontext {4 int sc_onstack; /* signal stack flag to restore */+ int sc_mask; /* signal mask to restore */+ int sc_sp; /* stack pointerto restore */# int M sc_pc; /* pc to return to */" int sc_ps; /* psl to restore */ };#endif/* P** The following signals are defined by the ANSI C standard (ISO/IEC 9899:1990)*/ ?#define SIGABRT 6 /* Abnormal termination signal */B#define SIGFPE 8 /* Erroneous arithmetic operation */J#define SIGILL 4 /* Detection of an invalid hardware instr. */@#define SIGINT 2 /* Interactive attention signal */;#define SIGSEGV 11 /* segmentation violati Non */@#define SIGTERM 15 /* External termination signal *//* J** The following signals are defined by ISO POSIX-1 (ISO/IEC 9945-1:1990)*/ 6#if defined _POSIX_C_SOURCE || !defined _ANSI_C_SOURCE6# define SIGALRM 14 /* Timeout signal */K# define SIGHUP 1 /* Hangup detected on controlling terminal */@# define SIGKILL 9 /* External termination signal */E# define SIGPIPE 13 /* Write on a pipe with no readers */C# defi One SIGQUIT 3 /* Interactive termination signal */# if __CRTL_VER >= 60200000># define SIGUSR1 16 /* Application-defined signal 1 */># define SIGUSR2 17 /* Application-defined signal 2 */ # endif# if __CRTL_VER >= 70000000D# define SIGCHLD 20 /* Child process terminated or stopped */6# define SIGCONT 21 /* Continue if stopped */9# define SIGSTOP 22 /* Job control stop signal */9# define SIGTSTP 23 /* Interactive stop signal P */D# define SIGTTIN 24 /* Terminal read by background process */E# define SIGTTOU 25 /* Terminal write by background process */ # endif# if __CRTL_VER >= 703000009# define SIGWINCH 28 /* Window size changed */ # endif#endif/* ** Defined by XPG4 V2*/ =#if defined _XOPEN_SOURCE_EXTENDED || !defined _ANSI_C_SOURCEE# define SIGTRAP 5 /* TBIT trace trap or BPT instruction */@# define SIGSYS 12 /* Bad arguments to system caQll */#endif/* ** DEC C Extensions*/ #ifndef _ANSI_C_SOURCEG# define SIGIOT 6 /* Obsolete name - 6 reused as SIGABRT */B# define SIGEMT 7 /* Opcode reserved to customer */G# define SIGBUS 10 /* invalid access to memory objects */# if __CRTL_VER >= 70000000C# define SIGSPARE18 18 /* Reserved for future expansions */C# define SIGSPARE19 19 /* Reserved for future expansions */D# define SIGDEBUG 26 /* PermanenRtly reserved to Digital */C# define SIGSPARE27 27 /* Reserved for future expansions */C# define SIGSPARE28 28 /* Reserved for future expansions */C# define SIGSPARE29 29 /* Reserved for future expansions */C# define SIGSPARE30 30 /* Reserved for future expansions */C# define SIGSPARE31 31 /* Reserved for future expansions */C# define SIGSPARE32 32 /* Reserved for future expansions */D# define SIGRTMIN 33 /* First realtime signal (1S003.1b) */C# define SIGRTMAX 64 /* Last realtime signal (1003.1b) */ # endif# define NSIG _SIG_MAX# define BADSIG SIG_ERRC# define ILL_RESAD_FAULT 0x0 /* reserved addressing mode fault */C# define ILL_PRIVIN_FAULT 0x1 /* privilidged instruction fault */;# define ILL_RESOP_FAULT 0x2 /* reserved operand fault */# define FPE_INTOVF_TRAP 0x1# define FPE_INTDIV_TRAP 0x2# define FPE_FLTOVF_TRAP 0x3# define FPE_FLTDIV_TRAP 0x4# define FPE_FTLTUND_TRAP 0x5# define FPE_DECOVF_TRAP 0x6# ifdef __VAX# define FPE_SUBRNG_TRAP 0x7# else# define FPE_INXRES_TRAP 0x7 # endif# define FPE_FLTOVF_FAULT 0x8# define FPE_FLTDIV_FAULT 0x9 # define FPE_FLTUND_FAULT 0x0a# ifndef __VAX# define FPE_INVOPR_TRAP 0x0b# define FPE_DECDIV_TRAP 0x0c# define FPE_DECINV_TRAP 0x0d# define FPE_SUBRNG_TRAP 0x0e# define FPE_SUBRNG1_TRAP 0x0f# define FPE_SUBRNG2_TRAP 0x10# define FPE_SUBRNG3_TRAP 0x11# define FPE_SUUBRNG4_TRAP 0x12# define FPE_SUBRNG5_TRAP 0x13# define FPE_SUBRNG6_TRAP 0x14# define FPE_SUBRNG7_TRAP 0x15# ifdef __ia64# define FPE_FLTINE_TRAP 0x16# define FPE_FLTINV_TRAP 0x17# define FPE_FLTINV_FAULT 0x18## define FPE_FLTDENORMAL_FAULT 0x19 # endif # endif#endif/*** Enable 64 bit pointers*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*** Function prototypes (ANSI).*/#if V__SIGACT64 # pragma __extern_prefix __save!# pragma __extern_prefix "__64_"## define __SIGRETTYP __sighnd64_t #else # define __SIGRETTYP __sighnd_t#endif9 __SIGRETTYP signal( int __sig, __sighnd64_t __func );#if __SIGACT64## pragma __extern_prefix __restore# undef __SIGRETTYP#endif /* > ** In strict ANSI mode, raise has a signal parameter. As7 ** a DEC C extension, it accepts a subcode as well. */ #ifndef _ANSI_C_SOURCEC int raise (int __sWig, ...); /* 2nd parameter is the subcode */#else int raise (int __sig);#endif#ifdef __NAMESPACE_STD} /* namespace std */#endif/* ** ISO POSIX-1 signal handling*/ 6#if defined _POSIX_C_SOURCE || !defined _ANSI_C_SOURCE# if defined(_POSIX_EXIT)# if __USE_LONG_GID_T## pragma __extern_prefix __save0# pragma __extern_prefix "__posix_long_gid_"## elif __CRTL_VER >= 70000000 # if __CAN_USE_EXTERN_PREFIX'# pragma __extern_prefXix __save+# pragma __extern_prefix "__posix_" # else8# define kill(__p1,__p2) __posix_kill(__p1,__p2) # endif# endif # endif% int kill (__pid_t __pid, int __sig);# if defined(_POSIX_EXIT)# if __USE_LONG_GID_T&# pragma __extern_prefix __restore## elif __CRTL_VER >= 70000000 # if __CAN_USE_EXTERN_PREFIX*# pragma __extern_prefix __restore # endif# endif # endif# if __CRTL_VER >= 70000000/ int sigaddsYet (__sigset_t * __set, int __sig);/ int sigdelset (__sigset_t * __set, int __sig);7 int sigismember (const __sigset_t * __set, int __sig);# if __SIGACT64## pragma __extern_prefix __save$# pragma __extern_prefix "__64_"# endif9 int sigaction(int __sig, const struct sigaction* __act,  struct sigaction* __oact);# if __SIGACT64&# pragma __extern_prefix __restore# endif5#if __CRTL_VER >= 80200000 && __INITIAL_POINTER_SIZE T int __64_sigaction(int, Zconst struct __sigaction64 *, struct __sigaction64 *);T int __32_sigaction(int, const struct __sigaction32 *, struct __sigaction32 *);0 __sighnd64_t __64_signal(int, __sighnd64_t);/ __sighnd_t __32_signal(int, __sighnd64_t);9 __bsd_sighnd64_t __64_ssignal(int, __bsd_sighnd64_t);7 __bsd_sighnd_t __32_ssignal(int, __bsd_sighnd64_t);#endif7 int sigprocmask (int __how, const __sigset_t * __set,  __sigset_t * __oset);% int sigpending (__sigset_t * __set);+ int sig[suspend (const __sigset_t * __set);X# if __cplusplus && !__NO_MACROS && !(defined(__ia64) && (__INITIAL_POINTER_SIZE == 32))1 inline int sigemptyset (__sigset_t *__set) { *__set =_SIG_EMPTY_SET; return 0; }0 inline int sigfillset (__sigset_t *__set) { *__set =_SIG_FULL_SET; return 0; }# else* int sigemptyset (__sigset_t * __set);* int sigfillset (__sigset_t * __set);# if !__NO_MACROSB# define sigemptyset(set) (*(__sigset_t*)(set)=_SIG_E\MPTY_SET, 0)@# define sigfillset(set) (*(__sigset_t*)(set)=_SIG_FULL_SET, 0) # endif# endif # endif#endif/* ** XPG4 V2 function prototypes*/ >#if defined _XOPEN_SOURCE_EXTENDED || !defined _ANSI_C_SOURCE int sigpause (int __mask);A int sigstack (struct sigstack *__ss, struct sigstack *__oss);#endif/*** DEC C extensions*/#ifndef _ANSI_C_SOURCE# if __SIGACT64!# pragma __extern_prefix __save"# pragma __extern_prefix "__64_")# defi]ne __SSIGRETTYP __bsd_sighnd64_t # else&# define __SSIGRETTYP __bsd_sighnd_t# endif@ __SSIGRETTYP ssignal (int __sig, __bsd_sighnd64_t __action);# if __SIGACT64$# pragma __extern_prefix __restore# undef __SSIGRETTYP# endifJ int sigvec (int __sigveca, struct sigvec *__sv, struct sigvec *__osv); int sigblock (int __mask); int sigsetmask (int __mask);! int gsignal (int __sig, ...);, void VAXC$ESTABLISH (__vms_handler __f); void VAXC$CRTL_INIT ^(void);# ifndef __cplusplus void DECC$CRTL_INIT (void); # endif# ifndef __VAX8 void c$$establish(__void_ptr32, unsigned short);C# define VAXC$CRTL_INIT() ( c$$establish(0,32), (VAXC$CRTL_INIT)())# ifndef __cplusplusF# define DECC$CRTL_INIT() (c$$establish(0,32), (DECC$CRTL_INIT)())# endif # endif /* E ** ISO POSIX-1 defines alarm, sleep as being in . ForE ** compatibility with DEC C V4, the old prototypes are supported. */ _# ifndef _DECC_V4_SOURCE/ unsigned int alarm (unsigned int __seconds);1 unsigned int sleep (unsigned __seconds); # else , int alarm (unsigned int __seconds);( int sleep (unsigned __seconds); # endif /* / ** ISO POSIX-1 defines pause in  */  int pause (void); /* @ ** XPG4 V2 removed sigmask from signal.h in a corrigenda to ** that specification. */ # if __CRTL_VER >= 70000000 int sigmas`k (int __sig);## define sigmask(m) (1L << ((m)-1)) # endif#endif>#if defined _XOPEN_SOURCE_EXTENDED || !defined _ANSI_C_SOURCE/*** XPG5 extentions*/# if __CRTL_VER >= 703200009# if (!defined __TIMESPEC && !defined _TIMESPEC_T_)# define __TIMESPEC struct timespec {% unsigned long tv_sec; /* seconds */! long tv_nsec; /* nanoseconds */ };# endif2 int sigwait(const __sigset_t *__set, int *__sig);= int sigwaitinfo(const __sigset_t *__set, asiginfo_t *__info);` int sigtimedwait(const __sigset_t *__set, siginfo_t *__info, const struct timespec *__timeout); int sighold(int __sig); int sigrelse(int __sig); int sigignore(int __sig); # endif#endif5#if __CRTL_VER >= 80400000 && !defined _ANSI_C_SOURCER unsigned int decc$find_signal_value(unsigned int __cond_value, int *__subcode_p);F unsigned int decc$find_condition_value(int __sig_num, int __subcode);#endif/* ** Restore pointer size context*/#if __INITIAL_PObINTER_SIZE## pragma __pointer_size __restore#endif$#pragma __member_alignment __restore#ifdef __cplusplus }#endif#pragma __standard#endif /* __SIGNAL_PROCESSED */>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_SIGNAL_NAMES # define __USING_SIGNAL_NAMES using std::raise; using std::sig_atomic_t; using std::signal;# endif#endif#endif /* __SIGNAL_LOADED */wwC;ԗ#ifndef __SOCKET_LOADED c#define __SOCKET_LOADED 1M/********************************************************************************* - TCP/IP socket definitions**M*****************************************************************************I** Header introduced by the X/Open CAE Specification, Issue 4, Version 2M*****************************************************************************I** I** Copyright 2005 Hewlett-Packdard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Iteems are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties ffor HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M*******************************************************************************?** Copyright (c) 1982 Regents of the University of California.A** All rights reserved. The Begrkeley software License Agreement:** specifies the terms and conditions for redistribution.**%** socket.h 6.6 (Berkeley) 6/8/85**N*******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#include #include #if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/* E** Strict XPG4 V2 compliance hrequires the BSD 4.4 socket interfaces,4** which is only available on OpenVMS V7.0 or later*/ V#if defined _XOPEN_SOURCE_EXTENDED && !defined _SOCKADDR_LEN && __CRTL_VER >= 70000000# define _SOCKADDR_LEN 1#endif/*I** The OpenVMS V7.0 release added a second implementation of the socket F** functions which is compatible with BSD 4.4. Define a local to be C** used throughout the remaining header file which reflects which !** implementation is being used.**I** An applicatiion program enables this support by defining _SOCKADDR_LEN(** prior to including this header file.*/#ifdef _SOCKADDR_LEN# if (__CRTL_VER < 70000000)H# error " BSD 4.4 Socket package not available before OpenVMS V7.0"# undef _SOCKADDR_LEN # endif#endif/*7** Set __nomember_alignment to avoid internal and tail2** padding in structures; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragmja __nomember_alignment/*!** Public typedefs (32-bit mode)*/O#if !defined(__CADDR_T) && !defined(CADDR_T) && !defined _XOPEN_SOURCE_EXTENDED# define __CADDR_T 1!# ifndef __HIDE_FORBIDDEN_NAMES# define CADDR_T 1 # endif typedef __caddr_t caddr_t;#endif2#if !defined __SIZE_T && !defined _DECC_V4_SOURCE# define __SIZE_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __size_t size_t;#ifdef __NAMESPACE_STD} /* namespace std */ usinkg std::size_t;#endif#endif3#if !defined __SSIZE_T && !defined _DECC_V4_SOURCE# define __SSIZE_T 1 typedef __ssize_t ssize_t;#endif2#if !defined __TIME_T && !defined _DECC_V4_SOURCE# define __TIME_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __time_t time_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::time_t;#endif#endif /* F** is a header defined by XPG4 V2. That specificationE** puts struclt timeval, the FD* macros and select in . A** We define select here for compatibility with DEC C V4, unless#** the program is in XPG4 V2 mode. */ 9#if !defined __TIMEVAL && !defined _XOPEN_SOURCE_EXTENDED# define __TIMEVAL 1# if !defined _DECC_V4_SOURCE struct timeval {D __time_t tv_sec; /* seconds since Jan. 1, 1970 */6 long tv_usec; /* microseconds */ };# else struct timeval {D lon mg tv_sec; /* seconds since Jan. 1, 1970 */6 long tv_usec; /* microseconds */ }; # endif#endif> /* FD_SETSIZE may be defined by the user. It is normally > ** equal to the maximum number of descriptors supported byC ** the system. Here it is set to the minimum maximum supportedA ** by the system. In order to accomodate programs which use D ** a larger number of open files with select, increase this sizeF ** within a program nby providing a larger definition of FD_SETSIZE. ** before including or  */T#if !defined __FD_SET && !defined _XOPEN_SOURCE_EXTENDED && !defined _DECC_V4_SOURCE# define __FD_SET 1# ifndef FD_SETSIZE"# define FD_SETSIZE 1024 # endif typedef long fd_mask;C# define NBBY 8 /* bits per byte */C# define NFDBITS (sizeof(fd_mask) * NBBY) /* bits per mask */Z# define FD_SET(__n, __p) ((__p)->fds_bits[(__ on)/NFDBITS] |= (1 << ((__n) % NFDBITS)))[# define FD_CLR(__n, __p) ((__p)->fds_bits[(__n)/NFDBITS] &= ~(1 << ((__n) % NFDBITS)))Y# define FD_ISSET(__n, __p) ((__p)->fds_bits[(__n)/NFDBITS] & (1 << ((__n) % NFDBITS))):# define __howmany(__x, __y) (((__x)+((__y)-1))/(__y))S typedef struct fd_set { /* descriptor set */ 8 fd_mask fds_bits[__howmany(FD_SETSIZE, NFDBITS)]; } fd_set; # if !defined(__VAX)&# if __INITIAL_POINTER_pSIZE == 64"# pragma __pointer_size 64 # endif8 void *__MEMSET(void *__s, int __c, __size_t __n);=# define FD_ZERO(__p) __MEMSET((__p), 0, sizeof(*(__p)))&# if __INITIAL_POINTER_SIZE == 64"# pragma __pointer_size 32 # endif# elseF void _MOVC5(unsigned short __srclen, const char *__src, char __fill, / unsigned short __destlen, char *__dest, ...);D# define FD_ZERO(__p) _MOVC5(0, 0, 0, sizeof(*(__p)), (char *)(__p)) # endif#endif/*6q** Define non-standard BSD socket compatible typedefs*/A#if !defined __SOCKET_TYPEDEFS && !defined _XOPEN_SOURCE_EXTENDED# define __SOCKET_TYPEDEFS 1" typedef unsigned char u_char;# typedef unsigned short u_short;" typedef unsigned long u_long;#endif/*** Defined XPG4 typedefs*/6#if !defined __SA_FAMILY_T && !defined _DECC_V4_SOURCE# define __SA_FAMILY_T& typedef __sa_family_t sa_family_t;#endif/*D * Definitions related to sockets: types, address famirlies, options. *//* * Types */*#define SOCK_STREAM 1 /* stream socket */+#define SOCK_DGRAM 2 /* datagram socket */0#define SOCK_RAW 3 /* raw-protocol interface */4#define SOCK_RDM 4 /* reliably-delivered message */7#define SOCK_SEQPACKET 5 /* sequenced packet stream *//* * Option flags per-socket. */?#define SO_DEBUG 0x0001 /* turn on debugging info recording */;#define SO_ACCEPTCONN 0x0002 /* socket has had listen() */<#define SO_REUSEADDR 0x0004 /* allow loca sl address reuse */9#define SO_KEEPALIVE 0x0008 /* keep connections alive */?#define SO_DONTROUTE 0x0010 /* just use interface addresses */C#define SO_BROADCAST 0x0020 /* permit sending of broadcast msgs */B#define SO_USELOOPBACK 0x0040 /* bypass hardware when possible */?#define SO_LINGER 0x0080 /* linger on close if data present */B#define SO_OOBINLINE 0x0100 /* leave received OOB data in line */B#define SO_REUSEPORT 0x0200 /* allow local addr and port reuse */J#define SO_OPTIONS_V tMS SO_DEBUG+SO_ACCEPTCONN+SO_REUSEADDR+SO_KEEPALIVE+ \B SO_DONTROUTE+SO_BROADCAST+SO_USELOOPBACK+ \: SO_LINGER+SO_OOBINLINE+SO_REUSEPORT #if SEC_BASE #if SEC_NETL#define SO_EXPANDED_RIGHTS 0x1016 /* return expanded rights on recv */C#define SO_DEFAULT_ATTR 0x1017 /* set def. socket attr. */B#define SO_RCV_ATTR 0x1018 /* set socket rcv mask. */M#define SO_AUTHENTICATION 0x1019 /* set socket authentication data. */uH#define SO_ACCESS_ERROR 0x1020 /* record security violation. */P#define SO_SEC_ATTRIBUTES 0x1021 /* get sec. attrs. for last byte read */P#define SO_REMOTE_KEY 0x1022 /* get auth. data for remote process. */O#define SO_NEW_ATTRS_ONLY 0x1023 /* Only return attrs if they change. */P#define SO_SET_TNET_TCB 0x1024 /* Set/reset ALLOWNETACCESS on socket.*/P#define SO_GET_TNET_TCB 0x1025 /* Return ALLOWNETACC. flag on socket.*/#elseF#define SO_E vXPANDED_RIGHTS 0x0400 /* return expanded rights on recv */#endif /*SEC_NET*/#endifI#define SO_PAIRABLE 0x0800 /* pairable socket unix domain */8#define SO_UMC 0x01000 /* umc socket */K#define SO_RESVPORT 0x100000 /* process wants a reserved port *//*. * Additional options, not kept in so_options. */0#define SO_SNDBUF 0x1001 /* send buffer size */3#define SO_RCVBUF 0x1002 /* receive buffer size */5#define SO_SNDLOWAT 0x1003 /* send low-wa wter mark */8#define SO_RCVLOWAT 0x1004 /* receive low-water mark */.#define SO_SNDTIMEO 0x1005 /* send timeout */1#define SO_RCVTIMEO 0x1006 /* receive timeout */9#define SO_ERROR 0x1007 /* get error status and clear */.#define SO_TYPE 0x1008 /* get socket type */<#define SO_SHARE 0x1009 /* ovms Share between processes */ <#define SO_CCL 0x100a /* ovms Carriage Control socket */ 4#define SO_STATE 0x100b /* get socket state bits */9#define SO_FAMILY 0x100c /* get socket address xfamily*/ <#define SO_XSE 0x100d /* _XOPEN_SOURCE_EXTENDED socket */ /*"** Full duplex code socket option*/D#define SO_FULL_DUPLEX_CLOSE 0x2000 /* full duplex close option *//*;** Linger Structure: Used for manipulating linger options.**;** This structure specifies the setting or resetting of the9** socket opt for the time interval that the socket will 7** linger for data. linger is supported only by STREAM** type sockets.*/struct linger {L int l_onoff; y /* Linger option; 1 sets linger and 0 resets linger. */D int l_linger; /* Number of seconds to linger; defaulted to' ** 120 seconds. */};/*A** Level number for (get/set)sockopt() to apply to socket itself.*/9#define SOL_SOCKET 0xffff /* options for socket level *//*** Address families.*/&#define AF_UNSPEC 0 /* unspecified */8#define AF_UNIX 1 /* local to host (pipes, portals) */6#defin ze AF_INET 2 /* internetwork: UDP, TCP, etc. */1#define AF_IMPLINK 3 /* arpanet imp addresses */0#define AF_PUP 4 /* pup protocols: e.g. BSP */-#define AF_CHAOS 5 /* mit CHAOS protocols */*#define AF_NS 6 /* XEROX NS protocols */&#define AF_ISO 7 /* ISO protocols */#define AF_OSI AF_ISO9#define AF_ECMA 8 /* european computer manufacturers */-#define AF_DATAKIT 9 /* datakit protocols */4#define AF_CCITT 10 /* CCITT protocols, X.25 etc */!#define AF_SNA 11 /* IBM SNA */"{#define AF_DECnet 12 /* DECnet */8#define AF_DLI 13 /* DEC Direct data link interface */#define AF_LAT 14 /* LAT */,#define AF_HYLINK 15 /* NSC Hyperchannel */)#define AF_APPLETALK 16 /* Apple Talk */4#define AF_ROUTE 17 /* Internal Routing Protocol *//#define AF_LINK 18 /* Link layer interface */#ifdef _XOPEN_SOURCE_EXTENDEDB#define _pseudo_AF_XTP 19 /* eXpress Transfer Protocol (no AF) */#elseA#define pseudo_AF_XTP 19 /* eXpress Transfer Protocol (no AF) */#endif |2#define AF_NETMAN 20 /* DNA Network Management */&#define AF_X25 21 /* X25 protocol *//#define AF_CTF 22 /* Common Trace Facility */5#define AF_WAN 23 /* Wide Area Network protocols */<#define AF_USER 24 /* Wild card (user defined) protocol */R#define AF_LAST 25 /* Local Area System Transport protocol */B#define AF_INET6 26 /* IPV6: UDP, TCP, etc. */<#define AF_AAL 27 /* Native AAL ATM */B#define AF_KEY 28 } /* IPSEC key management */P#define AF_MAX 35 /* leave some space for future growth */I#define SHUT_RD 0 /* Disables further receive operations */F#define SHUT_WR 1 /* Disables further send operations */R#define SHUT_RDWR 2 /* Disables further send and receive operations */0/* definitions for sockaddr_storage structure */H#define _SS_MAXSIZE 128 /* Implementation specific max size. Set toE ~ * be large enough to take a sockaddr_un. */&#define _SS_ALIGNSIZE (sizeof (long))/*>** sockaddr structure used by kernel to store most addresses.*/#ifdef _SOCKADDR_LEN /* ** BSD 4.4 sockaddr */ struct sockaddr {> unsigned char sa_len; /* total length */? __sa_family_t sa_family; /* address family */P char sa_data[14]; /* up to 14 bytes of direct address */ };&# if !defined _XOPEN_SOURCE_EXTENDED /*) ** BSD 4.3 sockaddr (for compatibility) */ struct osockaddr {7 unsigned short sa_family; /* address family */I char sa_data[14]; /* up to 14 bytes of direct address */ }; # endifW#define _SS_PAD1SIZE (_SS_ALIGNSIZE - (sizeof (unsigned char) + sizeof(__sa_family_t)));#define _SS_PAD2SIZE (_SS_MAXSIZE - ( 2 * _SS_ALIGNSIZE))struct sockaddr_storage {D unsigned char ss_len; /* address length */D __sa_family_t ss_family; /* address family */#define __ss_len ss_len!#define __ss_family ss_familyM char __ss_pad1[_SS_PAD1SIZE]; /* pad to allignment field */P unsigned long __ss_align; /* force structure allignment */I char __ss_pad2[_SS_PAD2SIZE]; /* pad to desired size */};#else /* ** BSD 4.3 sockaddr */ struct sockaddr {> unsigned short sa_family; /* address family */P char sa_data[14]; /* up to 14 bytes of direct address */ };>#define _SS_PAD1SIZE (_SS_ALIGNSIZE - sizeof (unsigned short));#define _SS_PAD2SIZE (_SS_MAXSIZE - ( 2 * _SS_ALIGNSIZE))struct sockaddr_storage {D unsigned short ss_family; /* address family 4.3 BSD */!#define __ss_family ss_familyM char __ss_pad1[_SS_PAD1SIZE]; /* pad to allignment field */P unsigned long __ss_align;  /* force structure allignment */I char __ss_pad2[_SS_PAD2SIZE]; /* pad to desired size */};#endif##if !defined _XOPEN_SOURCE_EXTENDED /*L ** Structure used by kernel to pass protocol information in raw sockets */ struct sockproto {+ u_short sp_family; /* address family */+ u_short sp_protocol; /* protocol */ }; /*; ** Protocol families, same as address families for now */#define PF_UNSPEC AF_UNSPEC#define PF_UNIX AF_UNIX#define PF_INET AF_INET#define PF_IMPLINK AF_IMPLINK#define PF_PUP AF_PUP#define PF_CHAOS AF_CHAOS#define PF_NS AF_NS#define PF_ISO AF_ISO#define PF_OSI AF_ISO#define PF_ECMA AF_ECMA#define PF_DATAKIT AF_DATAKIT#define PF_CCITT AF_CCITT#define PF_SNA AF_SNA#define PF_DECnet AF_DECnet#define PF_DLI AF_DLI#define PF_LAT AF_LAT#define PF_HYLINK AF_HYLINK!#define PF_APPLETALK AF_APPLETALK#define PF_ROUTE AF_ROUTE#define PF_LINK AF_LINK#ifdef _XOPEN_SOURCE_EXTENDEDD#define PF_XTP _pseudo_AF_XTP /* really just proto family, no AF */#elseC#define PF_XTP pseudo_AF_XTP /* really just proto family, no AF */#endif#define PF_NETMAN AF_NETMAN#define PF_X25 AF_X25#define PF_CTF AF_CTF#define PF_WAN AF_WAN#define PF_USER AF_USER#define PF_LAST AF_LAST #define PF_INET6 AF_INET6#define PF_AAL AF_AAL#define PF_KEY AF_KEY#define PF_MAX AF_MAX/*. * Maximum queue length specifiable by listen. */#define SOMAXCONN 1024#endif/*** */##if !defined _XOPEN_SOURCE_EXTENDED#define MSG_MAXIOVLEN 16#endifF#define MSG_OOB 0x1 /* process out-of-band data */F#define MSG_PEEK 0x2 /* peek at incoming message */F#define MSG_DONTROUTE 0x4 /* send without using routing tables */F#define MSG_EOR 0x8 /* data completes record */F#define MSG_TRUNC 0x10 /* dat a discarded before delivery */F#define MSG_CTRUNC 0x20 /* control data lost before delivery */F#define MSG_WIRE 0x40 /* toggle socket wire flag (send only)*/F#define MSG_WAITALL 0x80 /* wait for full request or error */)/* MSG_AIO must not be set by the user */E#define MSG_AIO 0x2000 /* Asynchronous IO request */"/* Following used within kernel */6#define MSG_NONBLOCK 0x4000 /* nonblocking request */4#define MSG_COMPAT 0x8000 /* 4.3-format s ockaddr */P#define MSG_SENDFILE 0x10000 /* from sendfile; bypass space checks */##if !defined _XOPEN_SOURCE_EXTENDEDI# define MSG_DONTWAIT 0x40 /* this message should be nonblocking */I# define MSG_DONTROUTE 0x4 /* send without using routing tables */#endif /*F** Header for ancillary data objects in msg_control buffer. Used forC** additional information with/about a datagram not expressible byB** flags. The format is a sequence of message elements headed by** cmsghdr structures.*/#ifdef _XOPEN_SOURCE_EXTENDED/*<** The CMSG_NXTHDR macro uses the _ALIGN macro and therefore;** the assumption exists that we are longword base aligned.F** Consequently, the cmsghdr struct must have longword base alignment.*/'#pragma __nomember_alignment __longword struct cmsghdr {N __size_t cmsg_len; /* data byte count, including hdr.. */K int cmsg_level;  /* originating protocol, valuesM ** will be legal values for levelP ** arg to getsockopt(),setsockopt().. */F int cmsg_type; /* protocol-specific type.. */+ /* followed by u_char cmsg_data[]; */ };#endif#ifdef _XOPEN_SOURCE_EXTENDED struct __Ocmsghdr {#else struct cmsghdr {#endifP unsigned int cmsg_len; /* data byte count, including hdr */P int cmsg_level; /* originating protocol; see above*/H int cmsg_type; /* protocol-specific type */+ /* followed by u_char cmsg_data[]; */ };/*"** Restore default base alignment.*/#pragma __nomember_alignment/*N** Macro for checking and aligning a pointer to the machines native word size.*/#define _ALIGN(p) \:  (void *)((__caddr_t)(p) + sizeof(void *) - 1UL - \J ((unsigned int)((__caddr_t)(p) + sizeof(void *) - 1UL) % \ sizeof(void *)))=/* given pointer to struct cmsghdr, return pointer to data */H#define CMSG_DATA(cmsg) ((unsigned char *)(cmsg) + _CMSG_LEN(0))D/* given length of data, return space required for cmsghdr and data,< * plus any padding needed to satisfy alignment requirements */N#define _CMSG_SPACE(length) ((unsigned long)_ALIGN(sizeof(stru ct cmsghdr)) + \> (unsigned long)_ALIGN(length))H/* given length of data, return value to store in cmsg_len field, takingE * into account any padding needed to satisfy alignment requirements. */J#define _CMSG_LEN(length) ((unsigned long)_ALIGN(sizeof(struct cmsghdr)) \) + length)</* given pointer to struct cmsghdr, return length of data */A#define _CMSG_DATALEN(cmsg) ((cmsg)->cmsg_len - _CMSG_LEN(0))E/* given pointer  to struct msghdr, return pointer to first cmsghdr */#define CMSG_FIRSTHDR(mhdr) \0 ( (mhdr)->msg_controllen >= _CMSG_LEN(0) ? \/ (struct cmsghdr *)(mhdr)->msg_control : \ (struct cmsghdr *)__NULL )P/* given pointer to struct msghdr and cmsghdr, return pointer to next cmsghdr */!#define CMSG_NXTHDR(mhdr, cmsg) \3 ( ((cmsg) == __NULL) ? CMSG_FIRSTHDR(mhdr) : \P ( ((__caddr_t)(cmsg) + _CMSG_SPACE(_CMSG_DATALEN(cmsg)) + _CMSG_LEN(0)) > \I ((__caddr_t)(mhdr)->msg_control + (mhdr)->msg_controllen) ? \# (struct cmsghdr *)__NULL : \R (struct cmsghdr *)((__caddr_t)(cmsg) + _CMSG_SPACE(_CMSG_DATALEN(cmsg)) )))/*)** "Socket"-level control message types:*/J#define SCM_RIGHTS 0x01 /* access rights (array of int) */#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64/*** 64-bit Msghdr Structure**=** This structure specifies the message buffer parameter for @** recvmsg and sendmsg calls. It allows y ou to specify an arrayC** of scatter/gather buffers. Recvmsg scatters the data to several@** user receive buffers. Sendmsg gathers data from several user(** transmit buffers before transmitting.** */#ifdef _SOCKADDR_LEN!# ifdef _XOPEN_SOURCE_EXTENDED struct __msghdr64 {M __void_ptr64 msg_name; /* The address of the destina-R ** tion socket, if the socket isQ  ** connected. If no address isP ** required, this field can beA ** set to NULL.4 */K __size_t msg_namelen; /* Len of msg_name field.4 */K struct __iovec64 *msg_iov; /* scatter/gather array.4  */K int msg_iovlen; /* # elements in msg_iov.4 */J __void_ptr64 msg_control; /* Ancillary data consistingQ ** of a sequence of pairs, eachM ** consisting of a cmsghdr Q ** structure followed by a dataP  ** array. The data array con-M ** tains the ancillary dataN ** message, and the cmsghdr R ** struct contains info allowingO ** applications to parse the : ** data.4 */O __size_t  msg_controllen; /* Ancillary data buffer len.4 */O int msg_flags; /* Flags on received message.2 */ }; # else struct __msghdr64 {Q __char_ptr64 msg_name; /* The address of the destina-P ** tion socket, if the socket isO  ** connected. If no address isN ** required, this field can be? ** set to NULL.2 */K unsigned int msg_namelen; /* Len of msg_name field.2 */H struct __iovec64 *msg_iov; /* scatter/gather array.2 */I  unsigned int msg_iovlen; /* # elements in msg_iov.2 */J __char_ptr64 msg_control; /* Ancillary data, see above.2 */M unsigned int msg_controllen; /* Ancillary data buffer len.2 */M int msg_flags; /* Flags on received message.2 */ }; # endif#else /* ** BSD 4.3 message header */ struct __msghdr64 {@ __char_ptr64 msg_name; /* The address of the destina-J ** tion socket, if the socket isI ** connected. If no address isH ** required, this field can be9 ** set to NULL.,  */C int msg_namelen; /* Len of msg_name field., */B struct __iovec64 *msg_iov; /* Scatter/Gather array., */C int msg_iovlen; /* # elements in msg_iov., */G __char_ptr64 msg_accrights; /* Points to a buffer containingM ** access rights sent with message., */M int msg_accrightslen;/* Len of the msg_accrights buffer., */ };#endif* typedef struct msghdr *__msghdr_ptr64;6 typedef const struct msghdr *__const_msghdr_ptr64;0 typedef struct __msghdr64 *__msghdr64_ptr64;< typedef const struct __msghdr64 *__const_msghdr64_ptr64;# pragma __pointer_size 32/*** 32-bit Msghdr Structure**<** This structure specifies th e message buffer parameter for@** recvmsg and sendmsg calls. It allows you to specify an arrayC** of scatter/gather buffers. Recvmsg scatters the data to several@** user receive buffers. Sendmsg gathers data from several user(** transmit buffers before transmitting.***/#ifdef _SOCKADDR_LEN!# ifdef _XOPEN_SOURCE_EXTENDED struct __msghdr32 {O __void_ptr32 *msg_name; /* The address of the destina-Q ** tion socket, if the socket isP ** connected. If no address isO ** required, this field can be@ ** set to NULL.3 */J __size_t msg_namelen; /* Len of msg_name field.3 */I struct __iovec32 *msg_iov; /* scatter/gather array.3 */J int msg_iovlen; /* # elements in msg_iov.3 */M __void_ptr32 msg_control; /* Ancillary data consistingP ** of a sequence of pairs, eachK ** consisting of a cmsghdrP ** structure followed by a dataO ** array. The data array con-L ** tains the ancillary dataL ** message, and the cmsghdrQ ** struct contains info allowingM ** applications to parse the9 ** data.3  */N __size_t msg_controllen; /* Ancillary data buffer len.3 */N int msg_flags; /* Flags on received message.3 */ }; # else struct __msghdr32 {P __char_ptr32 msg_name; /* The address of the destina-R ** tion socket, if the socket isQ ** connected. If no address isP ** required, this field can beA ** set to NULL.4 */K unsigned int msg_namelen; /* Len of msg_name field.4 */J struct __iovec32 *msg_iov; /* scatter/gather arra y.4 */K unsigned int msg_iovlen; /* # elements in msg_iov.4 */O __char_ptr32 msg_control; /* Ancillary data, see above.4 */O unsigned int msg_controllen; /* Ancillary data buffer len.4 */O int msg_flags; /* Flags on received message.4 */ }; # endif#else /* ** BSD 4.3 message header */ struct __msghdr32 {H __char_ptr32 msg_name; /* The address of the destina-J ** tion socket, if the socket isI ** connected. If no address isH ** required, this field can be9  ** set to NULL., */C int msg_namelen; /* Len of msg_name field., */B struct __iovec32 *msg_iov; /* Scatter/Gather array., */C int msg_iovlen; /* # elements in msg_iov., */J __char_ptr32 msg_accrights; /* Points to a buffer containingM ** access rights sent with message., */N int msg_accrightslen; /* Len of the msg_accrights buffer.- */ };#endif* typedef struct msghdr *__msghdr_ptr32;0 typedef struct __msghdr32 *__msghdr32_ptr32;0 typedef struct __msghdr64 *__msghdr64_ptr32;< typedef const struct __msghdr32 *__const_msghdr32_ptr32;##endif /* __INITIAL_POINTER_SIZE *//*** Msghdr Structure**=** This structure specifies the message buffer parameter for @** recvmsg and sendmsg calls. It allows you to specify an arrayC** of scatter/gather buffers. Recvmsg scatters the data to several@** user receive buffers. Sendmsg gathers data from several user(** transmit buffers before transmitting.** */#ifdef _SOCKADDR_LEN!# ifdef _XOPEN_SOURCE_EXTENDED struct msghdr {N void *msg_name; /* The address of the destina-P ** tion socket, if the socket isO ** connected. If no address isN ** required, this field can be? ** set to NULL.2 */I __size_t msg_namelen; /* Len of msg_name field.2  */H struct iovec *msg_iov; /* scatter/gather array.2 */I int msg_iovlen; /* # elements in msg_iov.2 */L void *msg_control; /* Ancillary data consistingO ** of a sequence of pairs, eachK ** consisting of a cmsghdr O ** structure followed by a dataN ** array. The data array con-K ** tains the ancillary dataL ** message, and the cmsghdr P ** struct contains info allowingM ** applications to parse the 8  ** data.2 */M __size_t msg_controllen; /* Ancillary data buffer len.2 */M int msg_flags; /* Flags on received message.2 */ }; # endif!# ifdef _XOPEN_SOURCE_EXTENDED struct __Omsghdr { # else struct msghdr { # endifK  char *msg_name; /* The address of the destina-P ** tion socket, if the socket isO ** connected. If no address isN ** required, this field can be? ** set to NULL.2 */I unsigned int msg_namelen; /* Len of msg_name f ield.2 */!# ifdef _XOPEN_SOURCE_EXTENDEDH struct __Oiovec *msg_iov; /* scatter/gather array.2 */ # elseH struct iovec *msg_iov; /* scatter/gather array.2 */ # endifI unsigned int msg_iovlen; /* # elements in msg_iov.2 */J  char *msg_control; /* Ancillary data, see above.2 */M unsigned int msg_controllen; /* Ancillary data buffer len.2 */M int msg_flags; /* Flags on received message.2 */ };'# if !defined _XOPEN_SOURCE_EXTENDED /*6 ** BSD 4.3 message header (for compatibil ity) */ struct omsghdr {C char *msg_name; /* The address of the destina-K ** tion socket, if the socket isJ ** connected. If no address isI ** required, this field can be: ** set to NULL.- */D int msg_namelen; /* Len of m sg_name field.- */C struct iovec *msg_iov; /* scatter/gather array.- */K int msg_iovlen; /* # elements in msg_iov. - */E char *msg_accrights; /* Points to a buffer containingN ** access rights sent with message.- */N int msg_accrightslen;/* Len of the msg_accrights buffer.- */ }; # endif#else /* ** BSD 4.3 message header */ struct msghdr {9 char *msg_name; /* The address of the destina-J ** tion socket, if the socket isI ** connected. If no address isH ** required, thi s field can be9 ** set to NULL., */C int msg_namelen; /* Len of msg_name field., */B struct iovec *msg_iov; /* Scatter/Gather array., */C int msg_iovlen; /* # elements in msg_iov., */@ char *msg_accrights; /* Points to a buffer containingM ** access rights sent with message., */M int msg_accrightslen;/* Len of the msg_accrights buffer., */ };#endif( typedef struct msghdr *__msghdr_ptr;4 typedef const struct msghdr *__const_msghdr_ptr;/*J** This section is for functions and declarations which do support 64 bitK** pointers being passed (or returned). The socket interface is differentG** from other 64 bit interfaces in that only a select set of functionsK** accept 64 bit pointers. The DEC C RTL is a thin layer between the user/** application and a vendors tcp/ip interface.*/#if __CAN_USE_EXTERN_PREFIX!# pragma __extern_prefix __save#endif#ifdef _SOCKADDR_LEN# if __CAN_USE_EXTERN_PREFIX## pragma __extern_prefix "__bsd44_"# elseQ# define recvmsg(__p1,__p2,__p3) __bsd44_recvmsg(__p1,__p2,__p3)Q# define sendmsg(__p1,__p2,__p3) __bsd44_sendmsg(__p1,__p2,__p3) # endif#endif=__ssize_t recvmsg(int __sd, __msghdr_ptr __msg, int __flags);C__ssize_t sendmsg(int __sd, __const_msghdr_ptr __msg, int __flags);#if __CAN_USE_EXTERN_PREFIX$# pragma __extern_prefix __restore#endif/*O** New pointer-size specific entry points for sendmsg and recvmsg were added inL** OpenVMS V7.3-2 to support pointer-size specific struct msghdr. These are M** new p ointer-size specific entry points and hence are not available on VAX.*/4#if __INITIAL_POINTER_SIZE && __CRTL_VER >= 70311000# if __CAN_USE_EXTERN_PREFIX# pragma __extern_prefix __save # endif# ifdef _SOCKADDR_LEN"# if __CAN_USE_EXTERN_PREFIX-# pragma __extern_prefix "__bsd44_" # else`# define __recvmsg32(__p1,__p2,__p3) __bsd44___recvmsg32(__p1,__p2,__p3)`# define __sendmsg32(__p1,__p2,__p3) __bsd44___sen dmsg32(__p1,__p2,__p3)`# define __recvmsg64(__p1,__p2,__p3) __bsd44___recvmsg64(__p1,__p2,__p3)`# define __sendmsg64(__p1,__p2,__p3) __bsd44___sendmsg64(__p1,__p2,__p3) # endif # endifE__ssize_t __recvmsg32(int __sd, __msghdr32_ptr32 __msg, int __flags);K__ssize_t __sendmsg32(int __sd, __const_msghdr32_ptr32 __msg, int __flags);E__ssize_t __recvmsg64(int __sd, __msghdr64_ptr64 __msg, int __flags);K__ssize_t __sendmsg64(int __sd, __const_msghdr64_ptr64 __msg, int __flags);# if __CAN_USE_EXTERN_PREFIX'# pragma __extern_prefix __restore # endif#endif:#if __INITIAL_POINTER_SIZE == 64 && __CRTL_VER >= 70311000L# define recvmsg(__p1,__p2,__p3) __recvmsg64(__p1,__p2,__p3)L# define sendmsg(__p1,__p2,__p3) __sendmsg64(__p1,__p2,__p3)M# define __bsd44_recvmsg(__p1,__p2,__p3) __bsd44___recvmsg64(__p1,__p2,__p3)M# define __bsd44_sendmsg(__p1,__p2,__p3) __bsd44___sendmsg64(__p1,__p2,__p3)#endif/*O** If the user has used /pointer_size=32 or /pointer_size=64, we will allow 64.** bit pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*E** Functions which will always accept 32 or 64 bit pointers. If theJ** underlying tcp/ip layer has 64 bit support, then the addresses will beE** passed as they are. If the underlying layer does not have 64 bitH** address support, then the data will be copied to  a malloced area and+** then passed on to the underlying layer.*/#ifdef _SOCKADDR_LEN# if __CAN_USE_EXTERN_PREFIX%# pragma __extern_prefix __save)# pragma __extern_prefix "__bsd44_"# elseF# define accept(__p1,__p2,__p3) __bsd44_accept(__p1,__p2,__p3)B# define bind(__p1,__p2,__p3) __bsd44_bind(__p1,__p2,__p3)H# define connect(__p1,__p2,__p3) __bsd44_connect(__p1,__p2,__p3)O# define getpeername(__p1,__p2,__p3) __bsd44_getpeername(__p1,__p 2,__p3)O# define getsockname(__p1,__p2,__p3) __bsd44_getsockname(__p1,__p2,__p3)f# define recvfrom(__p1,__p2,__p3,__p4,__p5,__p6) __bsd44_recvfrom(__p1,__p2,__p3,__p4,__p5,__p6)b# define sendto(__p1,__p2,__p3,__p4,__p5,__p6) __bsd44_sendto(__p1,__p2,__p3,__p4,__p5,__p6) # endif#endif /* ? ** In DEC C V4.0, the following routines used int or int *> ** for the length parameters. X/Open specifies that these ** are size_t. */ #if !defined _DECC _V4_SOURCE K int accept (int __sd, struct sockaddr *__S_addr, __size_t *__len);T int bind (int __sd, const struct sockaddr *__s_name, __size_t __len); N int connect (int __sd, const struct sockaddr *__name, __size_t __len);I int getpeername (int __sd, struct sockaddr *__name, __size_t *__len);I int getsockname (int __sd, struct sockaddr *__name, __size_t *__len);P __ssize_t recvfrom (int __sd, void *__buf, __size_t __buflen, int __flags, E  struct sockaddr *__from, __size_t *__fromlen);V __ssize_t sendto (int __sd, const void *__msg, __size_t __msglen, int __flags, F const struct sockaddr *__to, __size_t __tolen);#elseE int accept (int __sd, struct sockaddr *__S_addr, int *__addrlen);B int bind (int __sd, struct sockaddr *__s_name, int __namelen);C int connect (int __sd, struct sockaddr *__name, int __namelen);H int getpeername (int __sd, struct sockaddr *__name, int *__namelen);H int getsockname (int __sd, struct sockaddr *__name, int *__namelen);m int recvfrom (int __sd, char *__buf, int __length, int __flags, struct sockaddr *__from, int *__fromlen);f int sendto (int __sd, char *__msg, int __length, int __flags, struct sockaddr *__to, int __tolen);#endif#ifdef _SOCKADDR_LEN# if __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __restore # endif#endif /* ? ** In DEC C V4.0, the following routines used int or int *; ** for the length parameters and char * for the option A ** value. X/Open specifies that these are size_t and void *. */ #if !defined _DECC_V4_SOURCE _ int getsockopt (int __sd, int __level, int __optname, void *__optval, __size_t *__optlen);d int setsockopt (int __sd, int __level, int __optname, const void *__optval, __size_t __optlen);L __ssize_t recv (int __sd, void *__buf, __size_t __length, int __flags);R __ssize_t send (int __sd, const void *__msg, __size_t _ _length, int __flags);#elseY int getsockopt (int __sd, int __level, int __optname, char *__optval, int *__optlen);X int setsockopt (int __sd, int __level, int __optname, char *__optval, int __optlen);@ int send (int __sd, char *__msg, int __length, int __flags);@ int recv (int __sd, char *__buf, int __length, int __flags);#endif*int listen (int __sd, int __backlog);'int shutdown (int __sd, int __mode);=int socket (int __af, int __mess_type, int __prot_type); /* ** DEC C Extensions (64-bit) */ #ifndef _XOPEN_SOURCE_EXTENDED# if __CRTL_VER >= 70000000+ int decc$socket_fd (int __channel);/# if !defined(_DECC) || (__DECC_VER < 60400000)* int socket_fd (int __channel); # endif # endif( int decc$get_sdc (int __descrip_no);*# define vaxc$get_sdc(x) decc$get_sdc(x)# int gethostaddr (char *__addr);# ifdef _DECC_V4_SOURCE6 int gethostname (char *__name, int __namelen);A int select (int __nfds, int *__readfds, int *__writefds, C int *__exceptfds, struct timeval *__timeout);# else; int gethostname (char *__name, __size_t __namelen);G int select (int __nfds, fd_set *__readfds, fd_set *__writefds, F fd_set *__exceptfds, struct timeval *__timeout); # endif#endif#if (__CRTL_VER >= 80200000) F int socketpair (int af, int mess_type, int prot_type, int sd[2] );#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#pragma __standard#endif /* __SOCKET_LOADED */ww!<ԗ#ifndef __STAT_LOADED#define __STAT_LOADED 1M/******************************************************************************2** - stat/fstat UNIX emulation functions**M*****************************************************************************1** Header introduced by the ISO POSIX-1 StandardM*****************************************************************************I** I** Copyright 2004 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty.  I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*J** Create 'public' typedefs that are either insensitive to pointer or are:** sensitive to pointer size and must use short pointers.*//* ** X/Open definitions*/S#if defined _XOPEN_SOURCE || (!defined _POSIX_C_SOURCE && !defined _DECC_V4_SOURCE)# ifndef __TIME_T# define __TIME_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __time_t time_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::time_t;#endif # endif# ifndef __DEV_T# define __DEV_T 1 typedef __dev_t dev_t; # endif# ifndef __INO_T# define __INO_T 1 typedef __ino_t ino_t; # endif# ifndef __NLINK_T# define __NLINK_T 1 typedef __nlink_t nlink_t; # endif# ifndef __MODE_T# define __MODE_T 1 typedef __mode_t mode_t; # endif# ifndef __OFF_T# define __OFF_T 1 typedef __off_t off_t; # endif# ifndef __UID_T# define __UID_T 1 typedef __uid_t uid_t; # endif# ifndef __GID_T# define __GID_T 1# if __USE_LONG_GID_T typedef __gid32_t gid_t;# else typedef __gid16_t gid_t;# endif # endif#endif/* K** Define some macros to use to access the component fields of ino values. K** S_ names are those intended for application use; _S_ names are internal.** S_INO_NUM - file number#** S_INO_SEQ - file sequence number%** S_INO_RVN - relative volume number>** S_INO_RVN_NMX - file number extension, portion of S_INO_RVN>** S_INO_RVN_RVN - relative volume number portion of S_INO_RVN*/#if __USING_STD_STAT-# define _S_INO_NUM_MASK 0x000000000000FFFF-# define _S_INO_SEQ_MASK 0 x00000000FFFF0000-# define _S_INO_RVN_MASK 0x0000FFFF000000001# define _S_INO_RVN_RVN_MASK 0x000000FF000000001# define _S_INO_RVN_NMX_MASK 0x0000FF0000000000C# define S_INO_NUM(ino) ((unsigned short)((ino)&_S_INO_NUM_MASK))I# define S_INO_SEQ(ino) ((unsigned short)(((ino)&_S_INO_SEQ_MASK)>>16))I# define S_INO_RVN(ino) ((unsigned short)(((ino)&_S_INO_RVN_MASK)>>32))P# define S_INO_RVN_RVN(ino) ((unsigned char)(((ino)&_S_INO_RVN_RVN_MASK)>>32))P# define S_INO_RVN_NMX(ino) ((unsigned char)(((ino)&_S_INO_RVN_NMX_MASK)>>40))#else%# define _S_INO_RVN_RVN_MASK 0x00FF%# define _S_INO_RVN_NMX_MASK 0xFF006# define S_INO_NUM(ino) ((unsigned short)((ino)[0]))6# define S_INO_SEQ(ino) ((unsigned short)((ino)[1]))6# define S_INO_RVN(ino) ((unsigned short)((ino)[2]))S# define S_INO_RVN_RVN(ino) ((unsigned char)(S_INO_RVN(ino)&_S_INO_RVN_RVN_MASK))W# define S_INO_RVN_NMX(ino) ((unsigned char)((S_INO_RVN(ino)&_S_INO_RVN_NMX_MASK)>8))#endif/*C** This is the beginning of the standard stat structure definition.=** It is in effect if feature macro _USE_STD_STAT is defined.*/#if __USING_STD_STAT /*L ** Define the size of the output buffer for $GETDVI item DVI$_ALLDEVNAM. */# define __ALLDEVNAM_LEN 64 /*H ** Define the number of quadwords held in reserve at the tail of the, ** new stat struct, for HP's future use. */(# define __STD_STAT_QWORDS_RESERVED 20 /*O ** Define some macros that will assist us in the stat structure definition.? ** These automate the naming and sizing of the fill fields.= ** The __USING_64BIT_TIME_T macro is set in decc$types.h. */<# define __MODE_FILL_SIZE (sizeof(int) - sizeof(__mode_t))?# define __MODEFILL(mem) char mem ## Fill [__MODE_FILL_SIZE];# if __USING_64BIT_TIME_T# define __TIMEFILL(mem)# else># define __TIME_FILL_SIZE (sizeof(__int64) - sizeof(__time_t))=# define __TIMEFILL(mem) char mem ## Fill [__TIME_FILL_SIZE]; # endif$# pragma __member_alignment __save# pragma __member_alignment struct stat {' __dev_t st_dev; /* device id */) __ino_t st_ino; /* file number */( __mode_t st_mode; /* file mode */ __MODEFILL( st_mode) 4 __nlink_t st_nlink; /* number of hard links */% __uid_t st_uid; /* user id */& __gid_t st_gid; /* group id */ __dev_t st_rdev; 0 __off_t st_size; /* file size in bytes *// __time_t st_atime; /* file a ccess time */ __TIMEFILL( st_atime)/ __time_t st_mtime; /* file mod time */ __TIMEFILL( st_mtime)4 __time_t st_ctime; /* file creation time */ __TIMEFILL( st_ctime)( char st_fab_rfm; /* record format */, char st_fab_rat; /* record attributes */, char st_fab_fsz; /* fixed header size */ char st_fabFill;- unsigned st_fab_mrs; /* record size */Z blksize_t st_blksize; /* filesystem-specific preferred I/O block size for this file */G blkcnt_t st_blocks; /* number of blocks allocated for this file */A char st_reserved[sizeof(__int64)*__STD_STAT_QWORDS_RESERVED];};'# pragma __member_alignment __restore+#else /* end of __USING_STD_STAT section *//*=** There are two definitions of the stat structure. The first<** is intended for newly compiled applications and is larger"** than the traditional structure.**=** The new structure has aligned fields and has a fixed size.:** It contains padding for elements sh orter than type int,;** and in some cases where a field may have 2 sizes such as>** st_size and st_gid. It also has spare fields at the end for** future expansion.**=** The traditional structure is for use when passing pointers<** to stat structures with previously compiled objects. This=** structure does not have aligned elements. Its size varies,8** depending on whether datatype gid_t is short or long.**:** Note that times are given in units of seconds since the;** Epoch i.e. times returned are measured in seconds since ** 00:00:00 GMT, Jan. 1, 1970.**@** ISO POSIX-1 defines off_t to be a signed arithmetic type, and>** requires the st_size field to be of type off_t. DEC C V5.0,** and prior declared the field as unsigned.*/#if __USE_OFF64_T/*;** This is the new stat structure. It has aligned fields, ?** extra padding to allow fields to expand and extra space at !** the end for future expansion.*/ !#pragma __member_alignment __save#pragma member_alignment struct stat{K __dev_t st_dev; /* pointer to physical device name */ __dev_t st_fill_dev;#if __USE_INO64 __ino64_t st_ino;#elif __USE_INO32 __ino32_t st_ino; __ino32_t st_fill_ino;#elseB __ino16_t st_ino[3]; /* 3 words to receive fid */8 __ino16_t st_fill_ino; /* spare word for fill */#endifQ __mode_t st_mode; /* file "mode" i.e. prot, dir, reg, etc. */L __mode_t st_fill_mode;  /* fill because mode_t is defined as short */@ __nlink_t st_nlink; /* number of hard links */D __uid_t st_uid; /* from ACP - QIO uic field */# if __USE_LONG_GID_TR __gid32_t st_gid; /* long group number from POSIX_OWNER ACE */# elseN __gid16_t st_gid; /* short group number extracted st_uid*/N __gid16_t st_fill_gid; /* padding because short GID is only 16 bits */# endif7# if defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCEK __dev_t st_rdev; /* for compatibility - always zero */# elseH __dev_t st_fill_rdev; /* padding when st_rdev is not defined */# endif# if defined _DECC_V4_SOURCEC unsigned int st_size; /* file size in bytes, was unsigned */( int st_fill_size; /* padding */# else7 __off64_t st_size; /* file size in bytes */# endifU __time_t st_atime; /* file access time; always same as st_m time */, __time_t st_fill_atime; /* padding */B __time_t st_mtime; /* last modification time */, __time_t st_fill_mtime; /* padding */> __time_t st_ctime; /* file creation time */, __time_t st_fill_ctime; /* padding */# ifndef _POSIX_C_SOURCE9 char st_fab_rfm; /* record format */= char st_fab_rat; /* record attributes */= char st_fab_fsz; /* fixed header size */, char  st_fab_fill; /* padding */7 unsigned int st_fab_mrs; /* record size */# else char st_fill_fab[4]; unsigned int st_fill_mrs;# endif9 int st_fill_expand[8]; /* room for expansion */};&# pragma __member_alignment __restore#else/* E** This is the traditional stat structure. Its size varies depending1** on whether long or short gid_t is being used.*//*** Disable warning messages*/# pragma __message __save/# pragma __message __disable (__MISALGNDSTRCT)-# pragma __message __disable (__MISALGNDMEM) /*0** Do not naturally align older data structures*/## pragma __member_alignment __save# pragma __nomember_alignment struct stat{K __dev_t st_dev; /* pointer to physical device name */B __ino16_t st_ino[3]; /* 3 words to receive fid */Q __mode_t st_mode; /* file "mode" i.e. prot, dir, reg, etc. */@ __nlink_t st_nlink; /* number of hard links */D __uid_t st_uid; /* from ACP - QIO uic field */#if __USE_LONG_GID_TR __gid32_t st_gid; /* long group number from POSIX_OWNER ACE */#elseO __gid16_t st_gid; /* short group number extracted st_uid */#endif8# if defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCEK __dev_t st_rdev; /* for compatibility - always zero */# else __dev_t st_fill1; # endif# if defined _DECC_V4_SOUR CEC unsigned int st_size; /* file size in bytes, was unsigned */# else7 __off32_t st_size; /* file size in bytes */ # endifU __time_t st_atime; /* file access time; always same as st_mtime */B __time_t st_mtime; /* last modification time */> __time_t st_ctime; /* file creation time */# ifndef _POSIX_C_SOURCE9 char st_fab_rfm; /* record format */= char st_fab_rat; /* record attributes */= char st_fab_fsz; /* fixed header size */7 unsigned int st_fab_mrs; /* record size */# else char st_fill2[3]; unsigned int st_fill3;# endif};# pragma __message __restore&# pragma __member_alignment __restore#endif#endif /* __USING_STD_STAT *//*** DEC C extensions*/#ifndef _POSIX_C_SOURCE typedef struct stat stat_t; #endif/*** Private definitions*/ 0#define __S_IFMT 0170000 /* type of file */0#define __S_IFIFO 0010000 /* pipe or fifo */-#define __S_IFDIR 0040000 /* directory */5#define __S_IFCHR 0020000 /* character special */1#define __S_IFBLK 0060000 /* block special */+#define __S_IFREG 0100000 /* regular */<#define __S_IFMPC 0030000 /* multiplexed char special */=#define __S_IFMPB 0070000 /* multiplexed block special */*#define __S_IFSOCK 0140000 /* socket */1#define __S_IFLNK 0120000 /* symbolic link *//* **  ISO POSIX-1 definitions*/ :#define S_ISUID 0004000 /* set user id on execution */;#define S_ISGID 0002000 /* set group id on execution */@#define S_IRWXU 0000700 /* read,write,execute perm: owner */8#define S_IRUSR 0000400 /* read permission: owner */9#define S_IWUSR 0000200 /* write permission: owner */B#define S_IXUSR 0000100 /* execute/search permission: owner */@#define S_IRWXG 0000070 /* read,write,execute perm: group */8#define S_IRGRP 0000040 /*  read permission: group */9#define S_IWGRP 0000020 /* write permission: group */B#define S_IXGRP 0000010 /* execute/search permission: group */@#define S_IRWXO 0000007 /* read,write,execute perm: other */8#define S_IROTH 0000004 /* read permission: other */9#define S_IWOTH 0000002 /* write permission: other */B#define S_IXOTH 0000001 /* execute/search permission: other */2#define S_ISFIFO(m) (((m)& __S_IFMT) == __S_IFIFO)2#define S_ISDIR(m) (((m)& __S_IFMT) == __S_IFDIR)2#define S_ISCHR(m) (((m)& __S_IFMT) == __S_IFCHR)2#define S_ISBLK(m) (((m)& __S_IFMT) == __S_IFBLK)2#define S_ISREG(m) (((m)& __S_IFMT) == __S_IFREG)/* ** X/Open XPG4 definitions*/ 5#if defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCE1# define S_IFMT __S_IFMT /* type of file */1# define S_IFIFO __S_IFIFO /* pipe or fifo */.# define S_IFDIR __S_IFDIR /* directory */6# define S_IFCHR __S_IFCHR /* character special */2# define S_IFBLK __S_IFBLK /* block special */,# define S_IFREG __S_IFREG /* regular */ #endif /* ** X/Open XPG4 V2 definitions*/ >#if defined _XOPEN_SOURCE_EXTENDED || !defined _POSIX_C_SOURCE+# define S_IFSOCK __S_IFSOCK /* socket */2# define S_IFLNK __S_IFLNK /* symbolic link */1# define S_ISLNK(m) (((m)& S_IFMT) == S_IFLNK)2# define S_ISSOCK(m) (((m)& S_IFMT) == S_IFSOCK)E# define S_ISVTX 0001000 /* save swapped text even after use */#endif/* ** DEC C extensions */ #ifndef _POSIX_C_SOURCE;# define S_IREAD 0000400 /* read permission, owner */<# define S_IWRITE 0000200 /* write permission, owner */E# define S_IEXEC 0000100 /* execute/search permission, owner */=# define S_IFMPC __S_IFMPC /* multiplexed char special */># define S_IFMPB __S_IFMPB /* multiplexed block special */#endif/*H** We are done defining things which must always be short pointers. IfH** the user has used /pointer_size=short or /pointer_size=long, we will5** allow long pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif#if __USING_STD_STAT# pragma __extern_prefix __save!# pragma __extern_prefix "__std_"#else#if __USE_OFF64_T!# pragma __extern_prefix __save# if __USE_LONG_GID_T,# pragma __extern_prefix "__off64_long_gid_" # elif !defined _VMS_V6_SOURCE'# pragma __extern_prefix "__off64_utc_"# else## pragma __extern_prefix "__off64_" #  endif#elif __USE_LONG_GID_T /*J ** On Alpha, beginning in version of OpenVMS Alpha following V7.3, statK ** and fstat support 32-bit gid_t datatype. The stat and fstat functionsL ** supporting long gid_t datatype can return UTC time only. If local timeJ ** is required, define _VMS_V6_SOURCE macro. Defining _DECC_SHORT_GID_TL ** or _VMS_V6_SOURCE macro causes DEC C RTL to use 16-bit gid_t datatype. */!# pragma __extern_prefix __save(# pragma __extern_prefix "__long_gid_"#elif __CRTL_VER >= 70000000 /*F ** Beginning in OpenVMS Version 7.0 stat has two implementations. B ** One for compatibility stat() which returns time in terms ofJ ** local time and one __utc_stat() which returns time in terms of UTC. */# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX'# pragma __extern_prefix __save)# pragma __extern_prefix "__utc_" # else8# define stat(__p1,__p2) __utc_stat(__p1,__p2)9# define fstat(__p1,__p2) __utc_fstat(__p1,__p2)0# if !defined(__VAX) && __CRTL_VER >= 70301000;# define lstat(__p1,__p2) __utc_lstat(__p1,__p2) # endif # endif # endif#endif /* __USE_OFF64_T */#endif /* __USING_STD_STAT *//*** Function prototypes*/3int fstat (int __file_desc, struct stat *__buffer);/*N** If we cannot use extern prefix, then the user cannot get the ellipsis formM** of the prototype. Applications which must use the optional argument s mayK** either upgrade the compiler or change the call site to use decc$stat or$** decc$__utc_stat instead of stat.*/C#if (defined _POSIX_C_SOURCE) || (!defined __CAN_USE_EXTERN_PREFIX)7 int stat (const char *__path, struct stat *__buf);0# if !defined(__VAX) && __CRTL_VER >= 703010009 int lstat (const char *__path, struct stat *__buf); # endif#else< int stat (const char *__path, struct stat *__buf, ...);0# if !defined(__VAX) && __CRTL_VER >= 70301000> int lstat (const char *__path, struct stat *__buf, ...); # endif#endif/*2** Disable extern_prefix if we enabled it earlier*/#if __USING_STD_STAT "# pragma __extern_prefix __restore#else%#if __USE_LONG_GID_T || __USE_OFF64_T$# pragma __extern_prefix __restore#elif __CRTL_VER >= 70000000# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX+# pragma __extern_prefix __restore # endif # endif#endif#endif#if __USE_LONG_GID_T!# pragma __extern_prefix __save(# pragma __extern_prefix "__long_gid_"#endif7int chmod (const char *__file_spec, __mode_t __mode);(int fchmod (int __fd, __mode_t __mode);#if __USE_LONG_GID_T$# pragma __extern_prefix __restore#endif&__mode_t umask (__mode_t __old_mask);#ifdef _POSIX_C_SOURCE 8 int mkdir (const char *__dir_spec, __mode_t __mode);#else= int mkdir (const char *__dir_spec, __mode_t __mode, ...);#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __STAT_LOADED */wwt<ԗ#ifndef __STATVFS_LOADED#define __STATVFS_LOADED 1J/*************************************************************************7 * - definitions for file system statisticsJ**************************************************************************H * Header introduced by the X/Open CAE Specification, Issue 4, Version 2J**************************************************************************J * *J * Copyright 2004 Hewlett-Packard Development Company, L.P. *J * *J * Confidential computer software. Valid license from HP and/or *J * its subsidiaries required for possession, use, or copying. *J *  *J * Consistent with FAR 12.211 and 12.212, Commercial Computer Software, *J * Computer Software Documentation, and Technical Data for Commercial *J * Items are licensed to the U.S. Government under vendor's standard *J * commercial license. *J * *J * Neither HP nor any of its subsidiaries shall be liable for technical *J * or editorial errors or omissions contained herein. The information *J * in this document is provided "as is" without warranty of any kind and *J * is subject to change without notice. The warranties for HP products *J * are set forth in the express limited warranty statements accompanying *J * such products. Nothing herein should be construed as constituting an *J * additional warranty. *J *  *K *************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif!#pragma __member_alignment __save#pragma __member_alignmentstruct statvfs {> unsigned long f_frsize; /* fundamental block size */; unsigned long f_bsize; /* preferred block size */8 fsblkcnt_t f_blocks; /* total block count */6 fsblkcnt_t f_bfree; /* free bloc k count */N fsblkcnt_t f_bavail; /* available block count, subject to quota */6 fsfilcnt_t f_files; /* total file count */C fsfilcnt_t f_ffree; /* free file count (approximate) */I fsfilcnt_t f_favail; /* available file count (approximate) */4 unsigned long f_fsid; /* file system id */D unsigned long f_flag; /* ST_RDONLY, ST_NOSUID flag bits */A unsigned long f_namemax; /* maximum file name length */3 char f_basetype[64]; /* device type name */> char f_fstr[64]; /* file system-specific string */: char __reserved[64]; /* reserved for future use */ };2#define ST_RDONLY 0x01 /* read-only file system */g#define ST_NOSUID 0x02 /* does not support the semantics of the ST_ISUID and ST_ISGID file mode bits */#if __INITIAL_POINTER_SIZE# pragma __pointer_size __save# pragma __pointer_size 64#endif[int statvfs(const char * __XOPEN_RESTRICT __path, struct statvfs * __XOPEN_RESTRICT __buf);/int fstatvfs(int filedes, struct statvfs *buf);#if __INITIAL_POINTER_SIZE "# pragma __pointer_size __restore#endif$#pragma __member_alignment __restore#ifdef __cplusplus }#endif#pragma __standard#endifww<ԗ#ifndef __STDARG_LOADED#define __STDARG_LOADED 1#ifndef __STDARG_PROCESSED#define __STDARG_PROCESSEDM/******************************************************************************$** - Variable Arguments **M*****************************************************************************,** Header introduced by the ANSI C StandardM*****************************************************************************I** I** Copyright 2004 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or  I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I**  I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard #include #ifdef __cplusplus extern "C" {#endif/*M** The header files VARARGS.H and STDARG.H cannot be used together; undo the** effects of VARARGS.H.*/#ifdef __VARARGS_LOADED# undef __VARARGS_LOADED# undef va_dcl# undef va_count# undef va_start_1# undef va_start# undef va_arg# undef va_end#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*** Declare a va_list */#ifndef __VA_LIST# define __VA_LIST typedef __va_list va_list;#endif#ifdef __NAMESPACE_STD} /* namespace std */#endif#if !defined(__VAX)# if __X_FLOAT!# define va_start(ap, parmN) \E ap = (__va_list) ((__char_ptr32) __VA_START_BUILTIN(parmN) + \\ (((__IS_X_FLOAT_BUILTIN(parmN) ? sizeof(long double *) : sizeof(parmN)) + 7) & ~7))O# if defined(__va_arg_no_comma) || (defined(__cplusplus) && defined(__ia64))E /* Linux-style definition of va_arg, without comma operator */H# define va_arg(ap, type) (__IS_X_FLOAT_BUILTIN(type) ? \H (* ((type **) \H ((__char_ptr32)(ap = (__va_list) ((__char_ptr32) ap + \H ((sizeof(long double *) + 7) & ~7))) -  \H ((sizeof(long double *) + 7) & ~7)))[0]) \H : \H ( ((type *) \H ((__char_ptr32)(ap = (__va_list) ((__char_ptr32) ap + \H ((sizeof(type) + 7) & ~7))) - \H ((sizeof(type) + 7) & ~7)))[0]) \ ) # elseA /* VMS-styl e definition of va_arg, using comma operator */!# define va_arg(ap, type) (\0 ap = (__va_list) ((__char_ptr32) ap + \` (((__IS_X_FLOAT_BUILTIN(type) ? sizeof(long double *) : sizeof(type)) + 7) & ~7)), \* __IS_X_FLOAT_BUILTIN(type) ? \/ (** (type **)((__char_ptr32) ap - \Z (((__IS_X_FLOAT_BUILTIN(type) ? sizeof(long double *) : sizeof(type)) + 7) & ~7))) : \/ ( * (type *)((__char_ptr32) ap - \X (((__IS_X_FLOAT_BUILTIN(type) ? sizeof(long double *) : sizeof(type)) + 7) & ~7))) ) # endif# else!# define va_start(ap, parmN) \Z ap = (__va_list) ((__char_ptr32) __VA_START_BUILTIN(parmN) + ((sizeof (parmN) + 7) & ~7))# define va_arg(ap, type) (\E ap = (__va_list) ((__char_ptr32) ap + ((sizeof (type) + 7) & ~7)), \A (* (type *)((__char_ptr32) ap - ((sizeof (type) + 7) & ~7))))# endif /* 0 ** va_count is an extension to the standard. */ # ifndef __HIDE_FORBIDDEN_NAMES+ unsigned int __VA_COUNT_BUILTIN(void);:# define va_count(count) (count = __VA_COUNT_BUILTIN())# endif#else<# if (__DECC_VER >= 50300000) || (__DECCXX_VER >= 50300000)?# define va_start(ap, parmN) ap = __VA_START1_BUILTIN(parmN)# define va_arg(ap, type) \ (__VA_START_BUILTIN(), (\E ap = (__va_list) ((__char_ptr32) ap + ((sizeof (type) + 3) & ~3)), \> * (type *) ((__char_ptr32) ap - ((sizeof (type) + 3) & ~3))))# else# ifdef __cplusplus## define va_start(ap, parmN) \I ap = (__va_list) ((__char_ptr32) &parmN + ((sizeof (parmN) + 3) & ~3))!# define va_arg(ap, type) (\N ap = (__va_list) ((__char_ptr32) ap + ((sizeof (type) + 3) & ~3)), \J * (type *) ((__char_ptr32) ap - ((sizeof (type) + 3) & ~3))) # else## define va_start(ap, parmN) \( ap = (__VA_START_BUILTIN(), \P (__va_list) ((__char_ptr32) &parmN + ((sizeof (parmN) + 3) & ~3))) # define va_arg(ap, type) \$ (__VA_START_BUI LTIN(), (\H ap = (__va_list) ((__char_ptr32) ap + ((sizeof (type) + 3) & ~3)), \K * (type *) ((__char_ptr32) ap - ((sizeof (type) + 3) & ~3)))) # endifF# endif /* (__DECC_VER >= 50300000) || (__DECCXX_VER >= 50300000) */ # ifndef __HIDE_FORBIDDEN_NAMES( void decc$va_count( int *__count );5# if defined(__DECC) || (__DECCXX_VER >= 50300000)L# define va_count(count) (__VA_START_BUILTIN(), decc$va_count (&count)) # else5# define va_count(count) decc$va_count (&count) # endif# endif#endif&#define va_end(ap) ap = (__va_list) 0#ifdef __cplusplus }#endif#pragma __standard#endif /* __STDARG_PROCESSED */>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_STDARG_NAMES # define __USING_STDARG_NAMES using std::va_list;# endif#endif#endif /* __STDARG_LOADED */ww<ԗ#ifndef __STDBOOL_LOADED#define __STDBOOL_LOADED 1M/************************* *****************************************************'** - C99 boolean data type**M*****************************************************************************)** Header introduced by the C99 StandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I**  I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include 1#if ! (defined(__DECC) && __DECC_VER >= 60400000)E# error "C99 header is not supported by this compiler."#else#  define bool _Bool# define true 1# define false 0,# define __bool_true_false_are_defined 16#endif /* defined(__DECC) && __DECC_VER >= 60400000 */#pragma __standard#endif /* __STDBOOL_LOADED */ww$ =ԗ#ifndef __STDDEF_LOADED#define __STDDEF_LOADED#ifndef __STDDEF_PROCESSED#define __STDDEF_PROCESSEDM/******************************************************************************$** - Common Definitions **M*****************************************************************************,** Header introduced by the ANSI C StandardM*****************************************************************************I** I** Copyright 2004 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I**  I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty.  I** M******************************************************************************/#pragma __nostandard#include #ifdef __NAMESPACE_STDnamespace std {#endiftypedef int ptrdiff_t;#ifndef __SIZE_T# define __SIZE_T 1 typedef __size_t size_t;#endif#ifdef __NAMESPACE_STD} /* namespace std */#endif#ifndef __WCHAR_T# define __WCHAR_T typedef __wchar_t wchar_t;#endif #ifndef NULL# define NULL __NULL#endif#if __DECCXX_VER > 60500000N# define offsetof(__t, __memb) ((__size_t)__INTADDR__(&(((__t *)0)->__memb)))#else`# define offsetof(type, identifier) ((__size_t)((char *)&((type*)0L)->identifier - (char *)0L))#endif#pragma __standard#endif /* __STDDEF_PROCESSED */>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_STDDEF_NAMES # define __USING_STDDEF_NAMES using std::ptrdiff_t; using std::size_t;# endif#endif#endif /* __STDDEF_LOADED */wwI3=ԗ#ifndef __STDIO_LOADED#define __STDIO_LOADED 1#ifndef __STDIO_PROCESSED#define __STDIO_PROCESSEDM/******************************************************************************%** - Standard Input/Output**M*****************************************************************************,** Header introduced by the ANSI C StandardM*****************************************************************************I** I** Copyright 2006 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I**  I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M**** **************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*3** Cplusplus and unix_putc does not work together.@** Primarily for pragma inline functions. So put out an error. *//# if defined __UNIX_PUTC && defined __cplusplus6# error " Use of __UNIX_PUTC not permitted wit h C++"# endif/*** Member align structures*/!#pragma __member_alignment __save#pragma __member_alignment/*K** Create 'public' typedefs that are either insensitive to pointer size or>** are sensitive to pointer size and must use short pointers.*/ #ifndef NULL# define NULL __NULL#endifstruct _iobuf { int _cnt; char *_ptr; char *_base; unsigned char _flag;#if __CRTL_VER >= 70000000"   unsigned char _padfile;  unsigned char _pad1; unsigned char _pad2; int _file;#else unsigned char _file;  unsigned char _pad1; unsigned char _pad2;#endif};#ifdef __NAMESPACE_STDnamespace std {#endif#ifndef __FILE_T# define __FILE_T typedef __FILE FILE;#endifHtypedef struct __fpos {unsigned __f0 : 32; unsigned __f1 : 32; } fpos_t;#ifndef __SIZE_T# define __SIZE_T 1 typedef  __size_t size_t;#endif#ifdef __NAMESPACE_STD} /* namespace std */#endifg#if !defined(_DECC_V4_SOURCE) && (__USE_OFF64_T || defined(_XOPEN_SOURCE) || !defined(_ANSI_C_SOURCE) )# ifndef __OFF_T# define __OFF_T 1 typedef __off_t off_t;# endif#endif/*5** Define macros to access stdin, stdout, and stderr*/ #ifndef __VAX"# define stderr (decc$ga_stderr)!# define stdin (decc$ga_stdin)"# define stdout (decc$ga_stdout)#else## define stderr (*decc$g a_stderr)"# define stdin (*decc$ga_stdin)## define stdout (*decc$ga_stdout)#endif/*$** Define stdin, stdout, and stderr*/#pragma __extern_model __save&#pragma __extern_model __strict_refdef extern __FILE * stderr; extern __FILE * stdin; extern __FILE * stdout; #pragma __extern_model __restore/*A** Define optind, opterr, optopt, and optarg. X/Open originallyG** specified these in . ISO POSIX-2 moved them to ** X/Open retains them in both.*/G#if __CRTL_VER >= 60200000 /* Supported starting with OpenVMS V6.2 */9# if defined(_XOPEN_SOURCE) || !defined(_ANSI_C_SOURCE)## pragma __extern_model __save,# pragma __extern_model __strict_refdef extern int optind; extern int opterr; extern int optopt; extern char *optarg;&# pragma __extern_model __restore # endif#endif/*L** The ANSI standard defines the following integral constant expressions asJ** having distinct values, suitable for use as the third argument to the ** setvbuf function.*/#define _IOLBF 0x01#define _IOFBF 0x02#define _IONBF 0x04/*M** Values for _flag field in the _iobuf structure. This flag is used by theG** functions clearerr(), feof() and ferror(). A standards conforming@** program should not use _IOEOF or _IOERR. Use clearerr, feof** and ferror macros instead.*/# define _IOEOF 0x10# define _IOERR 0x20#ifndef _ANSI_C_SOURCE# define _IOREAD 0x01# define _IOWRT 0x02# define _IOMYBUF 0x08# define _IOSTRG 0x40# define _IORW 0x80#endif/*F** Define seek modes. Note that the SEEK_EOF value is not defined byD** the ANSI standard, but is provided for compatibility with VAX C.*/#define SEEK_SET 0#define SEEK_CUR 1#define SEEK_END 2#ifndef _ANSI_C_SOURCE# define SEEK_EOF SEEK_END#endif/*I** The literal BUFSIZ is defined by the ANSI standard as the size of the'** buffer used by the setbuf function.*/ #ifndef __VAX# define BUFSIZ 32768#else# define BUFSIZ 8192#endif/*;** DEC C RTL extension. Define the values TRUE and FALSE.*/#ifndef _ANSI_C_SOURCE# ifndef TRUE# define TRUE 1 # endif# ifndef FALSE# define FALSE 0 # endif#endif/*L** The ANSI standard defines EOF as a negative integral constant expressionK** that is returned by several functions to indicate end-of-file. Internal;** __EOF macro is defined in header as (-1)*/#define EOF __EOF/*B** The ANSI standard defines FILENAME_MAX as an integral constantK** expression that is the size needed for an array of char large enough toH** hold the longest file name string that the implementation guarantees** can be opened.**J** The ANSI standard defines FOPEN_MAX as an integral constant expressionJ** that is the minumum number of files that the implementation guaranteesJ** can be opened simultaneously. This value is difficult to define as anJ** accurate constant value since many things affect the ability to open a** given number of files.*/#define FILENAME_MAX 256#define FOPEN_MAX 8/*M** DEC C RTL extension. Define OPEN_MAX to be identical to FOPEN_MAX. Also*** define _NFILE for VAX C compatibility.*/#ifndef _ANSI_C_SOURCE# define OPEN_MAX FOPEN_MAX# define _NFILE 20#endif/*C** The literal values L_tmpnam and TMP_MAX are defined by the ANSIE** standard. If the argument to the tmpnam() function is not a nullD** pointer, it is assumed to point to an array of at least L_tmpnamH** characters. The value TMP_MAX represents the number of unique namesJ** which must be returned from the tmpnam() function on successive calls.*/#define L_tmpnam 256#if __CRTL_VER >= 70301000# define TMP_MAX 17576#else# define TMP_MAX 156#endif/*F** ISO POSIX-1 extensions. These literal values are analogous to the/** L_tmpnam value for tmpnam() function calls.*/8#if defined(_POSIX_C_SOURCE) || !defined(_ANSI_C_SOURCE)# define L_cuserid 16# define L_ctermid 64#endif/*D** DEC C RTL extensions. These literal values are analogous to the/** L_tmpnam value for tmpnam() function calls.*/#ifndef _ANSI_C_SOURCE# define L_lcltmpnam 256# define L_nettmpnam 256#endif/*E** The MIA standard requires use of a special rename() and freopen();** function. Define macros when compiling with that mode.*/ #ifdef __MIA"# define rename decc$mia_rename## define freopen decc$mia_freopen#endif/*F** Conditions for X/Open file pointer locking functions to be visible.*/?#if ( (defined(_XOPEN_SOURCE) || !defined(_ANSI_C_SOURCE)) && \ (__CRTL_VER >= 80200000) )# define __FP_LOCKING 1#else# define __FP_LOCKING 0#endif/*P** Conditions to permit optimizations not requiring X/Open file pointer locking.*/#ifdef __STDIO_UNLOCK_CHAR_IO# define __FP_OPTIMIZATIONS 1#else# if __FP_LOCKING# define __FP_OPTIMIZATIONS 0# else# define __FP_OPTIMIZATIONS 1 # endif#endif/*J** Throughout this header file, for a C++ compilation with __NAMESPACE_STDM** enabled, functions from ANSI C standard that are defined as macros in thisB** header file, are defined as inline functions instead of macros.**J** This is to comply with clause 17.4.1.2 Headers [lib.headers] of the C++&** standard which says, in particular:J-6- Names that are defined as functions in C shall be defined as functions" in the C++ Standard Library.*)L*) This disallows the practice, allowed in C, of providing a "masking macro"L in addition to the function prototype. The only way to achieve equivalentJ "inline" behavior in C++ is to provide a definition as an extern inline function.*//*** DEC C Performance (Macros)*/P#define __feof_(stream) (((unsigned int)((*(stream))->_flag) & _IOEOF) != 0)P#define __ferror_(stream) (((unsigned int)((*(stream))->_flag) & _IOERR) != 0)N#define __clearerr_(stream) ((void)((*(stream))->_flag &= ~(_IOERR | _IOEOF)))#ifndef __NAMESPACE_STD#if __FP_OPTIMIZATIONS(#define feof(stream) __feof_(stream)*#define ferror(stream) __ferror_(stream),#define clearerr(stream) __clearerr_(stream)#endif#else#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endifnamespace std {#pragma __extern_prefix __save#pragma __extern_prefix "CXXL$"#if __FP_OPTIMIZATIONS=inline int feof(FILE* stream) { return __feof_(stream); }?inline int ferror(FILE* stream) { return __ferror_(stream); };inline void clearerr(FILE* stream) { __clearerr_(stream); }#endif!#pragma __extern_prefix __restore} /* namespace std */#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#endif /* __NAMESPACE_STD *//*** DEC C Performance (Inlined)**L** Certain DEC C functions are available as inline code instead of making aE** call to the DEC C RTL. Using this inline code offers performanceB** improvements and are enabled here for all programs not on VAX.*/ #ifndef __VAX /*= ** Optimized getc, getchar, putc, putchar, fgetc, fputc.E ** ANSI standard says that getc/putc can evaluate its parameters ** more than once. ** */# ifndef __NAMESPACE_STD /*! ** C compilation, define macros **B ** Any change in the macro below should be made in corresponding; ** inline function for a C++ compilation, and vice versa. ** */'# define __getc_(__fp) ((*(__fp)) ? \J (((((*(__fp))->_cnt > 0) & !((int)(*(__fp))->_flag & 0x40)) ? \R ((*(__fp))->_cnt--, ((int) ((unsigned char) *((*(__fp))->_ptr++)))) : \) (getc)(__fp))) : (getc)(__fp))+# if !defined(getc) && __FP_OPTIMIZATIONS&# define getc(__fp) __getc_(__fp) # endif%# define __getchar_() ((*stdin) ? \H (((((*stdin)->_cnt > 0) & !((int)(*stdin)->_flag & 0x40)) ? \P ((*stdin)->_cnt--, ((int) ((unsigned char) *((*stdin)->_ptr++)))) : \' (getchar)())) : (getchar)()).# if !defined(getchar) && __FP_OPTIMIZATIONS$# define getchar() __getchar_() # endif# else /* __NAMESPACE_STD */#if __FP_OPTIMIZATIONS /*- ** C++ compilation, define inline functions */#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endifnamespace std {#pragma __extern_prefix __save#pragma __extern_prefix "CXXL$" inline int getc(FILE* __fp); inline int getchar();!#pragma __extern_prefix __restore inline int getc(FILE* __fp) { int decc$getc(FILE*); return ((*__fp) ?D (((((*__fp)->_cnt > 0) & !((int)(*__fp)->_flag & 0x40)) ?L ((*__fp)->_cnt--, ((int) ((unsigned char) *((*__fp)->_ptr++)))) :4 (decc$getc)(__fp))) : (decc$getc)(__fp)); } inline int getchar() { int decc$getchar(void); return ((*stdin) ?F (((((*stdin)->_cnt > 0) & !((int)(*stdin)->_flag & 0x40)) ?N ((*stdin)->_cnt--, ((int) ((unsigned char) *((*stdin)->_ptr++)))) :2 (decc$getchar)())) : (decc$getchar)()); }} /* namespace std */#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#endif /* FP locking */# endif /* __NAMESPACE_STD */ /*? ** This is conditional until a problem with static inline 0 **  procedures is corrected in the compiler.9 ** When this is corrected, we must separate this and' ** conditionalize this out of c++. **  */# ifdef __UNIX_PUTC# ifndef putc# pragma __inline __putc= static int __putc( int __c, struct _iobuf **__p2 ) {$ struct _iobuf *__p = *__p2;/ if (!(*__p2)) return (putc)(__c,__p2);$ if ( !((__p)->_flag & 0x40)B & ((int)((__p)->_ptr) != (int) *(((int *) (__p)) + 6))8 ! & !(*(((unsigned char *)(__p))+14) & 0x10 )) {- if ((__p)->_cnt) (__p)->_cnt--;% *(__p)->_ptr++ = (__c);8 *(((unsigned char *) (__p)) + 14) |= 0x02; return __c; + } else return (putc)(__c,__p2); }# if __FP_OPTIMIZATIONS$# define putc(c,fp) __putc(c,fp)# endif # endif# ifndef putchar # pragma __inline __putchar( static int __putchar( int __c ) {& struct "_iobuf *__p = *stdout;/ if (!(*stdout)) return (putchar)(__c);# if (!((__p)->_flag & 0x40)= & ((int)((__p)->_ptr)!=(int) *(((int *)(__p))+6))8 & !(*(((unsigned char *)(__p))+14) & 0x10 )) {- if ((__p)->_cnt) (__p)->_cnt--;% *(__p)->_ptr++ = (__c);8 *(((unsigned char *) (__p)) + 14) |= 0x02; return __c; ) } else return (putchar)(__c); }# if __FP_OPTIMIZATIONS# # define putchar(c) __putchar(c) # endif # endif # endif /*@ ** ANSI standard says that fgetc/fputc cannot evaluate its 9 ** parameters more than once so make sure it is doneJ ** via a static inline function. and surrounded by unix conditionals. */# ifdef __UNIX_PUTC# ifndef fgetc# pragma inline __fgetcA static int __fgetc (__FILE *__fp) {return (getc (__fp));}# if __FP_OPTIMIZATIONS"# define fgetc(fp) __fgetc(fp)# endi$f# endif# ifndef fputc# pragma __inline __fputcU static int __fputc(int __c, struct _iobuf **__p2) {return (putc(__c, __p2));}# if __FP_OPTIMIZATIONS&# define fputc(c,fp) __fputc(c,fp)# endif # endif # endif#endif /* ! __VAX *//*H** This section is for functions and declarations which do not support /** 64 bit pointers being passed (or returned).*/#ifdef __NAMESPACE_STDnamespace std {#endif.void setbuf (__FILE *__stream, c%har *__buf);Kint setvbuf (__FILE *__stream, char *__buf, int __mode, __size_t __size);#ifdef __NAMESPACE_STD} /* namespace std */#endif/* K** The function cuserid is defined by IEEE Std 1003.1-1988 and was changedO** from mandatory to permitted by ISO POSIX-1. With IEEE Std 1003.1-1988, theN** definition is in . X/Open added it to while retaining ** the definition in **L** The function getopt was originally in ISO POSIX-2 moved& it to)** X/Open retains it in both.*/ 6#if defined(_XOPEN_SOURCE) || !defined(_ANSI_C_SOURCE)J# if __CRTL_VER >= 60200000 /* Supported starting with OpenVMS V6.2 */O int getopt (int __argc, char * const __argv[], const char *__optstring); # endif#endif/*O** We are done (for now) defining things which must always be short pointers. K** If the user has used /pointer_size=short or /pointer_size=long, we will5** allow long pointers to be used in function' calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*** ANSI Function prototypes*/S__size_t fread (void *__ptr, __size_t __size, __size_t __nmemb, __FILE *__stream);Y__size_t fwrite (const void *__ptr, __size_t __size, __size_t __nmemb, __FILE *__stream);#int fclose (__FILE *__stream);#int fflush (__FILE *__stream);2int fgetpos (__FILE *__stream, fpos_t *__pos);>int fprintf (__FILE (*__stream, const char *__format, ...);4int fputs (const char *__s, __FILE *__stream);>int fscanf (__FILE *__stream, const char *__format, ...);Dint fseek (__FILE *__stream, long int __offset, int __whence);8int fsetpos (__FILE *__stream, const fpos_t *__pos);#long ftell (__FILE *__stream);#ifdef __NAMESPACE_STD} /* namespace std */#endifG#if __USE_OFF64_T || defined(_XOPEN_SOURCE) || !defined(_ANSI_C_SOURCE)# if __USE_OFF64_T # pragma extern_prefi)x __save&# pragma __extern_prefix "__off64_"I __off_t fseeko (__FILE *__stream, __off_t __offset, int __whence);) __off_t ftello (__FILE *__stream);%# pragma __extern_prefix __restore# elif __CRTL_VER >= 70301000I __off_t fseeko (__FILE *__stream, __off_t __offset, int __whence);) __off_t ftello (__FILE *__stream);# endif#endif#ifdef __NAMESPACE_STDnamespace std {#endif"void perror (const char *__s);,int printf (const char *__forma *t, ...);"int puts (const char *__s);)int remove (const char *__filename);7int rename (const char *__old, const char *__new);,int scanf (const char *__format, ...);7int sprintf (char *__s, const char *__format, ...);=int sscanf (const char *__s, const char *__format, ...);,int ungetc (int __c, __FILE *__stream);Kint vfprintf (__FILE *__stream, const char *__format, __va_list __arg); 8int vprintf (const char *__format, __va_list __arg);Cint v+sprintf (char *__s, const char *__format, __va_list __arg);__FILE_ptr32 tmpfile(void);/*>** The following function prototypes may be defined as macros*/#ifndef __NAMESPACE_STD/*J** For a C++ compilation with __NAMESPACE_STD macro defined, the functionsK** below may have been already defined as inline functions. We declare them<** here only if function definitions have not been provided.*/#void (clearerr) (__FILE *__stream);#int (feof) (__FILE *__stream);#int (,ferror) (__FILE *__stream);#int (getc) (__FILE *__stream);int (getchar) (void);#else#if !(__FP_OPTIMIZATIONS)#void (clearerr) (__FILE *__stream);#int (feof) (__FILE *__stream);#int (ferror) (__FILE *__stream);#int (getc) (__FILE *__stream);int (getchar) (void);#endif#endif#int (fgetc) (__FILE *__stream);,int (fputc) (int __c, __FILE *__stream);,int (putc) (int __c, __FILE *__stream);int (putchar) (int __c);/*H** By d -efining __UNIX_FOPEN, a macro for fopen is defined which ensuresF** that the created file does not inherit attributes from an existingE** file. To use the fopen function with optional RMS arguments, theC** caller is required to use (fopen)() to prevent macro expansion.*/#ifdef __UNIX_FOPENI __FILE_ptr32 fopen (const char *__filename, const char *__mode, ...);# define fopen(__p1,__p2) \C (fopen)(__p1,__p2,"ctx=stm","rfm=stmlf","rat=cr","mrs=0")#else# ifdef _ANS.I_C_SOURCEG __FILE_ptr32 fopen (const char *__filename, const char *__mode); # else L __FILE_ptr32 fopen (const char *__filename, const char *__mode, ...); # endif#endif/*H** The DEC C RTL extends the ANSI standard definitions of the followingH** functions. The function prototypes used in this header file differ 0** when the user is compiling /standard=ansi89.*/#ifdef _ANSI_C_SOURCEX __FILE_ptr32 freopen (const char *__filename, const char *__mode, __FILE/ *__stream);# void rewind (__FILE *__stream);#else] __FILE_ptr32 freopen (const char *__filename, const char *__mode, __FILE *__stream, ...);# int rewind (__FILE *__stream);#endif#ifdef __NAMESPACE_STD} /* namespace std */#endif/*K** The following functions have interfaces of XXX, _XXX32, and _XXX64 due J** to the fact that the return argument is a pointer that is relative to ** one of the arguments.*/ #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_si0ze 32#endif8#if defined(_POSIX_C_SOURCE) || !defined(_ANSI_C_SOURCE) char *ctermid (char *__str);#endif6#if defined(_XOPEN_SOURCE) || !defined(_ANSI_C_SOURCE) char *cuserid (char *__str);#endif#ifdef __NAMESPACE_STDnamespace std {#endif char *gets (char *__s);9 char *fgets (char *__s, int __n, __FILE *__stream); char *tmpnam (char *__s);#ifdef __NAMESPACE_STD} /* namespace std */#endif/*=** End functions with interfaces of XXX, _XXX132, and _XXX64 C** Restore allowing long pointers to be used in function calls if @** the user has used /pointer_size=short or /pointer_size=long.*/#if __INITIAL_POINTER_SIZE#pragma __pointer_size 64#endif#if !(defined(__DECCXX) && \G (defined(__STD_STRICT_ANSI) || defined(__STD_STRICT_ANSI_ERRORS)))/*K** The functions below are not in the ISO/IEC 9899:1990 standard (so calledM** C89). They should not be visible in a C++ compilation in strict ansi mode.*/#if __2CRTL_VER >= 70301000Jint vfscanf (__FILE *__stream, const char *__format, __va_list __arg);8int vscanf (const char *__format, __va_list __arg);Iint vsscanf (const char *__s, const char *__format, __va_list __arg);#endif#if __CRTL_VER >= 70312000Dint snprintf(char *__s, __size_t __n, const char *__format, ...);Pint vsnprintf(char *__s, __size_t __n, const char *__format, __va_list __ap);#endif0#endif /* C++ compilation in strict ansi mode */P#if __INITIAL_POINTE3R_SIZE && !defined(_ANSI_C_SOURCE) && __CRTL_VER >= 70000000# pragma __pointer_size 32# char *_ctermid32 (char *__str);# char *_cuserid32 (char *__str); char *_gets32 (char *);- char *_fgets32 (char *, int, __FILE *); char *_tmpnam32 (char *);# pragma __pointer_size 64# char *_ctermid64 (char *__str);# char *_cuserid64 (char *__str); char *_gets64 (char *);- char *_fgets64 (char *, int, __FILE *); char *_tmpnam64 (char *);#endif4/*** ISO POSIX-1 Extensions*/8#if defined(_POSIX_C_SOURCE) || !defined(_ANSI_C_SOURCE)$ int (fileno) (__FILE *__stream);= __FILE_ptr32 fdopen(int __file_desc, const char *__mode);#endif/* ** ISO POSX-2 Extensions*/ N#if _POSIX_C_SOURCE >= 2 || !defined(_ANSI_C_SOURCE) && __CRTL_VER >= 70000000B __FILE_ptr32 popen(const char *__command, const char *__mode);3# if __CRTL_VER >= 70301000 && defined(_VMS_WAIT)# ifdef __CAN_USE_EXTERN_PREFIX## pragma __e5xtern_prefix __save%# pragma __extern_prefix "__vms_"# else,# define pclose(__p1) __vms_pclose(__p1)# endif int pclose(__FILE *__stream);# ifdef __CAN_USE_EXTERN_PREFIX&# pragma __extern_prefix __restore# endif # else int pclose(__FILE *__stream); # endif#endif/*** X/Open extensions*/ 6#if defined(_XOPEN_SOURCE) || !defined(_ANSI_C_SOURCE) int getw (__FILE *__stream);/ int putw (int __integer, __FILE *__stream);M# if __CRTL_VE6R >= 70000000 /* tempnam() was introduced in OpenVMS V7.0 */ /* H ** P_tmpdir is the directory name used for tempnam(). It is defined ** by X/Open. */%# define P_tmpdir "SYS$SCRATCH:" # if __CRTL_VER >= 70301000F __char_ptr32 tempnam(const char *dir, const char *pfx, ...); # elseA __char_ptr32 tempnam(const char *dir, const char *pfx); # endif # endif#endif/* B** DEC C RTL extensions. This include explicit 64-bit inte7rfaces#** to otherwise standard routines.*/ #ifndef _ANSI_C_SOURCE## if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32 # endif7 char *fgetname(__FILE *__stream, char *__buf, ...);7# if __INITIAL_POINTER_SIZE && __CRTL_VER >= 70000000 # pragma __pointer_size 32> char *_fgetname32(__FILE *__stream, char *__buf, ...); # pragma __pointer_size 64> char *_fgetname64(__FILE *__stream, char *__buf, ...); # endifN int DECC$RECORD_RE 8AD(__FILE *__stream, void *__buffer, int __nbytes, ...);O int DECC$RECORD_WRITE(__FILE *__stream, void *__buffer, int __nbytes, ...);B int decc$read (int __file_desc, void *__buffer, int __nbytes);f# define decc$record_read(stream, buf, max_size) decc$read (((*(stream))->_file), (buf), (max_size))S# define decc$record_write(stream, buf, size) fwrite ((buf), (size), 1, (stream))! int fwait (__FILE *__stream); int lwait (int __file_desc); /* ; ** fsync is sta9ndardized by X/Open to be in  */ int fsync (int __file_desc);# endif/*1** Support code for precompiled printf functions*/5#if ((__DECC_VER > 50600000) && defined(_INTRINSICS))/# pragma intrinsic(printf, fprintf, sprintf)9# if defined(_INLINE_INTRINSICS) && __FP_OPTIMIZATIONSB static __inline int decc$__CFE_print_puts(const char *x) {# return(fputs(x,stdout)); }: static __inline int decc$__CFE_print_putc(int x) {: putc(x,stdout); return(1); }= static __inline int decc$__CFE_print_putc_nl(int x) {- putc(x,stdout); putc('\n',stdout); return(2); }R static __inline int decc$__CFE_fprint_puts_nl(const char *x, __FILE *f) { ( register int i = fputs(x,f);  putc('\n',f);  return(i+1); }F static __inline int decc$__CFE_fprint_putc(int x, __FILE *f) { putc(x,f); ; return(1); }I static __inline int decc$__CFE_fprint_putc_nl(int x, __FILE *f) {# putc(x,f); putc('\n',f); return(2); } # else3 int decc$__CFE_print_puts( const char *x );+ int decc$__CFE_print_putc( int x );. int decc$__CFE_print_putc_nl( int x );B int decc$__CFE_fprint_puts_nl( const char *x, __FILE *f );7 int decc$__CFE_fprint_putc( int x, __FILE *f );: int decc$__CFE_fprint_putc_n<l( int x, __FILE *f ); # endif#endif#if __FP_LOCKING /*O ** These functions shall provide for explicit application-level locking of K ** stdio ( FILE *) objects. These functions can be used by a thread to J ** delineate a sequence of I/O statements that are executed as a unit. */% void flockfile(__FILE *__stream);' int ftrylockfile(__FILE *__stream);( void funlockfile(__FILE *__stream);  /*D ** Versions of the file pointer functions wh =ich are functionallyI ** equivalent to the original versions, with the exception that they C ** are not required to be implemented in a thread-safe manner. L ** They may only safely be used within a scope protected by flockfile() - ** (or ftrylockfile()) and funlockfile(). */8# define clearerr_unlocked(stream) __clearerr_(stream)0# define getc_unlocked(stream) __getc_(stream)6# define getchar_unlocked(stream) __getchar_(stream)0# define feof_unlocked(stream) __feof_>(stream)4# define ferror_unlocked(stream) __ferror_(stream)0 void (clearerr_unlocked) (__FILE *__stream);0 int (getc_unlocked) (__FILE *__stream);$ int (getchar_unlocked) (void);0 int (feof_unlocked) (__FILE *__stream);0 int (ferror_unlocked) (__FILE *__stream);# ifdef __UNIX_PUTC0# define fgetc_unlocked(stream) __fgetc(stream)5# define fputc_unlocked(c, stream) __fputc(c, stream)*# define putc_unlocked(c,fp) __putc(c,fp)*# define putchar_unlocked(?c) __putchar(c)- int (fgetc_unlocked) (__FILE *__stream);6 int (fputc_unlocked) (int __c, __FILE *__stream);6 int (putc_unlocked) (int __c, __FILE *__stream);$ int (putchar_unlocked) (int __c); # endif$#endif /* X/Open file locking *//*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#pragma __standard#endif /* __@STDIO_PROCESSED */>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_STDIO_NAMES# define __USING_STDIO_NAMES using std::FILE; using std::clearerr; using std::fclose; using std::feof; using std::ferror; using std::fflush; using std::fgetc; using std::fgetpos; using std::fgets; using std::fopen; using std::fpos_t; using std::fprintf; using std::fputc; using std::fputs; A using std::fread; using std::freopen; using std::fscanf; using std::fseek; using std::fsetpos; using std::ftell; using std::fwrite; using std::getc; using std::getchar; using std::gets; using std::perror; using std::printf; using std::putc; using std::putchar; using std::puts; using std::remove; using std::rename; using std::rewind; using std::scanf; using std::setbuf; B using std::setvbuf; using std::sprintf; using std::sscanf; using std::tmpfile; using std::tmpnam; using std::ungetc; using std::vfprintf; using std::vprintf; using std::vsprintf; using std::size_t;# endif#endif#endif /* __STDIO_LOADED */ww'>ԗ#ifndef __STDLIB_LOADED#define __STDLIB_LOADED 1#ifndef __STDLIB_PROCESSED#define __STDLIB_PROCESSEDM/********************************************************* C*********************"** - General Utilities**M*****************************************************************************,** Header introduced by the ANSI C StandardM*****************************************************************************I** I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** ConDfidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. E I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herFein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/* E** X/Open specifies that WNOHANG, WUNTRACED, WEXITSTATUS, WIFEXITED,N** WIFSIGNALED, WIFSTOPPED, WSTOPSIG and WTGRERMSIG are defined here, and thatJ** inclusion of may make visible all symbols from ** and .*/ R#if defined _XOPEN_SOURCE || (!defined _ANSI_C_SOURCE && !defined _DECC_V4_SOURCE)# include # include #endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*** Member align structures*/!#pragma __member_alignment __save#pragma __member_alignment/*H** CreateH 'public' typedefs that are sensitive to pointer size and mustK** use 32 bit pointers. Create other declarations which are not sensitive** to pointer size.*/ #ifndef NULL# define NULL __NULL#endif#ifdef __NAMESPACE_STDnamespace std {#endif#ifndef __SIZE_T# define __SIZE_T 1 typedef __size_t size_t;#endiftypedef struct { int quot, rem;} div_t;typedef struct { long int quot, rem; } ldiv_t;#ifdef __NAMESPACE_STD} /* namespace std */I#endif#ifndef __WCHAR_T# define __WCHAR_T typedef __wchar_t wchar_t;#endif/* .** mode_t is needed for a DEC C RTL Extension*/ #ifndef _ANSI_C_SOURCE5# if !defined __MODE_T && !defined _DECC_V4_SOURCE# define __MODE_T 1 typedef __mode_t mode_t; # endif#endif/*** Define constant values*//*<** Exit function failure definition changes corresponding to+** V7.0 "UNIX"-like exit function behavior.*/2#if __CRTL_VER >= 70000000 && deJfined(_POSIX_EXIT)# define EXIT_FAILURE (1) #else&# define EXIT_FAILURE 0x10000002 #endif#define EXIT_SUCCESS 0!#define RAND_MAX 2147483647/*F** Beginning in OpenVMS V6.2, MB_CUR_MAX is no longer a literal value*/#if __CRTL_VER < 60200000# define MB_CUR_MAX 1#else # pragma __extern_model __save)# pragma __extern_model __strict_refdef% extern int decc$$gl___mb_cur_max;## pragma __extern_model __restore-# define MB_CUR_MAX (decc$$gl_K__mb_cur_max)#endifM/******************************************************************************2** Functions which do not support 64 bit pointers**M****************************************************************************/#ifdef __NAMESPACE_STDnamespace std {#endif/*** ANSI functions */$ int atexit(void(*__func)(void));#ifdef __NAMESPACE_STD} /* namespace std */#endif/*** X/Open functions*/4#if defined _XOPEN_SOURCE || !defined _ANSI_C_LSOURCE# if __CRTL_VER >= 70000000/ int putenv (const char *__string); # endif#endif/*** X/Open Extended functions*/W#if defined _XOPEN_SOURCE_EXTENDED || !defined _ANSI_C_SOURCE && __CRTL_VER >= 70000000 char *setstate(char *);/ char *initstate(unsigned int, char *, int);#endif/*M** We are done defining things which must always be 32 bit pointers. If theL** user has used /pointer_size=32 or /pointer_size=64, we will allow 64 bit*** poinMters to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endifM/******************************************************************************;** Functions which accept either 32 bit or 64 bit pointers**M****************************************************************************/#ifdef __NAMESPACE_STDnamespace std {#endif/*** ANSI functions */ void abort (void); int abs (int __j);+ double a Ntof (const char *__nptr);+ int atoi (const char *__nptr);+ long int atol (const char *__nptr);1 div_t div (int __numer, int __denom);$ void free (void *__ptr);% long int labs (long int __j);; ldiv_t ldiv (long int __numer, long int __denom);6 int mblen (const char *__s, __size_t __n);I __size_t mbstowcs (__wchar_t *__pwcs, const char *__s, __size_t __n);H int mbtowc (__wchar_t *__pwc, const char *__s, O__size_t __n); int rand (void);, void srand (unsigned int __seed);I __size_t wcstombs (char *__s, const __wchar_t *__pwcs, __size_t __n);5 int wctomb (char *__s, __wchar_t __wchar);2#if __CRTL_VER >= 70000000 && defined(_POSIX_EXIT)# if __CAN_USE_EXTERN_PREFIX$# pragma __extern_prefix __save(# pragma __extern_prefix "__posix_"# else&# define exit(__p1) __posix_exit(__p1)*# define system(__p1) __posix_system(__p1) # endif#endifP% void exit (int __status);- int system (const char *__string);2#if __CRTL_VER >= 70000000 && defined(_POSIX_EXIT)# if __CAN_USE_EXTERN_PREFIX'# pragma __extern_prefix __restore # endif#endif#ifdef __NAMESPACE_STD} /* namespace std */#endif/*** X/Open functions */4#if defined _XOPEN_SOURCE || !defined _ANSI_C_SOURCE# if __CRTL_VER >= 70000000 double drand48 (void);8 double erand48 (unsigned short int __xsubi[3]Q);8 long int jrand48 (unsigned short int __xsubi[3]);8 void lcong48 (unsigned short int __param[7]); long int lrand48 (void); long int mrand48 (void);8 long int nrand48 (unsigned short int __xsubi[3]);- void srand48 (long int __seedval); # endif# if __CRTL_VER >= 80300000void setkey(const char *__key);#endif#endif/*** X/Open Extended functions*/=#if defined _XOPEN_SOURCE_EXTENDED || !defined _ANSI_C_SOURCE# if __CRRTL_VER >= 70000000& int mkstemp (char *path);  long int random (void);' void srandom (unsigned int); # endif# if __CRTL_VER >= 70320000* int rand_r (unsigned int *__seed_ptr); ' __char_ptr32 l64a (long __val);3 long int a64l (__const_char_ptr64 __s);## if !defined _POSIX_C_SOURCEK int l64a_r (long int __val, __char_ptr64 __s, int __len);8# endif /* not defined while building for posix */ # enSdif#endif/*** DEC C extensions*/#ifndef _ANSI_C_SOURCE< int nice (int __increment); /* */< __mode_t umask (__mode_t __old_mask); /* */! void cfree (void *__ptr);# if !defined(__VAX)A typedef struct { __int64 quot, rem; } __qdiv_t, __lldiv_t;, __int64 atoll (const char *__nptr);, __int64 atoq (const char *__nptr);% __int64 llabs (__int64 __j);: __lldiv_t lldiv (__int64 __numer, __intT64 __denom);% __int64 qabs (__int64 __j);: __lldiv_t qdiv (__int64 __numer, __int64 __denom); # endif# if __CRTL_VER >= 70000000P int setenv (const char *__name, const char *__value, int __overwrite);* void unsetenv (const char *__name); # endif2#if __CRTL_VER >= 70000000 && defined(_POSIX_EXIT)# if __CAN_USE_EXTERN_PREFIX$# pragma __extern_prefix __save(# pragma __extern_prefix "__posix_"# else+# define _exit(__p1) __posix_U_exit(__p1) # endif#endif< void _exit (int __status); /* */2#if __CRTL_VER >= 70000000 && defined(_POSIX_EXIT)# if __CAN_USE_EXTERN_PREFIX'# pragma __extern_prefix __restore # endif#endif#endifM/******************************************************************************H** Functions which accept either 32 bit or 64 bit pointers, but always ** return 32 bit pointers.**M**************************************************V**************************/#ifdef __NAMESPACE_STDnamespace std {#endif/*** ANSI functions*/- __char_ptr32 getenv (const char *__name);#ifdef __NAMESPACE_STD} /* namespace std */#endif/*** X/Open functions*/4#if defined _XOPEN_SOURCE || !defined _ANSI_C_SOURCE# if __CRTL_VER >= 70000000B __unsigned_short_ptr32 seed48(unsigned short __seed16v[3]); # endif#endif/*** X/Open Extended functions*/=#if defined _XOPEN_SOURCE_EXTENDED || W!defined _ANSI_C_SOURCEP __char_ptr32 ecvt (double __value, int __ndigit, int *__decpt, int *__sign);P __char_ptr32 fcvt (double __value, int __ndigit, int *__decpt, int *__sign);#endif/*** DEC C extensions.*/#ifndef _ANSI_C_SOURCEB __void_ptr32 brk (unsigned long int __addr); /* */: __void_ptr32 sbrk (long int __incr); /* */#endifM/******************************************************************************G** Functions which have X separate implementations for 32 bit and 64 bitG** pointers. The implementation defaults to that corresponding to theI** default pointer size used in the /POINTER_SIZE qualifier. The 32 bitH** interface is used with no /POINTER_SIZE qualifier is present. LaterE** in this header file we will define additional function prototypesG** which allow you to call the non-default form of the implementation.**M****************************************************************************/ Y#if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*** ANSI functions*/7 void * calloc (__size_t __nmemb, __size_t __size);% void * malloc (__size_t __size);9 void * realloc (__void_ptr64 __ptr, __size_t __size);q void * bsearch (const void *, const void *, __size_t, __size_t, int (*__compar)(const void *, const void *));] void qsort (void *, __size_t, __size_t, int (*__compar)(const void *, Zconst void *));9 double strtod (const char *__nptr, char **__endptr);F long int strtol (const char *__nptr, char **__endptr, int __base);P unsigned long int strtoul (const char *__nptr, char **__endptr, int __base);#ifdef __NAMESPACE_STD} /* namespace std */#endif/*** X/Open Extended functions*/=#if defined _XOPEN_SOURCE_EXTENDED || !defined _ANSI_C_SOURCEA char * gcvt (double __value, int __ndigit, char *__buffer);% char * mktemp (char *__template);#e[ndif/*!** DEC C extensions (Alpha only)*//#if !defined(_ANSI_C_SOURCE) && !defined(__VAX)E __int64 strtoll(const char *__nptr, char **__endptr, int __base);E __int64 strtoq (const char *__nptr, char **__endptr, int __base);O unsigned __int64 strtoull(const char *__nptr, char **__endptr, int __base);O unsigned __int64 strtouq (const char *__nptr, char **__endptr, int __base);#endif/* ** realpath()** Not in ANSI standard.=** Optional parameters not in X/Open\ or Posix specifications.*/#if __CRTL_VER >=803000007# if defined _POSIX_C_SOURCE || !defined _ANSI_C_SOURCE# if defined _POSIX_C_SOURCEi char * realpath (const char * __XOPEN_RESTRICT __file_name, char * __XOPEN_RESTRICT __resolved_name);# elsen char * realpath (const char * __XOPEN_RESTRICT __file_name, char * __XOPEN_RESTRICT __resolved_name, ...);# endif # if __INITIAL_POINTER_SIZE# pragma __pointer_size 32q char * _realpath32 (const char * __XOPEN_R]ESTRICT __file_name, char * __XOPEN_RESTRICT __resolved_name, ...);# pragma __pointer_size 64q char * _realpath64 (const char * __XOPEN_RESTRICT __file_name, char * __XOPEN_RESTRICT __resolved_name, ...);# endif /* /POINTER_SIZE */# endif /* realpath() */&#endif /* __CRTL_VER >=80300000 */M/******************************************************************************I** In addition to the function prototypes above, two additional functionG** prototypes a ^re defined. These prototypes are prefixed with "_" andI** have a suffix of either "32" or "64" depending on whether you want toB** use the 32 bit pointer form or the 64 bit pointer form. TheseG** functions can be used if you have used the /POINTER_SIZE qualifier,I** and you need to explitly call either the 32 or 64 bit pointer form of** the function.**M****************************************************************************/5#if __INITIAL_POINTER_SIZE && !defined _ANSI_C_S_OURCEM /************************************************************************ ** ** 32 Bit Interfaces **M ************************************************************************/# pragma __pointer_size 32 /* ** ANSI functions */+ void * _calloc32 (__size_t, __size_t);! void * _malloc32 (__size_t);) void * _realloc32 (void *, __size_t);t void * _bsearch32 (const void *, const void *, __size_t, __size_t, int (*__compar)(con`st void *, const void *));` void _qsort32 (void *, __size_t, __size_t, int (*__compar)(const void *, const void *));. double _strtod32 (const char *, char **);4 long int _strtol32 (const char *, char **, int);> unsigned long int _strtoul32 (const char *, char **, int); /*! ** X/Open Extended functions */D char * _gcvt32 (double __value, int __ndigit, char *__buffer); char * _mktemp32 (char *); /*% ** DEC C extensions (Alpha only) a*/4 __int64 _strtoll32 (const char *, char **, int);4 __int64 _strtoq32 (const char *, char **, int);> unsigned __int64 _strtoull32 (const char *, char **, int);> unsigned __int64 _strtouq32 (const char *, char **, int); #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 64#endifM /************************************************************************ ** ** 64 Bit Interfaces **M ************************************************************b************/# pragma __pointer_size 64 /* ** ANSI functions */+ void * _calloc64 (__size_t, __size_t);! void * _malloc64 (__size_t);) void * _realloc64 (void *, __size_t);t void * _bsearch64 (const void *, const void *, __size_t, __size_t, int (*__compar)(const void *, const void *));` void _qsort64 (void *, __size_t, __size_t, int (*__compar)(const void *, const void *));. double _strtod64 (const char *, char **);4 long int _strtol64 (cconst char *, char **, int);> unsigned long int _strtoul64 (const char *, char **, int); /*! ** X/Open Extended functions */D char * _gcvt64 (double __value, int __ndigit, char *__buffer); char * _mktemp64 (char *); /*% ** DEC C extensions (Alpha only) */4 __int64 _strtoll64 (const char *, char **, int);4 __int64 _strtoq64 (const char *, char **, int);> unsigned __int64 _strtoull64 (const char *, char **, int);> unsigned __int64 _dstrtouq64 (const char *, char **, int);#endif/*** DEC C Performance**F** Certain DEC C functions are available as compiler builtins. UsingD** the builtins offer performance improvements and are enabled here0** for all programs including this header file.*/&#if !defined(__VAX) && defined(__DECC) int __ABS (int __j);# long int __LABS (long int __j);# define abs(__x) __ABS(__x) # define labs(__x) __LABS(__x)#endif/*%** Restore the users pointer conteext*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#pragma __standard#endif /* __STDLIB_PROCESSED */>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_STDLIB_NAMES # define __USING_STDLIB_NAMES using std::abort; using std::abs; using std::atexit; using std::atof; using std::atoi; using std::atol; using sftd::bsearch; using std::calloc; using std::div; using std::div_t; using std::exit; using std::free; using std::getenv; using std::labs; using std::ldiv; using std::ldiv_t; using std::malloc; using std::mblen; using std::mbstowcs; using std::mbtowc; using std::qsort; using std::rand; using std::realloc; using std::size_t; using std::srand; using std::strtod; using std::stgrtol; using std::strtoul; using std::system; using std::wcstombs; using std::wctomb;# endif#endif#endif /* __STDLIB_LOADED */ww>ԗ#ifndef __STRING_LOADED#define __STRING_LOADED 1#ifndef __STRING_PROCESSED#define __STRING_PROCESSEDM/****************************************************************************** ** - String Handling**M*****************************************************************************,h** Header introduced by the ANSI C StandardM*****************************************************************************I** I** Copyright 2006 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. Ii** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall bej liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** k M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*N** Create 'public' typedefs, structure definitions, and definitions which areM** in this header file which lare either not sensitive to pointer size or are"** required to be short pointers.*/#ifndef __SIZE_T# define __SIZE_T 1 typedef __size_t size_t;#endif#ifdef __NAMESPACE_STD} /* namespace std */#endif #ifndef NULL# define NULL __NULL#endif/*L** At this point in the processing, we are done defining those things whichJ** must always be short pointers. If the user has used the /pointer_sizeG** qualifier, we will allow long pointers to be used in function camllsE** regardless of whether they have specified short or long pointers.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*O** The following functions have interfaces of XXX, _XXX32, and _XXX64 due onlyM** to the fact that the return argument is a pointer that is relative to one** of the arguments.*/ #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 32#endif#ifdef __NAMESPACE_STDnamespace std {#endif7void *memchr (const void *__s, int n__c, __size_t __n);Bvoid *memcpy (void *__s1, __const_void_ptr64 __s2, __size_t __n);Bvoid *memmove (void *__s1, __const_void_ptr64 __s2, __size_t __n);1void *memset (void *__s, int __c, __size_t __n);4char *strcat (char *__s1, __const_char_ptr64 __s2);)char *strchr (const char *__s, int __c);4char *strcpy (char *__s1, __const_char_ptr64 __s2);Bchar *strncat (char *__s1, __const_char_ptr64 __s2, __size_t __n);Bchar *strncpy (char *__s1, __const_char_ptr64 __s2, __size_t __n);:char *storpbrk (const char *__s1, __const_char_ptr64 __s2);)char *strrchr (const char *__s, int __c);:char *strstr (const char *__s1, __const_char_ptr64 __s2);4char *strtok (char *__s1, __const_char_ptr64 __s2);#ifdef __NAMESPACE_STD} /* namespace std */#endif #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 64#endifO#if __INITIAL_POINTER_SIZE && !defined _ANSI_C_SOURCE && __CRTL_VER >= 70000000# pragma __pointer_size 32> void *_memchr32 (const void *__s, int __c, __si pze_t __n);I void *_memcpy32 (void *__s1, __const_void_ptr64 __s2, __size_t __n);I void *_memmove32 (void *__s1, __const_void_ptr64 __s2, __size_t __n);8 void *_memset32 (void *__s, int __c, __size_t __n);; char *_strcat32 (char *__s1, __const_char_ptr64 __s2);0 char *_strchr32 (const char *__s, int __c);; char *_strcpy32 (char *__s1, __const_char_ptr64 __s2);I char *_strncat32 (char *__s1, __const_char_ptr64 __s2, __size_t __n);I char *_strncpy32 (char *__s1, q__const_char_ptr64 __s2, __size_t __n);A char *_strpbrk32 (const char *__s1, __const_char_ptr64 __s2);0 char *_strrchr32 (const char *__s, int __c);A char *_strstr32 (const char *__s1, __const_char_ptr64 __s2);; char *_strtok32 (char *__s1, __const_char_ptr64 __s2);# pragma __pointer_size 64> void *_memchr64 (const void *__s, int __c, __size_t __n);B void *_memcpy64 (void *__s1, const void *__s2, __size_t __n);B void *_memmove64 (void *__s1, const void *__s2, r__size_t __n);8 void *_memset64 (void *__s, int __c, __size_t __n);4 char *_strcat64 (char *__s1, const char *__s2);0 char *_strchr64 (const char *__s, int __c);4 char *_strcpy64 (char *__s1, const char *__s2);B char *_strncat64 (char *__s1, const char *__s2, __size_t __n);B char *_strncpy64 (char *__s1, const char *__s2, __size_t __n);: char *_strpbrk64 (const char *__s1, const char *__s2);0 char *_strrchr64 (const char *__s, int __c);: char *_strstr64 (const schar *__s1, const char *__s2);4 char *_strtok64 (char *__s1, const char *__s2);#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*J** The following functions have only a single interface regardless of theI** pointer size in effect. The parameters can accept both 32 bit and 64** bit addresses.*/Bint memcmp (const void *__s1, const void *__s2, __size_t __n);4int strcmp (const char *__s1, const char *__s2);4int strcoll (const char *__s1, const char *__s2);Btint strncmp (const char *__s1, const char *__s2, __size_t __n);6__size_t strcspn (const char *__s1, const char *__s2);#__size_t strlen (const char *__s);6__size_t strspn (const char *__s1, const char *__s2);>__size_t strxfrm (char *__s1, const char *__s2, __size_t __n);#ifdef __NAMESPACE_STD} /* namespace std */#endif5#if !defined _ANSI_C_SOURCE && __CRTL_VER >= 602000001__size_t strnlen (const char *__s, __size_t __n);#endif/*H** The following function has a differeunt prototype based on whether or=** not we are compiling in strict ANSI C compatibility mode.*/#ifdef __NAMESPACE_STDnamespace std {#endif#if defined _ANSI_C_SOURCE( __char_ptr32 strerror(int __errnum);#else- __char_ptr32 strerror(int __errnum, ...);#endif#ifdef __NAMESPACE_STD} /* namespace std */#endif/* ** X/Open extensions*/ 4#if defined _XOPEN_SOURCE || !defined _ANSI_C_SOURCE## if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32v # endif# if __CRTL_VER >= 70000000= void *memccpy(void *, __const_void_ptr64, int, __size_t); # endif#endif/* ** X/Open extended*/ =#if defined _XOPEN_SOURCE_EXTENDED || !defined _ANSI_C_SOURCE## if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32 # endif# if __CRTL_VER >= 70000000% char *strdup(__const_char_ptr64); # endif# if __CRTL_VER >= 70301000F char *strtok_r(char *__s, __const_char_ptr64 __sep, char **lasts);w # endif#endif/* G** BSD 4.4 extensions. strsep is specified by BSD 4.4 but not X/OpenA** There is not currently a feature test macro defined for BSD44*/ 5#if !defined _ANSI_C_SOURCE && __CRTL_VER >= 70000000## if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32 # endif. char *strsep(char **, __const_char_ptr64);# if __INITIAL_POINTER_SIZE # pragma __pointer_size 32. char *_strsep32(char **, __const_char_ptr64); # pragma __pxointer_size 64( char *_strsep64(char **, const char *);# endif#endif/*** DEC C ExtensionsF** X/Open extended specifies that bcmp, bcopy, bzero, ffs, strcasecmp7** strncasecmp, index and rindex appear in .L** X/Open extended specifies that basename and dirname appear in */5#if !defined _ANSI_C_SOURCE && __CRTL_VER >= 70000000## if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 64 # endifD int bcmp (const void * __s1, const void y* __s2, __size_t __n);@ void (bcopy) (const void * __s1, void * __s2, __size_t __n);- void (bzero) (void * __s1, __size_t __n); int ffs (int);0 int strcasecmp(const char *, const char *);; int strncasecmp(const char *, const char *, __size_t);## if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32 # endif# char *index(const char *, int);$ char *rindex(const char *, int); char *basename(char *); char *dirname(char *);# if __IzNITIAL_POINTER_SIZE # pragma __pointer_size 32, char *_strdup32(__const_char_ptr64);= void *_memccpy32(void *, __const_void_ptr64, int, __size_t); char *_basename32(char *); char *_dirname32(char *);# char *_index32(const char *, int);$ char *_rindex32(const char *, int);# if __CRTL_VER >= 70301000G char *_strtok_r32 (char *__s, __const_char_ptr64 __sep, char **lasts);# endif # pragma __pointer_size 64& char *_strdup64(const char *);7 void *_memccp{y64(void *, const void *, int, __size_t); char *_basename64(char *); char *_dirname64(char *);# char *_index64(const char *, int);$ char *_rindex64(const char *, int);# if __CRTL_VER >= 70301000G char *_strtok_r64 (char *__s, __const_char_ptr64 __sep, char **lasts);# endif # endif#endif/* ** DEC C Performance (Builtins)**F** Certain DEC C functions are available as compiler builtins. UsingD** the builtins offer performance improvements and are enabled here0**| for all programs including this header file.**K** In a 64 bit OpenVMS environment, the builtins accept and return 64 bit ,** pointers. We will explicitly use casts */#if !defined(__VAX) #if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32#endif# if __DECCXX_VER >= 60590046J void * __MEMCPY (void *__s1, __const_void_ptr64 __s2, __size_t __n);I void * __MEMMOVE (void *__s1, __const_void_ptr64 __s2, __size_t __n);#elseC void * __MEMCPY (void *__s1, const } void *__s2, __size_t __n);B void * __MEMMOVE (void *__s1, const void *__s2, __size_t __n);#endif8 void * __MEMSET (void *__s, int __c, __size_t __n);# if (__DECC_VER > 50600000)) __size_t __STRLEN (const char *__s);4 char * __STRCPY (char *__s1, const char *__s2); # endif#ifndef __NAMESPACE_STD8# define memcpy(__x, __y, __z) __MEMCPY(__x, __y, __z):# define memmove(__x, __y, __z) __MEMMOVE(__x, __y, __z)8# define memset(__x, __y, __z) __MEMSET(__x, __y, __~z)#endif# if (__DECC_VER > 50600000)$# define strlen(__x) __STRLEN(__x).# define strcpy(__x, __y) __STRCPY(__x, __y) # endifY# if !defined _ANSI_C_SOURCE && __CRTL_VER >= 70000000 /* BSD byte string extensions */7# define bcopy(__x, __y, __z) __MEMMOVE(__y, __x, __z) /# define bzero(__x, __y) __MEMSET(__x, 0, __y) # endif #if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 64#endif#endif/*$** DEC C RTL Performance (Linkages)**B** Certain DEC C RTL functions are defined with linkages declaredE** which gives the compiler more information as to register usage in** the implementation.*/'#if defined(__ALPHA) && defined(__DECC)%# pragma __linkage __str_link1 = (\L __notused(__r1,__r2,__r3,__r4,__r5,__r6,__r7,__r8,__r9,__r10,__r11,\O __r12,__r13,__r14,__r15,__r17,__r18,__r19,__r20,__r21,__r22,\+ __r23,__r24,__r25,__r29,\K __f0,__f1,__f2,__f3,__f4,__f5,__f6,__f7,__f8,__f9,__ f10,\O __f11,__f12,__f13,__f14,__f15,__f16,__f17,__f18,__f19,__f20,\P __f21,__f22,__f23,__f24,__f25,__f26,__f27,__f28,__f29,__f30),\ __notneeded(__ai))%# pragma __linkage __str_link2 = (\L __notused(__r1,__r2,__r3,__r4,__r5,__r6,__r7,__r8,__r9,__r10,__r11,\I __r12,__r13,__r14,__r15,__r22,__r23,__r24,__r25,__r29,\K __f0,__f1,__f2,__f3,__f4,__f5,__f6,__f7,__f8,__f9,__f10,\O __f11,__f12,__f1 3,__f14,__f15,__f16,__f17,__f18,__f19,__f20,\P __f21,__f22,__f23,__f24,__f25,__f26,__f27,__f28,__f29,__f30),\ __notneeded(__ai))%# pragma __linkage __str_link3 = (\M __notused(__r2,__r3,__r4,__r5,__r6,__r7,__r8,__r9,__r10,__r11,__r12,\O __r13,__r14,__r15,__r18,__r19,__r20,__r21,__r22,__r23,__r24,\ __r25,__r29,\K __f0,__f1,__f2,__f3,__f4,__f5,__f6,__f7,__f8,__f9,__f10,\O __f11,__f12,__f1 3,__f14,__f15,__f16,__f17,__f18,__f19,__f20,\P __f21,__f22,__f23,__f24,__f25,__f26,__f27,__f28,__f29,__f30),\ __notneeded(__ai))# if (__DECC_VER > 50600000)0# pragma __use_linkage __str_link2 (strcmp)1# pragma __use_linkage __str_link3 (strnlen)# else0# pragma __use_linkage __str_link1 (strlen)8# pragma __use_linkage __str_link2 (strcpy, strcmp)1# pragma __use_linkage __str_link3 (strnlen) # endif(#elif defined(__ia64) && defined(__DECC)/*I** Should define "similar" linkages for ia64, but they cannot be exactly<** the same because the register conventions are different.** ***TBD for ia64****/#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __STRING_PROCESSED */>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_STRING_NAMES # define __USING_STRING_NAMES using std::memchr; using std::memcmp; using std::memcpy; using std::memmove; using std::memset; using std::size_t; using std::strcat; using std::strchr; using std::strcmp; using std::strcoll; using std::strcpy; using std::strcspn; using std::strerror; using std::strlen; using std::strncat; using std::strncmp; using std::strncpy; using std::strpbrk; using std::strrchr; using std::strspn; using std::strstr; using std::strtok; using std::strxfrm;# endif#endif#endif /* __STRING_LOADED */ww*#?ԗ#ifndef __STRINGS_LOADED#define __STRINGS_LOADED 1#pragma __nostandard#include E#if __CRTL_VER >= 70000000 /* Supported beginning in OpenVMS V7.0 */M/******************************************************************************!** - String Handling**M*****************************************************************************I** Header introduced by the X/Open CAE Specification, Issue 4, Version 2M*****************************************************************************I** I** Copyright 2006 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I**  I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endif/*N** Create 'public' typedefs, structure definitions, and definitions which areM** in this header file which are either not sensitive to pointer size or are"** required to be short pointers.*/#ifndef __SIZE_T# define __SIZE_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __size_t size_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::size_t;#endif#endif/*B** X/Open extended definitions which accept 32 or 64 bit pointers*/@int bcmp (const void * __s1, const void * __s2, __size_t __n);<void (bcopy) (const void * __s1, void * __s2, __size_t __n);)void (bzero) (void * __s1, __size_t __n);int ffs (int);.int strcasecmp (const char *, const char *);8int strncasecmp (const char *, const char *, __size_t);/*O** The following functions have interfaces of XXX, _XXX32, and _XXX64 due onlyM** to the fact that the return argument is a pointer that is relative to one** of the arguments.*/ #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 32#endif!char *index (const char *, int);!char *rindex (const char *, int); #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 64#endif/* 7** DEC C extensions (64-bit interfaces are extensions)*/ =#if __INITIAL_POINTER_SIZE && !defined _XOPEN_SOURCE_EXTENDED# pragma __pointer_size 32( char *_index32 (const char *, int);( char *_rindex32 (const char *, int);# pragma __pointer_size 64( char *_index64 (const char *, int);( char *_rindex64 (const char *, int);#endif/* ** DEC C Performance (Builtins)**F** Certain DEC C functions are available as compiler builtins. UsingD** the builtins offer performance improvements and are enabled here0** for all programs including this header file.*/#if !defined(__VAX)## if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32 # endif# if __DECCXX_VER >= 60590046H void *__MEMMOVE (void *__s1, __const_void_ptr64 __s2, __size_t __n);#elseA void *__MEMMOVE (void *__s1, const void *__s2, __size_t __n);#endif7 void *__MEMSET (void *__s, int __c, __size_t __n);9# define bcopy(__x, __y, __z) __MEMMOVE(__y, __x, __z) 6# define bzero(__x, __y) __MEMSET(__x, 0, __y) #endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE ## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#endif /* OpenVMS V7.0 */#pragma __standard#endif /* __STRINGS_LOADED */wwOI?ԗ#ifndef __STROPTS_LOADED#define __STROPTS_LOADEDM/***** *************************************************************************#** - STREAMS interface**M*****************************************************************************I** Header introduced by the X/Open CAE Specification, Issue 4, Version 2M*****************************************************************************I** I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in th e express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M*******************************************************************************&** Based on header available through:**E** Copyright (c) 1982, 1994 Regents of the University of California.A** All rights reserved. The Berkeley software License Agreement:** specifies the terms and conditions for redistribution.**/** ioctl.h 8.6 (Berkeley) 3/28/94**N*******************************************************************************/ #pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#include #include #include #if !defined(__VMS)?# if !defined(_XOPEN_SOURCE_EXTENDED) || defined(_OSF_SOURCE)"# include # endif#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*I** The OpenVMS V7.0 release added a second implementation of the socket F** functions which is compatible with BSD 4.4. Define a local to be C** used throughout the remaining header file which reflects which !** implementation is being used.**I** An application program enables this support by defining _SOCKADDR_LEN(** prior to including this header file.*/#ifdef _SOCKADDR_LEN# if (__CRTL_VER < 70000000)H# error " BSD 4.4 Socket package not available before OpenVMS V7.0"# undef _SOCKADDR_LEN # endif#endif/*7** Set __nomember_alignment to avoid internal and tail2** padding in structures; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment/*4** External names follow the "relaxed_refdef" model*/#pragma __extern_model __save'#pragma __extern_model __relaxed_refdef/*** Define Page Size*/#if defined(__VAX)# define NBPG 512#else# define NBPG 8192#endif/*F** Window/terminal size structure. This information is stored by theF** kernel in order to provide a consistent interface, but is not used** by the kernel.*/<#if !defined(_XOPEN_SOURCE_EXTENDED) || defined(_OSF_SOURCE) struct winsize {2 unsigned short ws_row; /* rows, in characters */5 unsigned short ws_col; /* columns, in characters */8 unsigned short ws_xpixel; /* horizontal size, pixels */6 unsigned short ws_ypixel; /* vertical size, pixels */ }; /* ** Pun for SUN. */ struct ttysize { unsigned short ts_lines; unsigned short ts_cols; unsigned short ts_xxx; unsigned short ts_yyy; };# define TIOCGSIZE TIOCGWINSZ# define TIOCSSIZE TIOCSWINSZ#endif/*G** Ioctl's have the command encoded in the lower word, and the size ofG** any in or out parameters in the upper word. The high 3 bits of theE** upper word are used to encode the in/out status of the parameter.*/O#define IOCPARM_MASK 0x1fff /* parameter length, at most 13 bits */4#define IOCPARM_LEN(x) (((x) >> 16) & IOCPARM_MASK)+#define IOCBASECMD(x) ((x) & ~IOCPARM_MASK)+#define IOCGROUP(x) (((x) >> 8) & 0xff)N#define IOCPARM_MAX NBPG /* max size of ioctl, mult. of NBPG */;#define IOC_VOID 0x20 000000 /* no parameters */A#define IOC_OUT 0x40000000 /* copy out parameters */@#define IOC_IN 0x80000000 /* copy in parameters */(#define IOC_INOUT (IOC_IN|IOC_OUT)B#define IOC_DIRMASK 0xe0000000 /* mask for IN/OUT/VOID */0#define _IOC_VOID 0x20000000 /* no parameters */5#define _IOC_OUT 0x40000000 /* copy out parameters */4#define _IOC_IN 0x80000000 /* copy in parameters */%#define _IOC_INOUT (_IOC_IN|_IOC_OUT):#define _IOC_DIRMASK 0xe0000000 /* mask for IN/OUT/VOID */##define _IOC(inout,group,num,len) \G (inout | ((len & IOCPARM_MASK) << 16) | ((group) << 8) | (num))4#define _IO(g,n) _IOC(IOC_VOID, (g), (n), 0)<#define _IOR(g,n,t) _IOC(IOC_OUT, (g), (n), sizeof(t))<#define _IOW(g,n,t) _IOC(IOC_IN, (g), (n), sizeof(t))5/* this should be _IORW, but stdio got there first */<#define _IOWR(g,n,t) _IOC(IOC_INOUT, (g), (n), sizeof(t))/*** For terminal drivers*/@#define TIOCMODG _IOR('t ', 3, int) /* get modem control state */@#define TIOCMODS _IOW('t', 4, int) /* set modem control state */(#define TIOCM_LE 0001 /* line enable */1#define TIOCM_DTR 0002 /* data terminal ready */-#define TIOCM_RTS 0004 /* request to send *//#define TIOCM_ST 0010 /* secondary transmit */.#define TIOCM_SR 0020 /* secondary receive */+#define TIOCM_CTS 0040 /* clear to send */,#define TIOCM_CAR 0100 /* carrier detect */#define TIOCM_CD TIOCM_CAR"#define TIOCM_RNG 0200 /* ring */#d efine TIOCM_RI TIOCM_RNG,#define TIOCM_DSR 0400 /* data set ready */ /* 8-10 compat */<#define TIOCEXCL _IO('t', 13) /* set exclusive use of tty */>#define TIOCNXCL _IO('t', 14) /* reset exclusive use of tty */ /* 15 unused */8#define TIOCFLUSH _IOW('t', 16, int) /* flush buffers */ /* 17-18 compat */G#define TIOCGETA _IOR('t', 19, struct termios) /* get termios struct */G#define TIOCSETA _IOW('t', 20, struct termios) /* set termios struct */G#define TIOCSETAW _IOW('t', 21 , struct termios) /* drain output, set */J#define TIOCSETAF _IOW('t', 22, struct termios) /* drn out, fls in, set *//*** System V terminal ioctls*/ #define TCGETS TIOCGETA #define TCSETS TIOCSETA!#define TCSETSW TIOCSETAW!#define TCSETSF TIOCSETAFK#define TCGETA _IOR('t', 23, struct termio) /* get termio struct */K#define TCSETA _IOW('t', 24, struct termio) /* set termio struct */L#define TCSETAW _IOW('t', 25, struct termio) /* drain output, set */M#define TCSETAF _IOW('t', 28, struct termio) /* drn out, flsh, set */6#define TCSBREAK _IO('t', 29) /* Send break */ #define TCSBRK TCSBREAK<#define TCXONC _IO('t', 30) /* Set flow control */7#define TCFLSH _IO('t', 31) /* Flush queue */=#define TIOCGETD _IOR('t', 26, int) /* get line discipline */=#define TIOCSETD _IOW('t', 27, int) /* set line discipline *//*** locals, from 127 down*/3#define TIOCSBRK _ IO('t', 123) /* set break bit */5#define TIOCCBRK _IO('t', 122) /* clear break bit */=#define TIOCSDTR _IO('t', 121) /* set data terminal ready */?#define TIOCCDTR _IO('t', 120) /* clear data terminal ready */=#define TIOCGPGRP _IOR('t', 119, pid_t) /* get pgrp of tty */=#define TIOCSPGRP _IOW('t', 118, pid_t) /* set pgrp of tty */ /* 117-116 compat */<#define TIOCOUTQ _IOR('t', 115, int) /* output queue size */C#define TIOCSTI _IOW('t', 114, char) /* simulate terminal input * /;#define TIOCNOTTY _IO('t', 113) /* void tty association */E#define TIOCPKT _IOW('t', 112, int) /* pty: set/clear packet mode */,#define TIOCPKT_DATA 0x00 /* data packet */1#define TIOCPKT_FLUSHREAD 0x01 /* flush packet */2#define TIOCPKT_FLUSHWRITE 0x02 /* flush packet */,#define TIOCPKT_STOP 0x04 /* stop output */.#define TIOCPKT_START 0x08 /* start output */1#define TIOCPKT_NOSTOP 0x10 /* no more ^S, ^Q *//#define TIOCPKT_DOSTOP 0x20 /* now do ^S ^Q */:#define TIOCSTOP _IO ('t', 111) /* stop output, like ^S */<#define TIOCSTART _IO('t', 110) /* start output, like ^Q */=#define TIOCMSET _IOW('t', 109, int) /* set all modem bits */9#define TIOCMBIS _IOW('t', 108, int) /* bis modem bits */9#define TIOCMBIC _IOW('t', 107, int) /* bic modem bits */=#define TIOCMGET _IOR('t', 106, int) /* get all modem bits */A#define TIOCREMOTE _IOW('t', 105, int) /* remote input editing */G#define TIOCGWINSZ _IOR('t', 104, struct winsize) /* get window size */G#define TIOCSWINSZ _IOW('t', 103, struct winsize) /* set window size */F#define TIOCUCNTL _IOW('t', 102, int) /* pty: set/clr usr cntl mode */5#define UIOCCMD(n) _IO('u', n) /* usr cntl op "n" */A#define TIOCCONS _IOW('t', 98, int) /* become virtual console */<#define TIOCSCTTY _IO('t', 97) /* become controlling tty */B#define TIOCEXT _IOW('t', 96, int) /* pty: external processing */9#define TIOCSIG _IO('t', 95) /* pty: generate signal */D#define TIOCISATTY _IO('t', 94) /* is this a tty? *//*!** SLIP (Serial Line IP) ioctl's*/?#define SLIOGUNIT _IOR('t', 88, int) /* get slip unit number */D#define SLIOCSFLAGS _IOW('t', 89, int) /* set configuration flags */D#define SLIOCGFLAGS _IOR('t', 90, int) /* get configuration flags */5#define TTYDISC 0 /* termios tty line discipline */+#define TABLDISC 3 /* tablet discipline */.#define SLIPDISC 4 /* serial IP discipline */-#define DUDISC 7 /* Dialup IP discipline */H#define KJIDISC 8 /* Kanji Shift JIS discipline */M#define ASYDISC 9 /* Asian multibyte line discipline */N#define TSBDISC 10 /* I18N single-byte line discipline */J#define KDBDISC 11 /* debug filter line discipline *//*6** Macros for determining Asian/I18N line disciplines*/1#define IS_ASY_LINE(tp) ((tp)->t_line == ASYDISC)1#define IS_TSB_LINE(tp) ((tp)->t_line == TSBDISC)/*** SYS V RELEASE 4 PTY IOCTL*/9#define ISPTM  _IO('t',71) /* get dev_t */F#define UNLKPT _IO('t',73) /* unlock slave pty */P#define ISPTS _IO('t',74) /* ret. maj+min of pty master */8#define TIOCGSID _IOR('t', 72, int) /* get sid of tty */;#define FIOCLEX _IO('f', 1) /* set close on exec on fd */8#define FIONCLEX _IO('f', 2) /* remove close on exec */F#define FIONREAD _IOR('f', 127, int) /* get number of bytes to read */E#define FIONBIO _IOW('f', 126, int) /* set/clear non-blocki ng i/o */>#define FIOASYNC _IOW('f', 125, int) /* set/clear async i/o */5#define FIOSETOWN _IOW('f', 124, int) /* set owner */5#define FIOGETOWN _IOR('f', 123, int) /* get owner */L#define FIOPIPESTAT _IOR('f', 122, struct stat) /* pipe|fifo stat */G#define FIOFATTACH _IOW('f', 121, void *) /* internal: fattach */G#define FIOFDETACH _IOW('f', 120, void *) /* internal: fdetach *//* ** Socket ioctl's. */U#define SIOCCHILDNBIO _IOW('s', 94, int) /* set/c lear the inherit nbio flag */]#define SIOCWIRE _IOW('s', 95, int) /* set/clear the wire all pages(send only) */A#define SIOCSHIWAT _IOW('s', 0, int) /* set high watermark */A#define SIOCGHIWAT _IOR('s', 1, int) /* get high watermark */A#define SIOCSLOWAT _IOW('s', 2, int) /* set low watermark */A#define SIOCGLOWAT _IOR('s', 3, int) /* get low watermark */A#define SIOCATMARK _IOR('s', 7, int) /* at oob mark? */C#define SIOCSPGRP _IOW('s', 8, __p id_t) /* set process group */C#define SIOCGPGRP _IOR('s', 9, __pid_t) /* get process group */ #if SEC_ARCH>#define SIOCGPEERPRIV _IOR('s', 10, int) /* get peer privs */#endif@#define SIOCADDRT _IOW('r', 10, struct ortentry) /* add route */C#define SIOCDELRT _IOW('r', 11, struct ortentry) /* delete route */J#define SIOCSIFADDR _IOW('i', 12, struct ifreq) /* set ifnet address */H#define SIOCSIFDSTADDR _IOW('i', 14, struct ifreq) /* set p-p address */H#define SIOCSIFFLAGS _IOW('i', 16, struct ifreq) /* set ifnet flags */H#define SIOCGIFFLAGS _IOWR('i',17, struct ifreq) /* get ifnet flags */K#define SIOCSIFBRDADDR _IOW('i', 19, struct ifreq) /* set broadcast addr */J#define SIOCSIFNETMASK _IOW('i', 22, struct ifreq) /* set net addr mask */F#define SIOCGIFMETRIC _IOWR('i',23, struct ifreq) /* get IF metric */F#define SIOCSIFMETRIC _IOW('i', 24, struct ifreq) /* set IF metric */G#define SIOCDIFADDR _IOW('i', 25, struct ifreq) /* delete IF addr */M#define SIOCAIFADDR _IOW('i', 26, struct ifaliasreq)/* add/chg IF alias */G#define SIOCRDZCTRS _IOWR('i', 27, struct ctrreq) /* Read counter */G#define SIOCRDCTRS _IOWR('i', 28, struct ctrreq) /* Read counter */M#define SIOCPIFADDR _IOW('i', 29, struct ifaliasreq)/* set primary addr */J#define SIOCSARP _IOW('i', 30, struct arpreq) /* set arp entry */M#define SIOCDARP _IOW('i', 32, struct arpreq) /* delete arp entry */O#define OSIOCARPREQ _IOWR('i', 40, struct ifreq)  /* old arp request pkt*/L#define SIOCARPREQ _IOWR('i',40, struct ifreq) /* arp request pkt */V#define OSIOCAARPREQ _IOWR('i', 41, struct ifreq) /* old alias arp request pkt */R#define SIOCAARPREQ _IOWR('i', 41, struct arpreq) /* alias arp request pkt */[#define OSIOCGARPREQ _IOWR('i', 42, struct ifreq) /* old gratuitous arp request pkt */W#define SIOCGARPREQ _IOWR('i', 42, struct arpreq) /* gratuitous arp request pkt */L#define SIOCDISARPREQ _IOWR('i', 43, stru ct arpreq) /* disable arp req */K#define SIOCENAARPREQ _IOWR('i', 44, struct arpreq) /* enable arp req */J#define SIOCMANREQ _IOWR('i',45, struct ifdata) /* mgmt request */ H#define SIOCGETEVENTS _IOWR('i',46, struct ifdata) /* event notif */L#define SIOCIFRESET _IOW('i',47, struct ifreq) /* Reset interface */I#define SIOCEEUPDATE _IOW('i',48, struct ifeeprom) /* Write EEPROM */H#define SIOCADDMULTI _IOW('i', 49, struct ifreq) /* add m'cast addr */H#define SIOCDELMULTI _IOW('i', 50, struct ifreq) /* del m'cast addr */O#define SIOCGETVIFCNT _IOWR('r', 54, struct sioc_vif_req)/* get vif pkt cnt */O#define SIOCGETSGCNT _IOWR('r', 55, struct sioc_sg_req) /* get s,g pkt cnt */ #if SEC_NETG#define SIOCGIFNET _IOWR('i', 56, struct ifreq) /* get ifnet struct */I#define SIOCSIFNET _IOW('i', 57, struct ifreq) /* set ifnet struct */#endif/*#** Set/get interface access filter*/H#define SIOCSIFAFILT _IOW('i', 58, struct ifafiltre q)/* set filter */I#define SIOCGIFAFILT _IOWR('i', 59, struct ifafiltreq)/* get filter *//*'** Added by choosing arbitrary numbers*/M#define SIOCENABLBACK _IOW('i', 60, struct ifreq) /* Enable loopback */N#define SIOCDISABLBACK _IOW('i', 61, struct ifreq) /* Disable loopback */L#define SIOCRPHYSADDR _IOWR('i', 62, struct ifdevea) /* Read Phys addr */F#define SIOCSPHYSADDR _IOWR('i', 63, struct ifdevea) /* Set addr */P#define SIOCIFSETCHAR _IOWR('i', 64, struct ifchar) /* Set characteristic */K#define SIOCSMACSPEED _IOW('i', 65, struct ifreq) /* Set MAC speed */L#define SIOCRMACSPEED _IOWR('i', 66, struct ifreq) /* Read MAC speed */N#define SIOCSIPMTU _IOW('i', 67, struct ifreq) /* Set intf. IP MTU */O#define SIOCRIPMTU _IOWR('i', 68, struct ifreq) /* Read intf. IP MTU */J#define SIOCGIFINDEX _IOWR('i', 69, struct ifreq) /* get IF index *//*** Source Routing ioctl*/E#define SIOCSRREQR _IOWR('i', 70, st ruct srreq) /* SR read request */F#define SIOCSRREQW _IOWR('i', 71, struct srreq) /* SR write request */*/* Network Redundant Adapters (NetRAIN) */M#define SIOCIFADD _IOWR('i', 72, struct if_nrset) /* Attach adapter */M#define SIOCIFSWITCH _IOWR('i', 73, struct ifreq) /* Switch adapters */L#define SIOCIFREMOVE _IOWR('i', 74, struct ifreq) /* Remove adapter */T#define SIOCIFNRTIMERS _IOWR('i', 75, mif_t) /* modify timers for NIFF */Y#define SIOCGNRSET _IOW R('i', 76, struct if_nrset) /* Get list of netrain members */W#define SIOCIFAUTOFAIL _IOWR('i', 77, struct ifreq) /* Enable auto failover mode */5/* Set/get interface trustgrp for FIREWALL product */M#define SIOCSIFTRUSTGRP _IOW('i', 85, struct ifreq) /* Set if_trustgrp */M#define SIOCGIFTRUSTGRP _IOWR('i', 85, struct ifreq) /* Get if_trustgrp *//* * IPv6 ioctls0 * See netinet/in6.h for struct defn of ip6ifreq */M#define SIOCIPV6NDNA _IOWR('i', 243, struct ip6ifreq) /* send neighborP advertisement */Z#define SIOCIPV6ADDHOMEPREFIX _IOWR('i',244, struct ip6ifreq)/* MIPv6 - Add Home Prefix */]#define SIOCIPV6REMHOMEPREFIX _IOWR('i',245, struct ip6ifreq)/* MIPv6 - Remove Home Prefix */H#define SIOCIPV6GIFADDR _IOWR('i', 246, struct ip6ifreq) /* get IPv6L * addr opts */M#define SIOCIPV6ADDROUT _IOWR('i', 247, struct ip6ifreq)  /* add LLADDR */L#define SIOCIPV6DELGATE _IOWR('i', 248, struct ip6ifreq) /* flush routesL * through gate@ */N#define SIOCIPV6IFUNINIT _IOWR('i', 249, struct ip6ifreq) /* uninit IPv6 */O#define SIOCIPV6IFINIT _IOWR('i', 250, struct ip6ifreq) /* init if IPv6 */N#define SIOCIPV6AIFADDR _IOWR('i', 251, struct ip6ifreq) /* add if IPv6 */K#define SIOCIPV6SIFATT R _IOW ('i', 252, struct ip6ifreq) /* set IPv6 ifM * attributes */L#define SIOCIPV6DIFADDR _IOWR ('i', 253, struct ip6ifreq) /* del if IPv6N * global addr */Y#define SIOCIPV6GIFATTR _IOWR('i', 254, struct ip6ifreq) /* get IPv6 if attributes */V#define SIOCIPV6MIFADDR _IOWR('i', 255, struct ip6ifreq) /* mdfy IPv6 addr opts *//*3** IP traffic control ( Integrated Services) ioctls3** See ip_tcntl.h for definition of structs below.*/J#define SIOCFLOWSPEC _IOWR('i', 86, struct flowreq) /* flowspec request */J#define SIOCFILTSPEC _IOWR('i', 87, struct filtreq) /* filtspec request */E#define SIOCGADSPEC _IOWR('i', 88, struct adspecreq) /* get adspec */S#define SIOCGTCNTLLIST _IOWR('i', 89, struct tcntllistreq) /* list filters/flows */N#define SIOCTCNTLCONF _IOWR('i', 90, struct tcntlconfreq) /* tcntl config *//*3** These ioctls help RSVP get routing information.** See rsvp_route.h*/I#define SIOCGROUTE _IOWR('r', 91, struct rtgetreq) /* get routing info */F#define SIOCGVIFCONF _IOWR('r', 92, struct vifconf) /* get vif list */K#define SIOCGMEDIAMTU _IOWR('i', 93, struct ifreq) /* get media mtu */P#define SIOCGIFTYPE _IOWR('i', 94, struct ifreq) /* get interface type *//*, * Some additional Traffic Control functions */L#define SIOCGLISTSPECFLOW _IOWR('i', 95, struct listflowreq) /* Flow info */N #define SIOCGLISTSPECFILT _IOWR('i', 96, struct listfiltreq) /* Filter info */"/* Traffic Monitor Thread (TMT) */C#define SIOCTMTADD _IOWR('i', 100, struct monitored_interface)C#define SIOCTMTREMOVE _IOWR('i', 101, struct monitored_interface)C#define SIOCTMTMODIFY _IOWR('i', 102, struct monitored_interface),#define SIOCTMTHOWMANY _IOWR('i', 103, int)C#define SIOCTMTSTATUS _IOWR('i', 104, struct monitored_interface)2#define SIOCTMTDUMP _IOWR('i', 105, __caddr_t)%#define SI OCTMTWALK _IO('i', 106)F#define SIOCTMTSTATEMODIFY _IOWR('i', 107, struct monitored_interface)#ifdef _SOCKADDR_LEN /*5 ** BSD 4.4 sockaddr format accepted and returned */P# define OSIOCGIFADDR _IOWR('i',13, struct ifreq) /* get ifnet address */P# define SIOCGIFADDR _IOWR('i',33, struct ifreq) /* get ifnet address */P# define OSIOCGIFDSTADDR _IOWR('i',15, struct ifreq) /* get p-p address */P# define SIOCGIFDSTADDR _IOWR('i',34, struct ifreq) /* get p-p address */P# define OSIOCGIFBRDADDR _IOWR('i',18, struct ifreq) /* get broadcast adr */P# define SIOCGIFBRDADDR _IOWR('i',35, struct ifreq) /* get broadcast adr */P# define OSIOCGIFCONF _IOWR('i',20, struct ifconf) /* get ifnet list */P# define SIOCGIFCONF _IOWR('i',36, struct ifconf) /* get ifnet list */P# define OSIOCGIFNETMASK _IOWR('i',21, struct ifreq) /* get net addr mask */P# define SIOCGIFNETMASK _IOWR('i',37, struct ifreq) /* get net addr m ask */P# define OSIOCGARP _IOWR('i',31, struct arpreq) /* get arp entry */P# define SIOCGARP _IOWR('i',38, struct arpreq) /* get arp entry */#else /* ** BSD 4.3 sockaddr format */P# define SIOCGIFADDR _IOWR('i',13, struct ifreq) /* get ifnet address */P# define SIOCGIFDSTADDR _IOWR('i',15, struct ifreq) /* get p-p address */P# define SIOCGIFBRDADDR _IOWR('i',18, struct ifreq) /* get broadcast adr */P# define SIOCGIFCONF  _IOWR('i',20, struct ifconf) /* get ifnet list */P# define SIOCGIFNETMASK _IOWR('i',21, struct ifreq) /* get net addr mask */P# define SIOCGARP _IOWR('i',31, struct arpreq) /* get arp entry */#endif/*** Tape i/o controls*/>#define MTIOCTOP _IOW('m', 1, struct mtop) /* Do a tape op.*/<#define MTIOCGET _IOR('m', 2, struct mtget) /* Get status */K#define MTIOCRDPOS _IOWR('m', 3, struct mtrdpos) /* Read Position *//*&** STREAMS ioctl commands - g roup 'S'*/O#define I_NREAD _IO('S', 1) /* return the number of bytes in 1st msg */L#define I_PUSH _IO('S', 2) /* push module just below stream head */F#define I_POP _IO('S', 3) /* pop module below stream head */N#define I_LOOK _IO('S', 4) /* retrieve name of first stream module */N#define I_FLUSH _IO('S', 5) /* flush all input and/or output queues */;#define I_SRDOPT _IO('S', 6) /* set the read mode */C#define I_GRDOPT _IO('S', 7) /* get the current read mode */J#define I_STR _IO('S', 8) /* create an internal ioctl message */J#define I_SETSIG _IO('S', 9) /* request SIGPOLL signal on events */E#define I_GETSIG _IO('S',10) /* query the registered events */D#define I_FIND _IO('S',11) /* check for module in stream */E#define I_LINK _IO('S',12) /* connect stream under mux fd */@#define I_UNLINK _IO('S',13) /* disconnect two streams */H#define I_ISASTREAM _IO('S',14) /* identifies as stream/pipe/fifo */D#define I_PEEK _IO('S',15) /* peek at data on read queue */N#define I_FDINSERT _IO('S',16) /* create a message and send downstream */O#define I_SENDFD _IO('S',17) /* send an fd to a connected pipe stream */D#define I_RECVFD _IO('S',18) /* retrieve a file descriptor */U#define I_FLUSHBAND _IO('S',19) /* flush a particular input and/or output band */<#define I_SWROPT _IO('S',20) /* set the write mode */D#define I_GWROPT  _IO('S',21) /* get the current write mode */O#define I_LIST _IO('S',22) /* get a list of all modules on a stream */J#define I_ATMARK _IO('S',23) /* is the next message is "marked"? */R#define I_CKBAND _IO('S',24) /* check for a message of a particular band */J#define I_GETBAND _IO('S',25) /* get the band of the next message */]#define I_CANPUT _IO('S',26) /* check to see if a message may be passed on a stream */D#define I_SETCLTIME _IO('S',27) /* set the close timeout wait */L#define I_GETCLTIME _IO('S',28) /* get the current close timeout wait */S#define I_PLINK _IO('S',29) /* persistently connect a stream under a mux */F#define I_PUNLINK _IO('S',30) /* disconnect a persistent link */9 /* 31-39 available */>#define I_GETMSG _IO('S',40) /* getmsg() system call */>#define I_PUTMSG _IO('S',41) /* putmsg() system call */?#define I_GETPMSG _IO('S',42) /* getpmsg() system call */?#define I_PUTPMSG _IO('S',43) /* putpmsg() system call */G#define I_PIPE _IO('S',44) /* connect two streams as a pipe */F#define I_FIFO _IO('S',45) /* convert a stream into a FIFO */A#define I_FATTACH _IO('S',46) /* check if fattached file */ #if SEC_BASE##define I_STR_ATTR _IO('S',60)##define I_PEEK_ATTR _IO('S',61)##define I_FDINSERT_ATTR _IO('S',62)##define I_SENDFD_ATTR _IO('S',63)##define I_RECVFD_ATTR _IO('S',64)##define I_GETMSG_ATTR _IO('S',65)##define I_PUTMSG_ATTR _IO('S',66)#endif /* SEC_BASE *//*!** binary event logger - group B*/+#define BINLOG_ENABLE _IO('B', 1)+#define BINLOG_DISABLE _IO('B', 2)+#define BINLOG_ASCIIENABLE _IO('B', 3)+#define BINLOG_ASCIIDISABLE _IO('B', 4)+#define BINLOG_CLRCNTRS _IO('B', 5)2#define BINLOG_SETPID _IOW('B', 6, long)F#define BINLOG_GETSTATUS _IOR('B', 20, struct binlog_getstatus)/* * File sy stem Ioctl's. */H#define GETCACHEPOLICY _IOR('F', 00, int) /* Get caching policy */H#define SETCACHEPOLICY _IOW('F', 01, int) /* Set caching policy */E#define CS_CACHE FCACHE /* Cache file data */L#define CS_DIRECTIO FDIRECTIO /* Do not cache file data */K#define GETMAP _IOR('F', 02, int) /* Get file's extent map *//*H** This section is for functions and declarations which do not support /** 64 bit pointers being passed (or returned).**F** The function ioctl passes a numeric "request code" followed by an G** argument pointer. Since this request code could specify both inputJ** and output arguments, and since the DEC C RTL does not interpret these=** arguments, they are restricted from being in high memory.*/#if __CRTL_VER >= 700000001 int ioctl (int __sd, int __r, void * __argp);#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore #pragma __extern_model __restore#pragma __standard#endif /* __STROPTS_LOADED */ww?ԗ#ifndef __TCP_LOADED#define __TCP_LOADEDM/******************************************************************************** - TCP descriptions**M******************************************************************************* Header is nonstandardM*****************************************************************************I** I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I**  I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M*******************************************************************************?** Copyright (c) 1982 Regents of the University of California.A** All rights reserved. The Berkeley software License Agreement:** specifies the terms and conditions for redistribution.**(** @(#)tcp.h 6.3 (Berkeley) 6/8/85**N*******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*7** Set __nomember_alignment to avoid internal and tail2** padding in structures; default base alignment.:** Required for consistency across programming languages.*/!#pragma __member_alignment __save#pragma __nomember_alignment/*** Disable messages*/#pragma __message __save-#pragma __message __disable (__MISALGNDSTRCT)+#pragma __message __disable (__MISALGNDMEM)#if defined __DECC,# pragma __message __disable (__BITNOTINT)#endif/*-** Define a caddr_t if not defined elsewhere*/*#if !defined __CADDR_T && !defined CADDR_T# define __CADDR_T 1!# ifndef __HIDE_FORBIDDEN_NAMES# define CADDR_T 1 # endif typedef __caddr_t caddr_t;#endif/*6** Define non-standard BSD socket compatible typedefs*/#ifndef __SOCKET_TYPEDEFS# define __SOCKET_TYPEDEFS 1" typedef unsigned char u_char;# typedef unsigned short u_short;" typedef unsigned long u_long;#endiftypedef u_long tcp_seq;/*.** TCP header. Per RFC 793, September, 1981.*/struct tcphdr {4 u_short th_sport; /* source port */4 u_short th_dport; /* destination port */4 tcp_seq th_seq; /* sequence number */4 tcp_seq th_ack; /* acknowledgement number */4 /* LITTLE_ENDIAN defn */4 u_char th_x2:4; /* (unused) */4 u_char th_off:4; /* data offset */4 u_char th_flags; /* */4 u_short th_win; /* window */4 u_short th_sum; /* checksum */4 u_short th_urp; /* urgent pointer */};/*** Define th_flags values*/#define TH_FIN 0x01#define TH_SYN 0x02#define TH_RST 0x04#define TH_PUSH 0x08#define TH_ACK 0x10#define TH_URG 0x20#define TCPOPT_MAX_LEN 40#define TCPO PT_EOL 0#define TCPOPT_NOP 1#define TCPOPT_MAXSEG 2#define TCPOLEN_MAXSEG 4!#define TCPOPT_WINDOW 3)#define TCPOLEN_WINDOW 3]#define TCPOPT_SACK_REQ 4 /* rfc 2018 Sack option requested SYN only */)#define TCPOLEN_SACK_PERMITTED 2B#define TCPOPT_SACK 5 /* Experimental */O#define TCPOPT_TS 8 /* rfc 1323 timestamp option */*#define TCPOLEN_TIMESTAMP 10N#define TCPOLEN_TSTAMP_APPA (TCPOLEN_TIMESTAMP+2) /* appendix A */#define TCPOPT_TSTAMP_HDR \I (TCPOPT_NOP<<24|TCPOPT_NOP<<16|TCPOPT_TIMESTAMP<<8|TCPOLEN_TIMESTAMP)/* * sack defines */L#define TCP_SACK_ELEMENT_LEN 8 /* Sack element have 2 int fields */K#define TCPOPT_SACK_LEN_OK( len ) ((len>=10) && (((((len-2)/8)*8)+2)==len))/* * timestamp defines */I#define TCPOPT_TS_LEN 10 /* tcp timestamp option length */\#define TCPOLEN_TSTAMP _APPA ((TCPOPT_NOP<<24)|(TCPOPT_NOP<<16)|(TCPOPT_TS<<8)|TCPOPT_TS_LEN)A#define TCPOPT_CREATE_TSOPT(opt, optlen, TSVAL, TSECR) \A{ \A int *__tmp=(int*)(opt) ; \A __tmp[0]=htonl(TCPOLEN_TSTAMP_APPA) ; \A __tmp[1]=htonl(TSVAL) ; \A __tmp[2]=htonl(TSECR) ; \A optlen+=TCPOPT_T S_LEN+2 ; \}A#define TCPOPT_EXTRACT_TSOPT(opt, TSVAL, TSECR) \A{ \C bcopy((__caddr_t)(&(opt)[2]), &(TSVAL), sizeof(TSVAL)) ; \A TSVAL=ntohl(TSVAL) ; \D bcopy(&(opt)[2+sizeof(TSVAL)], &(TSECR) , sizeof(TSECR)) ; \A TSECR=ntohl(TSECR) ; \}/*( * Default maximum segment size for TCP.6 * For RFC1122 MUST conformance, this needs to be 536.& * With an IP MSS of 576, this is 536,' * but 512 is probably more convenient.I * This should be defined as min(512, IP_MSS - sizeof (struct tcpiphdr)). */4#define TCP_MSS 536 /* XXX - BSD4.4lite uses 512 */B#define TCP_MAXWIN 65535 /* largest value for (unscaled) window */6#define TCP_MAX_WINSHIFT 14 /* maximum window shift *//*4 * User-settable options (used with set/getsockopt). */C#define TCP_NODELAY 0x01 /* do n't delay send to coalesce packets */6#define TCP_MAXSEG 0x02 /* set maximum segment size *//* F * Number of retransmissions before dropping connection. Larger than & * TCP_MAXRXTSHIFT or -1 for infinity  */B#define TCP_RPTR2RXT 0x03 /* set repeat count for R2 RXT timer */ F#define TCP_KEEPIDLE 0x04 /* seconds before initial keepalive probe */A#define TCP_KEEPINTVL 0x05 /* seconds between keepalive probes */E#define TCP_KEEPCNT 0x06 /* number of keepalive probes before drop */A#defin e TCP_KEEPINIT 0x07 /* initial connect timeout (seconds) */A#define TCP_PUSH 0x08 /* set push bit in outbound data packets */D#define TCP_NODELACK 0x09 /* don't delay send to coalesce packets */7#define TCP_TSOPTENA 0x10 /* time stamp option */1#define TCP_PAWS 0x20 /* PAWS option */2#define TCP_SACKENA 0x40 /* SACK enabled */0#define TCP_PROBE_IDLE 0x80 /* Probe idle *//#define TCP_DROP_IDLE 0x81 /* Drop idle *//*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __message __restore$#pragma __member_alignment __restore#pragma __standard#endif /* __TCP_LOADED */ww-.@ԗ#ifndef __TGMATH_LOADED#define __TGMATH_LOADED 1M/******************************************************************************0** - C99 type-generic math functions**M*****************************************************************************)** Header introduced by the C99 StandardM*****************************************************************************I** I** Copyright 2006 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include E#if !( !defined(__VAX) && defined(__DECC) && __DECC_VER >= 60400000 )D# error "C99 header is not supported by this compiler."#else#include #include /*5 * Remove builtins forced by traditional VMS  */ #undef fabs #undef cos #undef sin%#define acos(__x) __TGacos(__x)&#define acosh(__x) __TGacosh(__x)%#define asin(__x) __TGasin(__x)&#define asinh(__x) __TGasinh(__x)%#define atan(__x) __TGatan(__x)*#define atan2(__x,__y) __TGatan2(__x,__y)&#define atanh(__x) __TGatanh(__x)%#define carg(__x) __TGcarg(__x)%#define cbrt(__x) __TGcbrt(__x)%#define ceil(__x) __TGceil(__x)&#define cimag(__x) __TGcimag(__x)%#define conj(__x) __TGconj(__x)1#define copy sign(__x,__y) __TGcopysign(__x,__y)$#define cos(__x) __TGcos(__x)%#define cosh(__x) __TGcosh(__x)&#define cproj(__x) __TGcproj(__x)&#define creal(__x) __TGcreal(__x)$#define erf(__x) __TGerf(__x)%#define erfc(__x) __TGerfc(__x)$#define exp(__x) __TGexp(__x)%#define exp2(__x) __TGexp2(__x)&#define expm1(__x) __TGexpm1(__x)%#define fabs(__x) __TGfabs(__x))#define fdim(__x,__y) __TGfdim(__x,__y)&#define floor(__x) __TG floor(__x)0#define fma(__x,__y,__z) __TGfma(__x,__y,__z))#define fmax(__x,__y) __TGfmax(__x,__y))#define fmin(__x,__y) __TGfmin(__x,__y))#define fmod(__x,__y) __TGfmod(__x,__y)*#define frexp(__x,__y) __TGfrexp(__x,__y)*#define hypot(__x,__y) __TGhypot(__x,__y)&#define ilogb(__x) __TGilogb(__x)*#define ldexp(__x,__y) __TGldexp(__x,__y)'#define lgamma(__x) __TGlgamma(__x)$#define log(__x) __TGlog(__x)&#define log10(__x) __TGlog10(__x)&#define log1p(__x)  __TGlog1p(__x)%#define log2(__x) __TGlog2(__x)%#define logb(__x) __TGlogb(__x)&#define lrint(__x) __TGlrint(__x)'#define lround(__x) __TGlround(__x)2#define nextafter(__x,__y) __TGnextafter(__x,__y)3#define nexttoward(__x,__y) __TGnexttoward(__x,__y)(#define pow(__x,__y) __TGpow(__x,__y)2#define remainder(__x,__y) __TGremainder(__x,__y)3#define remquo(__x,__y,__z) __TGremquo(__x,__y,__z)%#define rint(__x) __TGrint(__x)+#define scalbn(__x,__y) __TGscalbn(__x,__y)$#define sin(__x) __TGsin(__x)%#define sinh(__x) __TGsinh(__x)%#define sqrt(__x) __TGsqrt(__x)$#define tan(__x) __TGtan(__x)%#define tanh(__x) __TGtanh(__x)'#define tgamma(__x) __TGtgamma(__x)&#define trunc(__x) __TGtrunc(__x)I#endif /* !defined(__VAX) && defined(__DECC) && __DECC_VER >= 60400000 */#pragma __standard#endif /* __TGMATH_LOADED */wwRT@ԗ#ifndef __TIME_LOADED#define __TIME_LOADED#ifndef __TIME_PROCESSED#define __TIME_PROCESSEDM/******************************************************************************** - Date and Time**M*******************************************************************************,** Header introduced by the ANSI C Standard**K** Definitions in this header file may not be available on all versions ofK** OpenVMS. See the DEC C Runtime Library reference manual for specifics.**M*****************************************************************************I** I** Copyright 2006 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*K** If the user has used /pointer_size=short or /pointer_size=long, we will+** begin in a 32-bit pointer size context.*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/* ** Member align structures*/!#pragma __member_alignment __save#pragma __member_alignment/*** Disable messages*/#pragma __message __save-#pragma __message __disable (__MISALGNDSTRCT)+#pragma __message __disable (__MISALGNDMEM)/*I** Create 'private' typedefs that are sensitive to pointer size and must** use 32 bit pointers.*//*(** ANSI Standard Definitions & Typedefs*/#define CLOCKS_PER_SEC 100 #ifndef NULL# define NULL __NULL#endif#ifdef __NAMESPACE_STDnamespace std {#endif#ifndef __SIZE_T# define __SIZE_T 1 typedef __size_t size_t;#endif#ifndef __TIME_T# define __TIME_T typedef __time_t time_t;#endif#ifndef __CLOCK_T # define __CLOCK_T 1 typedef long int clock_t;#endif/*** tm data structure**B** Note conditions for BSD extensions, introduced in VMS V7.0, and:** not wanted for some standards or legacy compilations. F** These extensions make tm "long". Not having them makes tm "short".8** - C++ Standard Library requires longer tm structure.F** After C++ V6.5 -042, use filler names. Either requires __utctz_.F** - Future VMS releases will get a longer tm structure possibly withF** changed/filler names, to make all objects of tm the same length,<** which may force recompilation of all modules using tm.)** - Macro _TM_SHORT will force short tm'** - Macro _TM_LONG will force long tm**?** This decides the time format for functions, 3 possibilities:.** - localtime (before VMS V7.0, no prefixes)** - utc time, one of:3** o __UTCTZ_ prefixes, using BSD tm extensions4** o __UTC_ prfexes, not using BSD tm extensions*/#undef __TM_USE_UTCTZ_TIME#undef __TM_USE_UTC_TIME#undef __TM_DEF_BSD_EXTENSIONS #undef __TM_DEF_BSD_FILLER_NAMES#undef __TM_CXX_NEED_BSD_NAMES!#undef __TM_CXX_NEED_FILLER_NAMES#if __CRTL_VER >= 70000000 2# if defined __DECCXX && !defined _VMS_V6_SOURCE# if __DECCXX_VER > 60590042'# define __TM_CXX_NEED_FILLER_NAMES# else$# define __TM_CXX_NEED_BSD_NAMES# endif # endif3  /* UTC time functions available in CRTL */ H# if (!defined _ANSI_C_SOURCE || defined __TM_CXX_NEED_BSD_NAMES) && \5 !defined _DECC_V4_SOURCE && !defined _TM_SHORT /* BSD member names visible */ # define __TM_DEF_BSD_EXTENSIONSE# if !defined _VMS_V6_SOURCE || defined __TM_CXX_NEED_BSD_NAMES* /* Use __UTCTZ_ prefixed functions */ # define __TM_USE_UTCTZ_TIME # endif # elif !defined _VMS_V6_SOURCE$ /* Use __UTC_ prefixed functions */# define __TM_USE_UTC_TIME # endif#endif /* CRTL V7.0 */:#if !defined __TM_DEF_BSD_EXTENSIONS && !defined _TM_SHORT6# if __CRTL_VER >= 80300000 || defined _TM_LONG || \) defined __TM_CXX_NEED_FILLER_NAMES4 /* Longer tm, but non-polluting BSD member names */"# define __TM_DEF_BSD_FILLER_NAMES# if defined __DECCXX # define __TM_USE_UTCTZ_TIME# undef __TM_USE_UTC_TIME# endif # endif#endif)#if defined _TM_SHORT && defined _TM_LONGA# error "Both _TM_SHORT and _TM_LONG defined ; only one allowed"#endif struct tm {; int tm_sec; /* seconds after the minute [0, 61] */; int tm_min; /* minutes after the hour [0, 59] */; int tm_hour; /* hours since midnight [0, 23] */; int tm_mday; /* day of the month [1, 31] */; int tm_mon; /* months since January [0, 11] */; int tm_year; /* years since 1900 */; int tm_wday; /* days since Sunday [0, 6] */; int tm_yday; /* day s since January 1 [0, 365] */; int tm_isdst; /* Daylight Saving Time flag */##if defined __TM_DEF_BSD_EXTENSIONS! /* BSD tm member extensions */; long tm_gmtoff; /* offset from UTC in seconds */; char *tm_zone; /* timezone abbreviation */'#elif defined __TM_DEF_BSD_FILLER_NAMES; /* BSD tm member extensions, non-polluting namespace */; long __tm_gmtoff; /* offset from UTC in seconds */; char *__tm_zone; /* timezone abbreviation */#endif }; /* tm */#ifdef __NAMESPACE_STD} /* namespace std */#endif#ifdef __NAMESPACE_STD+typedef struct std::tm * __struct_tm_ptr32;#else&typedef struct tm * __struct_tm_ptr32;#endif/*J** clock_t datatype is used in this header file in declaration of functionI** times() which is not in the ANSI C standard, and, consequently, is notJ** inserted into the namespace std. Make clock_t datatype available in theA** global namespace when compiling with C++ in nopure_cname mode.*/>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY) using std::clock_t;#endif/*/** ISO POSIX-1 Standard Definitions & Typedefs*/6#if defined _POSIX_C_SOURCE || !defined _ANSI_C_SOURCE /*A ** Number of clock ticks per second returned by the times ()# ** function. (To be Withdrawn) */# define CLK_TCK 100 /* 3 ** tzname is the name of the current timezone,3 ** it is not visible if compiling for a local & ** time based compatibility mode. */ # if __CRTL_VER >= 70000000"# if !defined _VMS_V6_SOURCE(# pragma __extern_model __save1# pragma __extern_model __strict_refdef# extern char *tzname[2];+# pragma __extern_model __restore # endif # endif#endif/* .** X/Open extension definitions and typedefs,0** these variables are not visible if compiling-** in a local time based compatibility mode.*/ 4#if defined _XOPEN_SOURCE || !defined _ANSI_C_SOURCE# if __CRTL_VER >= 70000000"# if !defined _VMS_V6_SOURCE(# pragma __extern_model __save1# pragma __extern_model __strict_refdef! extern int daylight; % extern long int timezone;+# pragma __extern_model __restore # endif # endif#endif/* ,** DEC C extension definitions and typedefs*/ #ifndef _ANSI_C_SOURCE /* = ** struct timeb is defined by XPG4 V2 to be in  */ # ifndef __TIMEB_STR_LOADED## define __TIMEB_STR_LOADED 1 struct timeb { __time_t time;$ unsigned short millitm; short timezone; short dstflag; }; # endif# ifndef __TIMEB_T# define __TIMEB_T$ typedef struct timeb timeb_t; # endif9# if __CRTL_VER >= 70000000 && !defined _DECC_V4_SOURCE# ifndef __TMS# define __TMS struct tms {5 clock_t tms_utime; /* user CPU time */7 clock_t tms_stime; /* system CPU time */N clock_t tms_cutime; /* user CPU of terminated child processes */P clock_t tms_cstime; /* system CPU of terminated child processes */ }; # endif # endif# ifndef __TBUFFER_T# define __TBUFFER_T 1 typedef struct tbuffer { int proc_user_time; int proc_system_time; int child_user_time;! int child_system_time; } tbuffer_t; # endif#endif/*M** We are done defining things which must always be 32 bit pointers. If theL** user has used /pointer_size=32 or /pointer_size=64, we will allow 64 bit*** pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*I** Create 'private' typedefs that are sensitive to pointer size and must@** use long pointers. Protect identically in all header files.*/#ifdef __NAMESPACE_STD+typedef struct std::tm * __struct_tm_ptr64;#else&typedef struct tm * __struct_tm_ptr64;#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*3** ANSI Function prototypes -- full 64 bit support*/  clock_t clock (void);; double difftime (__time_t __time1, __time_t __time0);; __char_ptr32 asctime (const struct tm *__timeptr);#ifdef __NAMESPACE_STD} /* namespace std */#endif6#if defined _POSIX_C_SOURCE || !defined _ANSI_C_SOURCE#ifdef __NAMESPACE_STDK __char_ptr32 asctime_r(const struct std::tm *__tm, __char_ptr32 __buf);#elseF __char_ptr32 asctime_r(const struct tm *__tm, __char_ptr32 __buf);#endif#endif/*B** Beginning in OpenVMS Version 7.0 mktime, time, ctime, strftime=** have two implementations. One implementation is providedA** for compatibility and deals with time in terms of local time,6** the other __utc_* deals with time in terms of UTC.*/#if __CRTL_VER >= 70000000# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __save*# pragma __extern_prefix "__utc_" # else4# define mktime(__p1) __utc_mktime(__p1)2# define time(__p1) __utc_time(__p1)3# define ctime(__p1) __utc_ctime(__p1)T# define strftime(__p1,__p2,__p3,__p4) __utc_strftime(__p1,__p2,__p3,__p4) # endif # endif##endif /* __CRTL_VER >= 70000000 */#ifdef __NAMESPACE_STDnamespace std {#endif/ __time_t mktime (struct tm *__timeptr);, __time_t time (__time_t *__timer);1 __char_ptr32 ctime (const __time_t *__timer);L __size_t strftime (char *__s, __size_t __maxsize, const char *__format, 1 const struct tm *__timeptr);#ifdef __NAMESPACE_STD} /* namespace std */#endif/*2** Disable extern_prefix if we enabled it earlier*/#if __CRTL_VER >= 70000000# if !defined _VMS_V6_SOURCE$#  ifdef __CAN_USE_EXTERN_PREFIX+# pragma __extern_prefix __restore # endif # endif#endif/*F** Beginning in OpenVMS Version 7.2, we have added and implementationD** of the ctime_r function. There are both local time and utc time** implementations.*/#if __CRTL_VER >= 70000000 && \8 (defined _POSIX_C_SOURCE || !defined _ANSI_C_SOURCE)# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __save*# pragma __extern_prefix "__utc_" # else=# define ctime_r(__p1,__p2) __utc_ctime_r(__p1,__p2) # endif # endifG __char_ptr32 ctime_r (const __time_t *__timer, __char_ptr32 __buf);# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX+# pragma __extern_prefix __restore # endif # endif1#endif /* __CRTL_VER >= 70000000 && (not ANSI) *//*D** Beginning in OpenVMS Version 7.0 gmtime and localtime have three** implementations:/** - Older (pre-7.0) localtime implementation$** - Two UTC time implementations:6** o __utctz_* implementations provide support for the@** additional tm_gmtoff and tm_zone fields of the tm structureB** o the __utc_* implementations deal with the ANSI definition of ** the tm structure.*/#if defined __TM_USE_UTCTZ_TIME0 /* UTC time with BSD tm member extensions */!# ifdef __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __save,# pragma __extern_prefix "__utctz_"# else6# define gmtime(__p1) __utctz_gmtime(__p1)9# define localtime(__p1) __utctz_localtime(__p1) # endif#elif defined __TM_USE_UTC_TIME3 /* UTC time without BSD tm member extensions */!# ifdef __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __save*# pragma __extern_prefix "__utc_"# else4# define gmtime(__p1) __utc_gmtime(__p1)7# define localtime(__p1) __utc_localtime(__p1) # endif#endif#ifdef __NAMESPACE_STDnamespace std {#endif; __struct_tm_ptr32 localtime (const __time_t *__timer); 9 __struct_tm_ptr32 gmtime (const __time_t *__timer); #ifdef __NAMESPACE_STD} /* namespace std */#endif/*2** Disable extern_prefix if we enabled it earlier*/<#if defined __TM_USE_UTCTZ_TIME || defined __TM_USE_UTC_TIME!# ifdef __CAN_USE_EXTERN_PREFIX"# pragma __extern_prefix __restore # endif#endif8#if !(defined(__NAMESPACE_STD) && defined(__PURE_CNAME))/*L** Beginning in OpenVMS Version 7.2, we have added gmtime_t and localtime_tI** implementations. The same three interfaces are supported for each as** described above.*/#if __CRTL_VER >= 70000000 && \8 (defined _POSIX_C_SOURCE || !defined _ANSI_C_SOURCE)# undef __UTC_PREFIX_DEFINED"# if defined __TM_USE_UTCTZ_TIME- /* UTC time with BSD tm member extensions */# ifdef __CAN_USE_EXTERN_PREFIX # define __UTC_PREFIX_DEFINED(# pragma __extern_prefix __save,# pragma __extern_prefix "__utctz_"# elseD# define gmtime_r(__p1,__p2) __utctz_gmtime_r(__p1,__p2)G# define localtime_r(__p1,__p2) __utctz_localtime_r(__p1,__p2)# endif"# elif defined __TM_USE_UTC_TIME0 /* UTC time without BSD tm member extensions */# ifdef __CAN_USE_EXTERN_PREFIX # define __UTC_PREFIX_DEFINED(# pragma __extern_prefix __save*# pragma __extern_prefix "__utc_"# elseB# define gmtime_r(__p1,__p2) __utc_gmtime_r(__p1,__p2)E# define localtime_r(__p1,__p2) __utc_localtime_r(__p1,__p2)# endif # endifV __struct_tm_ptr32 gmtime_r (const __time_t *__timer, __struct_tm_ptr32 __result); Y __struct_tm_ptr32 localtime_r (const __time_t *__timer, __struct_tm_ptr32 __result); # ifdef __UTC_PREFIX_DEFINED'# pragma __extern_prefix __restore!# undef __UTC_PREFIX_DEFINED # endif1#endif /* __CRTL_VER >= 70000000 && (not ANSI) */A#endif /* !(defined(__NAMESPACE_STD) && defined(__PURE_CNAME)) *//* :** ISO POSIX-1 Function prototypes -- full 64 bit support*/ 6#if defined _POSIX_C_SOURCE || !defined _ANSI_C_SOURCE8# if __CRTL_VER >= 70000000 && !defined _VMS_V6_SOURCE void tzset (void); # endif# endif/*O** The following functions have interfaces of XXX, _XXX32, and _XXX64 due onlyM** to the fact that the return argument is a pointer that is relative to one** of the arguments.*/ #if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32#endif4#if defined _XOPEN_SOURCE || !defined _ANSI_C_SOURCE# if __CRTL_VER >= 60200000\ char *strptime (const char *__buf, __const_char_ptr64 __fmt, __struct_tm_ptr64 __tm); # endif#endif #if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 64#endif/* ** DEC C Extensions*/ #ifndef _ANSI_C_SOURCE /*H** Beginning in OpenVMS Version 7.0 ftime has two implementations. OneM** implementation is provided for compatibility and deals with time in termsI** of local time, the other __utc_ftime deals with time in terms of UTC.*/#if __CRTL_VER >= 70000000# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __save*# pragma __extern_prefix "__utc_" # else1# define ftime(__p1) __utc_ftime(__p1) # endif # endif##endif /* __CRTL_VER >= 70000000 *// int ftime (struct timeb *__timeptr); /*2** Disable extern_prefix if we enabled it earlier*/#if __CRTL_VER >= 70000000# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX+# pragma __extern_prefix __restore # endif # endif#endif9# if __CRTL_VER >= 70000000 && !defined _DECC_V4_SOURCE) clock_t times(struct tms *buffer);# else> void times (tbuffer_t *__buffer); /* */ # endif# if __INITIAL_POINTER_SIZE# pragma __pointer_size 32P char * _strptime32 (const char *, __const_char_ptr64, __struct_tm_ptr64);# pragma __pointer_size 64J char * _strptime64 (const char *, const char *, __struct_tm_ptr64); # endif#endifM/******************************************************************************** - time types**G** The following is the equivalent of . It is merged into@** since DEC C on OpenVMS systems does not distinguish** the two header files.*/[#if define d _XOPEN_SOURCE_EXTENDED || (!defined _ANSI_C_SOURCE && !defined _DECC_V4_SOURCE)/*A** Values for the which argument of getitimer() and setitimer().*/;# define ITIMER_REAL 0 /* Real time */B# define ITIMER_VIRTUAL 1 /* Per-process time */G# define ITIMER_PROF 2 /* Per-process user time */# ifndef __TIMEVAL# define __TIMEVAL 1 struct timeval {C __time_t tv_sec; /* seconds since Jan. 1, 1970 */3 long tv_usec; /* microseconds */e }; # endif struct itimerval {9 struct timeval it_interval; /* timer interval */8 struct timeval it_value; /* current value */ };  /*A ** Select () examines I/O descriptor sets which are stored asB ** bit fields in arrays of integers. The following macros are7 ** provided for mani pulating such descriptor sets.  */> /* FD_SETSIZE may be defined by the user. It is normally > ** equal to the maximum number of descriptors supported byC ** the system. Here it is set to the minimum maximum supportedA ** by the system. In order to accomodate programs which use D ** a larger number of open files with select, increase this sizeF ** within a program by providing a larger definition of FD_SETSIZE. ** before including or  */ # if !defined __FD_SET# define __FD_SET 1# ifndef FD_SETSIZE(# define FD_SETSIZE 1024# endif typedef long fd_mask;H# define NBBY 8 /* bits per byte */H# define NFDBITS (sizeof(fd_mask) * NBBY) /* bits per mask */_# define FD_SET(__n, __p) ((__p)->fds_bits[(__n)/NFDBITS] |= (1 << ((__n) % NFDBITS)))`# define FD_CLR(__n, __p) ((__p)->fds_bits[(__n)/NFDBITS] &= ~(1 << ((__n) % NFDBITS)))^# define FD_ISSET(__n, __p) ((__p)->fds_bits[(__n)/NFDBITS] & (1 << ((__n) % NFDBITS)))?# define __howmany(__x, __y) (((__x)+((__y)-1))/(__y))O typedef struct fd_set { /* descriptor set */= fd_mask fds_bits[__howmany(FD_SETSIZE, NFDBITS)]; } fd_set;# if !defined(__VAX)%# if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32 # endif6 void *__MEMSET(void *__s, int __c, __size_t __n );<# define FD_ZERO(__p) __MEMSET((__p), 0, sizeof(*(__p)))%# if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 64 # endif# else= void _MOVC5(unsigned short __srclen, const char *__src, < char __fill, unsigned short __destlen, char *__dest, ...);H# define FD_ZERO(__p) _MOVC5(0, 0, 0, sizeof(*(__p)), (char *)(__p))# endif # endif/*M** We are done defining things which must always be 32 bit pointers. If theL** user has used /pointer_size=32  or /pointer_size=64, we will allow 64 bit*** pointers to be used in function calls.*/# if __INITIAL_POINTER_SIZE!# pragma __pointer_size 64 # endif/* B** Note that gettimeofday() is UTC based, so it is not visible if 6** compiling in a local time based compatibility mode.*/ #if __CRTL_VER >= 70000000 ; int getitimer (int __which, struct itimerval *__value);] int setitimer (int __which, const struct itimerval *__value, struct itimerval *__ovalue); # if !defined _VMS_V6_SOURCE= int gettimeofday (struct timeval *__tp, void *__tzp); # endif#endifX int select (int __nfds, fd_set *__readfds, fd_set *__writefds, fd_set *__exceptfds, + struct timeval *__timeout);#if __CRTL_VER >= 70300000 # if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __save*# pragma __extern_prefix "__utc_" # else<# define utimes(__p1,__p2) __utc_utimes( __p1,__p2) # endif # endif@int utimes(const char *__path, const struct timeval __times[2]);# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX+# pragma __extern_prefix __restore # endif # endif#endif#if __CRTL_VER >= 703200005# if (!defined __TIMESPEC && !defined _TIMESPEC_T_)# define __TIMESPEC struct timespec {2 unsigned long tv_sec; /* seconds */6 long tv_nsec; /* nanoseconds */   }; # endif# define CLOCK_REALTIME 1# ifndef __CLOCKID_T# define __CLOCKID_T% typedef unsigned int clockid_t; # endif? int clock_gettime(clockid_t clock_id, struct timespec *tp);E int clock_settime(clockid_t clock_id, const struct timespec *tp);? int clock_getres(clockid_t clock_id, struct timespec *res);A long nanosleep(struct timespec *rqtp, struct timespec *rmtp);'#endif /* if __CRTL_VER >= 70320000 */O#endif /* _XOPEN_SOURCE_EXTENDED || (! _ANSI_C_SOURCE && ! _DECC_V4_SOURCE) *//* %** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __message __restore$#pragma __member_alignment __restore#pragma __standard#endif /* __TIME_PROCESSED */>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_TIME_NAMES# define __USING_TIME_NAMES using std::asctime;  using std::clock; using std::clock_t; using std::ctime; using std::difftime; using std::gmtime; using std::localtime; using std::mktime; using std::size_t; using std::strftime; using std::time; using std::time_t; using std::tm;# endif#endif#endif /* __TIME_LOADED */ww Aԗ#ifndef __TIMEB_LOADED#define __TIMEB_LOADED 1M/**************************************************************************** **3** - ftime() return structure definition**M*****************************************************************************I** Header introduced by the X/Open CAE Specification, Issue 4, Version 2M*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I**  I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license.  I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*** Member align structures*/!#pragma __member_alignment __save#pragma __member_alignment/*** Disable certain messages*/#pragma __message __save-#pragma __message __disable (__MISALGNDSTRCT)+#pragma __message __disable (__MISALGNDMEM)/*** Define the time_t structure*/#ifndef __TIME_T# define __TIME_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __time_t time_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std:: time_t;#endif#endif/*** Define the timeb structure*/#ifndef __TIMEB_STR_LOADED# define __TIMEB_STR_LOADED 1 struct timeb { __time_t time; unsigned short millitm; short timezone; short dstflag; };#endif/* ** DEC C extensions*/ 9#if !defined _XOPEN_SOURCE_EXTENDED && !defined __TIMEB_T# define __TIMEB_T! typedef struct timeb timeb_t;#endif/* ** Function prototypes*/ #if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*H** Beginning in OpenVMS Version 7.0 ftime has two implementations. OneM** implementation is provided for compatibility and deals with time in termsI** of local time, the other __utc_ftime deals with time in terms of UTC.*/#if __CRTL_VER >= 70000000# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __save*# pragma __extern_prefix "__utc_" # else1# define ftime(__p1) __utc_ftime(__p1) # endif # endif##endif /* __CRTL_VER >= 70000000 */( int ftime (struct timeb *__timeptr);/*2** Disable extern_prefix if we enabled it earlier*/#if __CRTL_VER >= 70000000# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX+# pragma __extern_prefix __restore # endif # endif#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __message __restore$#pragma __member_alignment __restore#pragma __standard #endif /* __TIMEB_LOADED */ww09Aԗ#ifndef __TIMERS_LOADED#define __TIMERS_LOADED 1M/********************************************************************************* - Clock and timer functions**M******************************************************************************* Header is nonstandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M************************ ******************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#include #if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endif/* ** Constants for Functions */0#define TIMEOFDAY 1 /* time of day clock type *//* ** Typedef*/#ifndef _TIMESPEC_T_ # define _TIMESPEC_T_# ifndef __TIMESPEC# define __TIMESPEC  struct timespec {9 unsigned long tv_sec; /* seconds */= long tv_nsec; /* nanoseconds */ }; # endif# ifndef __TIMESPEC_T# define __TIMESPEC_T+ typedef struct timespec timespec_t; # endif#endif /*?** Functions added in OpenVMS V7.0, Note, that getclock is UTCA** based so it is not visible if compiling in a local time based** compatibility mode.*/#if __CRTL_VER >= 70000000# if !defined _VMS_V6_SOURCE: int getclock(int clock_type, struct timespec *tp); # endif#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __TIMERS_LOADED */wwU_Aԗ#ifndef __TIMES_LOADED#define __TIMES_LOADED 1M/******************************************************************************@** - file  access and modification times structure**M*****************************************************************************1** Header introduced by the ISO POSIX-1 StandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential comp uter software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. ! I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be "construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endif/*** Member align structures #*/!#pragma __member_alignment __save#pragma __member_alignmentO/********************************************************************************M** This header file either defines the ISO POSIX-1 structures and prototypesM** or defines the DEC C specific structures and prototypes. The ISO POSIX-1K** support was added in OpenVMS V7.0. The user could still access the old)** interface by defining _DECC_V4_SOURCE**P**************************************************************$*****************/S#if __CRTL_VER >= 70000000 && (defined _POSIX_C_SOURCE || !defined _DECC_V4_SOURCE)O /**************************************************************************< ** ISO POSIX-1 definitions of structures and prototypesP ***************************************************************************/# ifndef __CLOCK_T# define __CLOCK_T#ifdef __NAMESPACE_STDnamespace std {#endif typedef int clock_t;#ifdef __NAMESPACE_STD} /* namespace% std */ using std::clock_t;#endif # endif# ifndef __TMS# define __TMS struct tms {4 clock_t tms_utime; /* user CPU time */- clock_t tms_stime; /* system CPU time */H clock_t tms_cutime; /* user CPU of terminated child processes */H clock_t tms_cstime; /* system CPU of terminated child processes */ }; # endif) clock_t times (struct tms *__buffer);#elseO /*******************************************&*******************************. ** DEC C specific (prior to OpenVMS V7.0)P ***************************************************************************/# ifndef __TBUFFER_T # define __TBUFFER_T 1 typedef struct tbuffer { int proc_user_time; int proc_system_time; int child_user_time;! int child_system_time; } tbuffer_t; # endif9 void times (tbuffer_t *__buffer); /* */#endif/*'%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#pragma __standard #endif /* __TIMES_LOADED */wwAԗ#ifndef __TYPES_LOADED#define __TYPES_LOADED 1M/******************************************************************************)** - Standard Type Definitions**M**************************************************(***************************1** Header introduced by the ISO POSIX-1 StandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possess)ion, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP *nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. + I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*** Public typedefs *//*** ISO POSIX-1 typedefs*//* ** Used for device IDs.*/1#if !defined __DEV_T && !,defined _DECC_V4_SOURCE# define __DEV_T 1 typedef __dev_t dev_t; #endif/* ** Used for group IDs.*/1#if !defined __GID_T && !defined _DECC_V4_SOURCE# define __GID_T 1 typedef __gid_t gid_t; #endif/* !** Used for file serial numbers.*/1#if !defined __INO_T && !defined _DECC_V4_SOURCE# define __INO_T 1 typedef __ino_t ino_t; #endif/* "** Used for some file attributes.*/2#if !defined __MODE_T && !defined _DECC_V4_SOURCE# -define __MODE_T 1 typedef __mode_t mode_t; #endif/* ** Used for link counts.*/3#if !defined __NLINK_T && !defined _DECC_V4_SOURCE# define __NLINK_T 1 typedef __nlink_t nlink_t;#endif/* ** Used for file sizes.*/1#if !defined __OFF_T && !defined _DECC_V4_SOURCE# define __OFF_T 1 typedef __off_t off_t; #endif/* .** Used for process IDs and process group IDs.*/1#if !defined __PID_T && !defined _DECC_V4_SOURCE# define __PID_T 1 . typedef __pid_t pid_t; #endif/*** Used for sizes of objects.*/2#if !defined __SIZE_T && !defined _DECC_V4_SOURCE# define __SIZE_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __size_t size_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::size_t;#endif#endif/*4** Used for a count of bytes or an error indication.*/3#if !defined __SSIZE_T && !defined _DECC_V4_SOURCE# define __SSIZE_T 1 typedef __ssize_t ssize_t;#endif//*** Used for user IDs.*/1#if !defined __UID_T && !defined _DECC_V4_SOURCE# define __UID_T 1 typedef __uid_t uid_t;#endif/* 1** X/Open XPG4 typedefs, also defined in DECC V4*/ 5#if defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCE/* ** Used for time in seconds.*/# ifndef __TIME_T# define __TIME_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __time_t time_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::time_t0;#endif # endif#endif/* +** X/Open XPG4 typedefs, new in DEC C V5.n*/ S#if defined _XOPEN_SOURCE || (!defined _POSIX_C_SOURCE && !defined _DECC_V4_SOURCE)/* ;** Used for system times in clock ticks or CLOCKS_PER_SEC.*/# ifndef __CLOCK_T # define __CLOCK_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef long int clock_t; #ifdef __NAMESPACE_STD} /* namespace std */ using std::clock_t;#endif # endif/* *** Used for i1nterprocess communication. */# ifndef __KEY_T # define __KEY_T 1 typedef __key_t key_t; # endif#endif/* #** X/Open extended (XPG4) typedefs*/ \#if defined _XOPEN_SOURCE_EXTENDED || (!defined _POSIX_C_SOURCE && !defined _DECC_V4_SOURCE)/*Z** Used as a general identifier; can be used to contain at least a pid_t, uid_t or gid_t.*/# ifndef __ID_T# define __ID_T typedef __id_t id_t; # endif/*!** Used for time in microseconds.*/# ifndef _2_USECONDS_T# define __USECONDS_T! typedef __useconds_t useconds_t; # endif#endif/*F** Define non-standard socket compatible typedefs for BSD portability*/#ifndef _POSIX_C_SOURCEL# if !defined(__CADDR_T) && !defined(CADDR_T) && !defined(_DECC_V4_SOURCE)# define __CADDR_T 1*# if !defined __HIDE_FORBIDDEN_NAMES# define CADDR_T 1 # endif" typedef __caddr_t caddr_t; # endif# ifndef __SOCKET_TYPEDEFS$# define __SOCKE3T_TYPEDEFS 1' typedef unsigned char u_char;( typedef unsigned short u_short;' typedef unsigned long u_long; # endif3# if !defined __U_INT && !defined _DECC_V4_SOURCE# define __U_INT typedef __u_int u_int; # endif# ifndef _DECC_V4_SOURCE" typedef volatile char v_char;# typedef volatile short v_short;" typedef volatile long v_long;# typedef volatile u_char vu_char;$ typedef volatile u_short vu_short;# typedef v4olatile u_long vu_long;A typedef u_char uchar; /* For System III & V portability */ typedef u_short ushort; typedef __u_int uint; typedef u_long ulong; # endif#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __TYPES_LOADED */wwAԗO/***************************************************************5**************/O/* */O/* - time zone information */O/* */O/* This header file is no longer a public header file. This change */O/* was made after DEC C V5.6 was released. Your application should */O/* not require definitions which formally appeared in this header file. * 6/O/* */O/*****************************************************************************/wwBԗ#ifndef __UIO_LOADED#define __UIO_LOADED 1M/******************************************************************************3** - definitions for vector I/O operations**M*****************************************************************************I** Header introduced by the X/Open CAE Specif7ication, Issue 4, Version 2M*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** 8 I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for tech9nical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** : M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*A** All structures should be member aligned on natural boundaries*/!#pragma __member_alignment __save#pragma __member_alignment#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64/*M* 64-bit version of the iovec structure that; is required to be used with the 4* 64-bit interface routines _readv64 and __writev64 */#ifdef _XOPEN_SOURCE_EXTENDED struct __iovec64 { __void_ptr64 iov_base; __size_t iov_len; }; struct __Oiovec64 {#else struct __iovec64 {#endif% __char_ptr64 iov_base; int iov_len;};) typedef struct iovec * __iovec_ptr64;/ typedef struct __iovec64 * __iovec64_ptr64;; typedef const struct __iovec64 * __const_iov<ec64_ptr64;) typedef struct __iovec64 __iovec64_t;# pragma __pointer_size 32/*M* 32-bit version of the iovec structure that is required to be used with the 4* 32-bit interface routines _readv32 and __writev32 */#ifdef _XOPEN_SOURCE_EXTENDED struct __iovec32 { __void_ptr32 iov_base; __size_t iov_len; }; struct __Oiovec32 {#else struct __iovec32 {#endif% __char_ptr32 iov_base; int iov_len;};) = typedef struct iovec * __iovec_ptr32;/ typedef struct __iovec32 * __iovec32_ptr32;; typedef const struct __iovec32 * __const_iovec32_ptr32;) typedef struct __iovec32 __iovec32_t;#endif/*A** Iovec Structure: I/O buffer element for vector I/O operations.**;** The iovec structure describes one scatter/gather buffer.?** Multiple scatter/gather buffer descriptors are stored as an ** array of iovec elements. */#ifdef _XOPEN_SOURCE_EXTENDED struct iovec {= > void *iov_base; /* A pointer to a buffer. % */F __size_t iov_len; /* The size of the buffer to which 6 ** iov_base points % */ }; struct __Oiovec {#else struct iovec {#endif char *iov_base; int iov_len;}; ' typedef struct iovec * __iovec_ptr;3 typedef const struct iovec * __const_iovec_ptr;?#if __CRTL_VER >= 70300000 H__ssize_t writev(int __fildes, const struct iovec *__iov, int __iovcnt);#endif:#if __CRTL_VER >= 70311000 && __INITIAL_POINTER_SIZE == 649#define writev(__P1,__P2,__P3) __writev64(__P1,__P2,__P3)#endif#if __CRTL_VER >= 70311000## if __INITIAL_POINTER_SIZE == 64J __ssize_t readv(int __fildes, __const_iovec64_ptr64 __iov, int __iovcnt);# elseF __ssize_t readv(int __fildes, __const_iovec_ptr __iov, int __iovcnt); # endif#endif4#if __INITIA@L_POINTER_SIZE && __CRTL_VER >= 70311000M __ssize_t _readv32(int __fildes, __const_iovec32_ptr32 __iov, int __iovcnt);O __ssize_t __writev32(int __fildes, __const_iovec32_ptr32 __iov, int __iovcnt);M __ssize_t _readv64(int __fildes, __const_iovec64_ptr64 __iov, int __iovcnt);O __ssize_t __writev64(int __fildes, __const_iovec64_ptr64 __iov, int __iovcnt);#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endifA#ifdef __cplusplus }#endif$#pragma __member_alignment __restore#pragma __standard#endif /* __UIO_LOADED */ww3DBԗ#ifndef __UNISTD_LOADED#define __UNISTD_LOADED 1N/*******************************************************************************6** - Standard symbolic constants and types**N******************************************************************************I** I** B Copyright 2007 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical DataC for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change with Dout notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** N*******************************************************************************/#pragma __nostandard#include #ifdef __cplusplusE extern "C" {!#define __decc$unknown_params ...#else#define __decc$unknown_params#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/* 6** X/Open extended (XPG4) typedefs, new in DEC C V5.n*/ '#if defined _XOPEN_SOURCE_EXTENDED || \: (!defined _POSIX_C_SOURCE && !defined _DECC_V4_SOURCE)# ifndef __USECONDS_T # define __USECONDS_T( typedef __useconds_t useconds_t; # endif#endifF/*H** Create 'public' typedefs that are sensitive to pointer size and mustK** use 32 bit pointers. Create other declarations which are not sensitive** to pointer size.*/ #ifndef NULL# define NULL __NULL#endif/*6** ISO POSIX-1 Defines for the Access() mode argument*/#define F_OK 0#define X_OK 1#define W_OK 2#define R_OK 4/*** ISO POSIX-1 Seek modes.*/#define SEEK_SET 0#define SEEK_CUR 1#define SEEK_END 2/* D** GISO POSIX-1 File descriptor numbers for stdin, stdout and stderr*/ #define STDIN_FILENO 0#define STDOUT_FILENO 1#define STDERR_FILENO 2/*8** ISO POSIX-1 Constants for portability specifications*/P#define _POSIX_VERSION 199506L /* IEEE Std 1003.1c-1995 */P#define _POSIX_JOB_CONTROL (-1) /* Support for job control */P#define _POSIX_SAVED_IDS (-1) /* Save set-user-id,set-group-id */P#define _POSIX_CHOWN_RESTRICTED 1H /* chown requires privilege */P#define _POSIX_NO_TRUNC (-1) /* pathnames are truncated */P#define _POSIX_VDISABLE (-1) /* tcgetattr not supported *//*A** ISO POSIX-1 Symbolic constants for the [f]pathconf() function*/%#define _PC_CHOWN_RESTRICTED 0%#define _PC_LINK_MAX 1%#define _PC_MAX_CANON 2%#define _PC_MAX_INPUT 3%#define _PC_NAME_MAX 4%#define _PC_NO_TRUINC 5%#define _PC_PATH_MAX 6%#define _PC_PIPE_BUF 7%#define _PC_VDISABLE 8/*=** ISO POSIX-1 Symbolic constants for the sysconf() function*/'#define _SC_ARG_MAX 100'#define _SC_CHILD_MAX 101'#define _SC_CLK_TCK 102'#define _SC_NGROUPS_MAX 103'#define _SC_OPEN_MAX 104'#define _SC_STREAM_MAX 105'#define _SC_TZNAME_MAX J106'#define _SC_JOB_CONTROL 107'#define _SC_SAVED_IDS 108'#define _SC_VERSION 1094#if _POSIX_C_SOURCE >= 2 || !defined _POSIX_C_SOURCE /* ( ** ISO POSIX-2 configuration values */ P# define _POSIX2_C_VERSION 199209L /* IEEE Std 1003.2-1992 */P# define _POSIX2_VERSION 199209L /* POSIX.2 standard */P# define _POSIX2_C_BIND 1 /* Support C language binding */P# defiKne _POSIX2_C_DEV (-1) /* Support C development env */P# define _POSIX2_CHAR_TERM 1 /* Support at least one terminal */P# define _POSIX2_FORT_DEV (-1) /* Support FORTRAN development */P# define _POSIX2_FORT_RUN (-1) /* Support FORTRAN runtime */P# define _POSIX2_LOCALEDEF 1 /* Support creation of locales */P# define _POSIX2_SW_DEV (-1) /* Support software development */P# define _POSIX2_UPEL (-1) /* Support User Portability Env */ /* 4 ** ISO POSIX-2 Symbolic constants for sysconf() */ )# define _SC_BC_BASE_MAX 121)# define _SC_BC_DIM_MAX 122)# define _SC_BC_SCALE_MAX 123)# define _SC_BC_STRING_MAX 124)# define _SC_COLL_WEIGHTS_MAX 125(# define _SC_EXPR_NEST_MAX 126)# define _SC_LINE_MAX 127)# define _SC_RE_DUP_MAX 128)# define _SC_2_VMERSION 129)# define _SC_2_C_BIND 130)# define _SC_2_C_DEV 131)# define _SC_2_FORT_DEV 132)# define _SC_2_SW_DEV 133)# define _SC_2_FORT_RUN 134)# define _SC_2_LOCALEDEF 135)# define _SC_2_UPE 136#if __CRTL_VER >= 70301000,# define _SC_GETGR_R_SIZE_MAX 150#endif,# define _SC_GETPW_R_SIZE_MAX 151 /*A ** ISO POSIX-2 Symbolic const Nants for the confstr() function **E ** _CS_MACHINE_IDENT, _CS_PARTITION_IDENT and _CS_MACHINE_SERIALC ** are HP-UX symbolic constants which are available on OpenVMS> ** as of V8.3. On OpenVMS, they correspond to the valuesG ** returned by sys$getsyi() for SYI$_SYSTEM_UID, SYI$_PARTITION_IDH ** and SYI$_SERIAL_NUMBER respectively. Note that SYI$_SYSTEM_UUID< ** returns meaningful information only for I64 systems. */# define _CS_PATH 0# define _CS_MOACHINE_IDENT 1!# define _CS_PARTITION_IDENT 2 # define _CS_MACHINE_SERIAL 3 /*3 ** ISO POSIX-2 option parsing state variables  */# if (__CRTL_VER >= 60200000)## pragma __extern_model __save,# pragma __extern_model __strict_refdef extern int optind; extern int opterr; extern int optopt; extern char *optarg;&# pragma __extern_model __restore # endif#endif9#if _POSIX_C_SOURCE >= 199506 || !defined _POSIXP_C_SOURCE /*0 ** POSIX 1003.1c-1995 configuration values. */C# define _POSIX_THREADS /* 1003.4a (pthreads) comformant */P# define _POSIX_THREAD_ATTR_STACKSIZE /* Support spec stack size */P# define _POSIX_THREAD_PRIORITY_SCHEDULING /* Support realtime scheduling *//*8** Thread-safe ANSI C functions from POSIX 1003.1c not ** implemented at this time.0** # define _POSIX_THREAD_SAFE_FUNCTIONS */ /*; ** POSIX 1003.1c-1995 SymboliQc constants for sysconf() */3# define _SC_THREAD_DESTRUCTOR_ITERATIONS 1403# define _SC_THREAD_KEYS_MAX 1413# define _SC_THREAD_STACK_MIN 1423# define _SC_THREAD_THREADS_MAX 1433# define _SC_THREAD_SAFE_FUNCTIONS 1443# define _SC_THREADS 1453# define _SC_THREAD_ATTR_STACKSIZE 1463# define _SC_THREAD_PRIORITY_SCHEDULING 147#endif5#if defined _XOPEN_SOURCE R|| !defined _POSIX_C_SOURCE /* & ** X/Open configuration variables- */ P# define _XOPEN_VERSION 4 /* XPG4 */P# define _XOPEN_XCU_VERSION -1 /* Version of XCU */P# define _XOPEN_XPG4_EXTENDED -1 /* not fully provided */P# define _XOPEN_CRYPT -1 /* Supports X/Open Encryption FG */P# define _XOPEN_ENH_I18N 1 /* SuSpports Enhanced Internat FG */P# define _XOPEN_SHM -1 /* Supports Shared Memory FG */ /*< ** X/Open Symbolic constants for the sysconf() function */'# define _SC_XOPEN_VERSION 110'# define _SC_PASS_MAX 111'# define _SC_XOPEN_CRYPT 118'# define _SC_XOPEN_ENH_I18N 119'# define _SC_XOPEN_SHM 120#endif>#if defined _XOPEN_SOURCE_EXTENDED || !defined _POSIX_C_SOURCE /*8 ** X/Open Exte Tnded (XPG4 V2) configuration variables */P# define _XOPEN_UNIX 1 /* Supports XSH4 extended feature*/ /* K ** X/Open Extended (XPG4 V2) symbolic constants for sysconf() function */ '# define _SC_PAGESIZE 1170# define _SC_PAGE_SIZE _SC_PAGESIZEG# define _SC_ATEXIT_MAX 138 /* not in POSIX, but in XPG4 */P# define _SC_IOV_MAX 139 /* not in POSIX, but in XPG4 */ '# define _SC_XOPEN_UNIX U 148#endif/* ** DEC C extensions*/ #ifndef _POSIX_C_SOURCE /*  ** Constants for sysconf() */  /*5 ** definitions for the MP extensions to sysconf() */# define _SC_NPROC_CONF 200.# define _SC_NPROCESSORS_CONF _SC_NPROC_CONF# define _SC_NPROC_ONLN 201.# define _SC_NPROCESSORS_ONLN _SC_NPROC_ONLN0# define _SC_2_C_VERSION _SC_2_VERSION'# define _SC_2_CHAR_TERM 137# ifdef __NOT_YET_IMPLEMENTED'V# define _SC_DELAYTIMER_MAX 112'# define _SC_TIMER_MAX 113'# define _SC_MAPPED_FILES 114'# define _SC_FSYNC 115'# define _SC_TIMERS 116 # endif# if __CRTL_VER >= 80300000'# define _SC_CPU_CHIP_TYPE 160 # endif /*9 ** Symbolic constants for the [f]pathconf() function */# ifdef __NEED_MORE_INFO%# define _PC_ASYNC_IO 9&# define _PC_PRIO_IO 10&# defiWne _PC_SYNC_IO 11 # endif#endif/* ** ISO POSIX-1 typedefs*/ 2#if !defined __SIZE_T && !defined _DECC_V4_SOURCE# define __SIZE_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __size_t size_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::size_t;#endif#endif3#if !defined __SSIZE_T && !defined _DECC_V4_SOURCE# define __SSIZE_T 1 typedef __ssize_t ssize_t;#endif/* ** X/Open (XPG4) typedefs*/ #if deXfined _XOPEN_SOURCE || \: (!defined _POSIX_C_SOURCE && !defined _DECC_V4_SOURCE)# ifndef __GID_T# define __GID_T 1 typedef __gid_t gid_t; # endif# ifndef __OFF_T# define __OFF_T 1 typedef __off_t off_t; # endif# ifndef __PID_T# define __PID_T 1 typedef __pid_t pid_t; # endif# ifndef __UID_T# define __UID_T 1 typedef __uid_t uid_t; # endif#endif/* =** ISO POSIX-2 functions that do Ynot support 64-bit pointers*/ 4#if _POSIX_C_SOURCE >= 2 || !defined _POSIX_C_SOURCEJ# if __CRTL_VER >= 60200000 /* Supported starting with OpenVMS V6.2 */O int getopt (int __argc, char * const __argv[], const char *__optstring); # endif#endif/*M** We are done defining things which must always be 32 bit pointers. If theL** user has used /pointer_size=32 or /pointer_size=64, we will allow 64 bit*** pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZZE# pragma __pointer_size 64#endif /* #** ISO POSIX-1 function prototypes*/ #if __USE_LONG_GID_T!# pragma __extern_prefix __save(# pragma __extern_prefix "__long_gid_"#endif5int access (const char *__file_spec, int __mode);#if __USE_LONG_GID_T$# pragma __extern_prefix __restore#endifint close (int __file_desc);1int dup2 (int __file_desc1, int __file_desc2);int dup (int __file_desc);4#if defined _XOPEN_SOURC[E || !defined _ANSI_C_SOURCE#if __CRTL_VER >= 80300000+void encrypt(char __block[64], int edflag);4char *crypt (const char *__key, const char *__salt);#endif#endif@int execv (const char *__path, __char_ptr_const_ptr32 __argv);_int execve (const char *__path, __char_ptr_const_ptr32 __argv, __char_ptr_const_ptr32 __envp);@int execvp (const char *__file, __char_ptr_const_ptr32 __argv);int isatty (int __file_desc);#if __USE_OFF64_T!# pragma __extern_prefix __save%# pragma _\_extern_prefix "__off64_"#endifC__off_t lseek (int __file_desc, __off_t __offset, int __direction);#if __USE_OFF64_T$# pragma __extern_prefix __restore#endifint pause (void);#ifdef _POSIX_C_SOURCE & int pipe (int __array_fdscptr[2]);#else+ int pipe (int __array_fdscptr[2], ...);#endifint rmdir (const char *__path);#if __USE_LONG_GID_T!# pragma __extern_prefix __save(# pragma __extern_prefix "__long_gid_"#endif__gid_t getegid (void);__gi]d_t getgid (void);#if __USE_LONG_GID_T$# pragma __extern_prefix __restore#endif#if __CRTL_VER >= 70301000# if __USE_LONG_GID_T$# pragma __extern_prefix __save+# pragma __extern_prefix "__long_gid_" # endif4int getgroups( int gidsetsize, __gid_t grouplist[]);# if __USE_LONG_GID_T'# pragma __extern_prefix __restore # endif#endif__pid_t getpid (void);__pid_t getppid (void);6#if __CRTL_VER >= 70000000 && !defined(_VMS_V6_SOURCE)# ^ if __CAN_USE_EXTERN_PREFIX$# pragma __extern_prefix __save(# pragma __extern_prefix "__posix_"# else-# define _exit(__p1) __posix__exit(__p1) # endif#endifvoid _exit (int status);6#if __CRTL_VER >= 70000000 && !defined(_VMS_V6_SOURCE)# if __CAN_USE_EXTERN_PREFIX'# pragma __extern_prefix __restore # endif#endif#if __USE_LONG_GID_T!# pragma __extern_prefix __save(# pragma __extern_prefix "__long_gid_"8#elif __CRTL_VER >= 70000000 && !d_efined(_VMS_V6_SOURCE)# if __CAN_USE_EXTERN_PREFIX$# pragma __extern_prefix __save'# pragma __extern_prefix "__unix_"# else## define geteuid() __unix_geteuid()!# define getuid() __unix_getuid() # endif#endif__uid_t geteuid (void);__uid_t getuid (void);#if __USE_LONG_GID_T$# pragma __extern_prefix __restore8#elif __CRTL_VER >= 70000000 && !defined(_VMS_V6_SOURCE)# if __CAN_USE_EXTERN_PREFIX'# pragma __extern_prefix __restore # endif#endif`/* ** X/Open functions */ >#if defined _XOPEN_SOURCE_EXTENDED || !defined _POSIX_C_SOURCE# if defined _DECC_V4_SOURCE7 int gethostname (char *__name, int __namelen); # else< int gethostname (char *__name, __size_t __namelen); # endif#endif#if __CRTL_VER >= 70301000: int getlogin_r (__char_ptr64 name, __size_t namesize);#endif/*:** The following functions always return a 32 bit pointer*/#if __CRTL_VER >= 70000000 ! __char_ptr32a getlogin (void);#endif-#if __CRTL_VER >= 70320000 && __POSIX_TTYNAME< __char_ptr32 ttyname(int fd); /* Enforces 1 argument */#endif#if __CRTL_VER >= 70320000 > int ttyname_r(int __fd, __char_ptr64 __buffer, int __len);#endif/* >** X/Open Extended functions always returning 32 bit pointers*/ ?#if defined _XOPEN_SOURCE_EXTENDED || !defined _POSIX_C_SOURCE ( __void_ptr32 sbrk (long int __incr);#endif/*O** The following functions have interfaces of XXX, _XbXX32, and _XXX64 due onlyM** to the fact that the return argument is a pointer that is relative to one** of the arguments.*/ #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 32#endif/* ISO POSIX-1 functions */char *ctermid (char *__str);5#if defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCE char *cuserid (char *__str);#endif#ifdef _POSIX_C_SOURCE 3 char *getcwd (char *__buffer, __size_t __size);#else< char *getcwd (char *__buffer, unsigned int _c_size, ...);#endif #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 64#endif#if __INITIAL_POINTER_SIZE# pragma __pointer_size 32$ char *_ctermid32 (char *__str);$ char *_cuserid32 (char *__str);A char *_getcwd32 (char *__buffer, unsigned int __size, ...);#if __CRTL_VER >= 80300000< char *_crypt32 (const char *__key, const char *__salt);#endif# pragma __pointer_size 64$ char *_ctermid64 (char *__str);$ char *_cuserid64 (char *__str);@d char *_getcwd64 (char *__buffer, unsigned int __size, ...);#if __CRTL_VER >= 80300000< char *_crypt64 (const char *__key, const char *__salt);#endif#endif/* I** DEC C V5.2 changed the prototypes to ISO POSIX-1 definitions in a wayH** that was binary upward compatible but not source upward compatibile.G** The old definitions are retained for compatibility with old source.*/ #ifndef _DECC_V4_SOURCE#if __USE_LONG_GID_T!# pragma __extern_prefix __save(# pragmae __extern_prefix "__long_gid_"#endifJ int chown (const char *__file_spec, __uid_t __owner, __gid_t __group);0# if !defined(__VAX) && __CRTL_VER >= 70301000M int lchown (const char *__file_spec, __uid_t __owner, __gid_t __group); # endif int setgid (__gid_t); int setuid (__uid_t);#if __USE_LONG_GID_T$# pragma __extern_prefix __restore#endif0 unsigned int alarm (unsigned int __seconds);H __ssize_t read (int __file_desc, void *__buffer, __size_t __ fnbytes);O __ssize_t write (int __file_desc, const void *__buffer, __size_t __nbytes);: int execl (const char *__path, const char *arg0, ...);; int execle (const char *__path, const char *arg0, ...);; int execlp (const char *__path, const char *arg0, ...);, unsigned int sleep (unsigned __seconds);0# if !defined(__VAX) && __CRTL_VER >= 703010009 int symlink (const char *path1, const char *path2);C int readlink (const char *path, char *buf, __size_t bufsize); # g endif#else' int alarm (unsigned int __seconds);T int chown (const char *__file_spec, unsigned int __owner, unsigned int __group);0# if !defined(__VAX) && __CRTL_VER >= 70301000W int lchown (const char *__file_spec, unsigned int __owner, unsigned int __group);9 int symlink (const char *path1, const char *path2);> int readlink (const char *path, char *buf, int bufsize); # endif= int read (int __file_desc, void *__buffer, int __nbytes);> int writhe (int __file_desc, void *__buffer, int __nbytes);" int execl (char *__name, ...);# int execle (char *__name, ...);# int execlp (char *__name, ...); __gid_t setgid (__gid_t); __uid_t setuid (__uid_t);# int sleep (unsigned __seconds);#endif#if __CRTL_VER >= 70000000. long int fpathconf (int __fd, int __name);8 long int pathconf (const char * __path, int __name);" long int sysconf (int __name);$ int unlink (const char *__path);#endif/* #** iISO POSIX-2 function prototypes*/ 4#if _POSIX_C_SOURCE >= 2 || !defined _POSIX_C_SOURCE# if __CRTL_VER >= 70000000C __size_t confstr (int __name, char * __buf, __size_t __len); # endif#endif/* %** X/Open (XPG4) function prototypes*/5#if defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCE int fsync (int __file_desc); int nice (int __increment);# if __CRTL_VER >= 70000000H void swab (const void * __src, void * __dst, __ssize_t __nbytes); # enjdif# if __CRTL_VER >= 70300000# if __USE_LONG_GID_T!# pragma __extern_prefix __save(# pragma __extern_prefix "__long_gid_" # endifC int fchown (int __fildes, __uid_t __owner, __gid_t __group);# if __USE_LONG_GID_T$# pragma __extern_prefix __restore # endif # endif0# if !defined(__VAX) && __CRTL_VER >= 70301000< int link (const char *__existing, const char *__new); # endif# if __USE_LONG_GID_T! __pid_t getpgid (k__pid_t); __pid_t getpgrp (void); __pid_t getsid (__pid_t); int seteuid (__uid_t);& int setpgid (__pid_t, __pid_t); __pid_t setpgrp (void);' int setregid (__gid_t, __gid_t);' int setreuid (__uid_t, __uid_t); __pid_t setsid (void); # endif#endif/* 1** X/Open extended (XPG4 V2) function prototypes*/ ?#if defined _XOPEN_SOURCE_EXTENDED || !defined _POSIX_C_SOURCE # if __CRTL_VER >= 70000000 # if __USE_OFF6l4_T'# pragma __extern_prefix __save+# pragma __extern_prefix "__off64_" # endif8 int ftruncate (int __filedes, __off_t __length );= int truncate (const char *__path, __off_t __length );# if __USE_OFF64_T*# pragma __extern_prefix __restore # endif int getdtablesize (void); int getpagesize (void);N __useconds_t ualarm (__useconds_t __useconds, __useconds_t __interval);, int usleep (__useconds_t __useconmds); # endif# if defined(__ALPHA)G# define lib$get_current_invo_context LIB$GET_CURRENT_INVO_CONTEXT3 __int64_ptr32 decc$$get_vfork_jmpbuf (void);## ifdef __INITIAL_POINTER_SIZE,# pragma __required_pointer_size __save,# pragma __required_pointer_size __long # endifA int LIB$GET_CURRENT_INVO_CONTEXT(__int64 *__invo_context);## ifdef __INITIAL_POINTER_SIZE/# pragma __required_pointer_size __restore # endif+ int n decc$$alloc_vfork_blocks (void);:# define vfork() (decc$$alloc_vfork_blocks() >= 0 ? \C lib$get_current_invo_context(decc$$get_vfork_jmpbuf()) : -1)# elif defined(__ia64)3 __int64_ptr32 decc$$get_vfork_jmpbuf (void);+ int decc$$alloc_vfork_blocks (void);) int decc$setjmp1 (__int64 *__env);:# define vfork() (decc$$alloc_vfork_blocks() >= 0 ? \3 decc$setjmp1(decc$$get_vfork_jmpbuf()) : -1)# else# ifndef _DECC_V4_SOURCE __poid_t vfork (void); # else int vfork (void); # endif # endif#endif/* ** DEC C extensions**;** chdir has an additional parameter as a DEC C extension.*/ #ifdef _POSIX_C_SOURCE' int chdir (const char *__dir_spec);#else, int chdir (const char *__dir_spec, ...);#endif>#if defined _XOPEN_SOURCE_EXTENDED || !defined _ANSI_C_SOURCE/*** XPG5 extentions*/# if __CRTL_VER >= 80300000# if __USE_OFF64_T"# pragma __extern_prepfix __save&# pragma __extern_prefix "__off64_"# endifG__ssize_t pread(int fildes, void *buf, __size_t nbyte, __off_t offset);N__ssize_t pwrite(int fildes, const void *buf, __size_t nbyte, __off_t offset);# if __USE_OFF64_T$# pragma __extern_prefix __restore# endif# else# if __CRTL_VER >= 70311000G__ssize_t pread(int fildes, void *buf, __size_t nbyte, __off_t offset);N__ssize_t pwrite(int fildes, const void *buf, __size_t nbyte, __off_t offset);# endif# endif#endqif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __UNISTD_LOADED */wwCԗ#ifndef __UNIXIO_LOADED#define __UNIXIO_LOADED 1N/*******************************************************************************8** - Prototypes for UNIX emulation functions**N**************************************************************** r**************** Header is nonstandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I**s I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be ltiable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** u M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif0#include /* Definition of rename */=#include /* Definition of stat, fstat, stat_t */#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/* ** Types shared with */ 2#if !dvefined __SIZE_T && !defined _DECC_V4_SOURCE# define __SIZE_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __size_t size_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::size_t;#endif#endif3#if !defined __SSIZE_T && !defined _DECC_V4_SOURCE# define __SSIZE_T 1 typedef __ssize_t ssize_t;#endif2#if !defined __MODE_T && !defined _DECC_V4_SOURCE# define __MODE_T 1 typedef __mode_t mode_t;#endif1#if !defined __UID_T && !defiwned _DECC_V4_SOURCE# define __UID_T 1 typedef __uid_t uid_t;#endif1#if !defined __GID_T && !defined _DECC_V4_SOURCE# define __GID_T 1 typedef __gid_t gid_t;#endif1#if !defined __OFF_T && !defined _DECC_V4_SOURCE# define __OFF_T 1 typedef __off_t off_t;#endif/**** Defines for the Access() mode argument*/#define F_OK 0#define X_OK 1#define W_OK 2#define R_OK 4/*J** Functions which return pointers into CRTL owned memory always return a>x** short pointer, regardless of application compilation mode.*/-#if __CRTL_VER >= 70320000 && __POSIX_TTYNAME9 char *ttyname(int fd); /* Enforces 1 argument */#elseI char *ttyname(); /* Legacy supports zero or 1 arguments */#endif/*L** We are done defining things which must always be short pointers. If theO** user has used /pointer_size=short or /pointer_size=long, we will allow long*** pointers to be used in function calls.*/#if __INITIAL_POINTEyR_SIZE# pragma __pointer_size 64#endif/*8** Functions which accept either 32 or 64 bits pointers*/#if __USE_LONG_GID_T!# pragma __extern_prefix __save(# pragma __extern_prefix "__long_gid_"#endif2int access (const char *__file_spec, int __mode);7int chmod (const char *__file_spec, __mode_t __mode);#if __USE_LONG_GID_T$# pragma __extern_prefix __restore#endifint close (int __file_desc);int dup (int __file_desc);1int dup2 (int __file_desc1, iznt __file_desc2);int isapipe (int __file_desc);int isatty (int __file_desc);#if __USE_OFF64_T!# pragma __extern_prefix __save%# pragma __extern_prefix "__off64_"#endifC__off_t lseek (int __file_desc, __off_t __offset, int __direction);#if __USE_OFF64_T$# pragma __extern_prefix __restore#endif/* I** The function open in DEC C V4.0 had a required mode_t parameter if inI** strict ANSI mode. This is not standard conforming, so it it here for** compatibil{ity only.*/ =#if defined _DECC_V4_SOURCE && defined __HIDE_FORBIDDEN_NAMESJ int open (const char *__file_spec, int __flags, __mode_t __mode, ...);#else9 int open (const char *__file_spec, int __flags, ...);#endif/* N** DEC C V5.2 changed the prototypes to ISO POSIX-1 definitions in a way thatL** was binary upward compatible but not source upward compatibile. The old>** definitions are retained for compatibility with old source*/ #ifndef _DECC_V4_SOURCE#if __|USE_LONG_GID_T!# pragma __extern_prefix __save(# pragma __extern_prefix "__long_gid_"#endifK int chown (const char *__file_spec, __uid_t __owner, __gid_t __group);#if __USE_LONG_GID_T$# pragma __extern_prefix __restore#endifJ __ssize_t read (int __file_desc, void *__buffer, __size_t __nbytes);P __ssize_t write (int __file_desc, const void *__buffer, __size_t __nbytes);#elseT int chown (const char *__file_spec, unsigned int __owner, unsigned int __group);>} int read (int __file_desc, void *__buffer, int __nbytes);> int write (int __file_desc, void *__buffer, int __nbytes);#endif/* K** DEC C extensions which have additional parameters as a DEC C extension.*/ #ifdef _POSIX_C_SOURCE' int chdir (const char *__dir_spec);9 int creat (const char *__file_spec, __mode_t __mode);#else, int chdir (const char *__dir_spec, ...);> int creat (const char *__file_spec, __mode_t __mode, ...);#endif/*3** The followin~g function is not available in C++.*/#ifndef __cplusplus( int delete(const char *__file_spec);#endif/*O** The following functions have interfaces of XXX, _XXX32, and _XXX64 due onlyM** to the fact that the return argument is a pointer that is relative to one** of the arguments.*/ #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 32#endif9 char *getname (int __file_desc, char *__buffer, ...);% char *mktemp (char *__template);4#if __INITIAL_POINTER_SIZE && __CRTL_VER >= 70000000# pragma __pointer_size 32( char *_getname32 (int, char *, ...); char *_mktemp32 (char *);# pragma __pointer_size 64( char *_getname64 (int, char *, ...); char *_mktemp64 (char *);#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __UNIXIO_LOADED */ww6OCԗ#ifndef __UNIX LIB_LOADED#define __UNIXLIB_LOADED 1M/******************************************************************************9** - Prototypes for UNIX emulation functions**M******************************************************************************* Header is nonstandardM*****************************************************************************I** I** Copyright 2006 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*F** The environ array is always composed of a list of 32 bit addresses*/#if !defined(__VAX)$# define environ (decc$ga_environ)#else%# define environ (*decc$ga_environ)#endif#pragma __extern_model __save&#pragma __extern_model __strict_refdef= extern char **environ; /* Only minimally supported */ #pragma __extern_model __restore/* 3** Types shared with that are used later*/ 2#if !defined __MODE_T && !defined _DECC_V4_SOURCE# define __MODE_T 1 typedef __mode_t mode_t;#endif1#if !defined __UID_T && !defined _DECC_V4_SOURCE# define __UID_T 1 typedef __uid_t uid_t;#endifM#if !defined __SIZE_T && !defined _DECC_V4_SOURCE && defined _POSIX_C_SOURCE# define __SIZE_T 1#ifdef __NAMESPACE_STDnamespace std {#endif typedef __size_t size_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::size_t;#endif#endif1#if !defined __GID_T && !defined _DECC_V4_SOURCE# define __GID_T 1 typedef __gid_t gid_t;#endif1#if !defined __PID_T && !defined _DECC_V4_SOURCE# define __PID_T 1 typedef __pid_t pid_t;#endif/* 7** Constants and prototypes for former SHELL$ routines */# define DECC$K_FOREIGN 0# define DECC$K_FILE 1# define DECC$K_DIRECTORY 2/* K** SHELL$ prototypes are provided for backward compatibility. Use of the #** decc$* routi nes is recommended.*/J#define SHELL$TO_VMS(__s,__a,__n1,__n2) decc$to_vms(__s,__a,__n1,__n2)F#define SHELL$FROM_VMS(__s,__a,__n) decc$from_vms(__s,__a,__n)F#define SHELL$MATCH_WILD(__s1,__s2) decc$match_wild(__s1,__s2)>#define SHELL$FIX_TIME(__n) decc$fix_time(__n)C#define SHELL$TRANSLATE_VMS(__s) decc$translate_vms(__s)J#define shell$to_vms(__s,__a,__n1,__n2) decc$to_vms(__s,__a,__n1,__n2)F#define shell$from_vms(__s,__a,__n) decc$from_vms(__s,__a,__n)F#define shell$match_wild(__s1,__s2) decc$match_wild(__s1,__s2)>#define shell$fix_time(__n) decc$fix_time(__n)C#define shell$translate_vms(__s) decc$translate_vms(__s)/*D** These former SHELL$ routines are unavailable on Alpha/VMS. Also(** SHELL$GET_ARGV, and SHELL$$RMS_PARSE*/#if !defined(__VAX)# define SHELL$IS_SHELL() (0) # define SHELL$CLI_NAME(_x) (0)#endif /*M** The callback routines for the decc$to_vms and decc$from_vms functions are#** always passed 32 bit addresses.*//typedef int (*__to_vms_callback) (char *, int);,typedef int (*__from_vms_callback) (char *);/*M** We are done defining things which must always be 32 bit pointers. If theL** user has used /pointer_size=32 or /pointer_size=64, we will allow 64 bit*** pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*O** The following functions have interfaces of XXX, _XXX32, and _XXX64 due onlyM** to the fact that the return argument is a pointer that is relative to one** of the arguments.*/ #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 32#endif#if defined _POSIX_C_SOURCE 2 char *getcwd(char *__buffer, __size_t __size);#else; char *getcwd(char *__buffer, unsigned int __size, ...);#endif9char *gcvt(double __value, int __ndigit, char *__buffer); #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 64#endif#if __INITIAL_POINTER_SIZE# pragma __pointer_size 32? char *_getcwd32 (char *__buffer, unsigned int __size, ...);C char *_gcvt32 (double __value, int __ndigit, char *__buffer);# pragma __pointer_size 64? char *_getcwd64 (char *__buffer, unsigned int __size, ...);C char *_gcvt64 (double __value, int __ndigit, char *__buffer);#endif/*** Function prototypes*/N__char_ptr32 ecvt (double __value, int __ndigit, int *__decpt, int *__sign);N__char_ptr32 fcvt  (double __value, int __ndigit, int *__decpt, int *__sign);)__char_ptr32 getenv (const char *__name);#if defined _POSIX_C_SOURCE 8 int mkdir (const char *__dir_spec, __mode_t __mode);#else= int mkdir (const char *__dir_spec, __mode_t __mode, ...);#endif#if __USE_LONG_GID_T!# pragma __extern_prefix __save(# pragma __extern_prefix "__long_gid_"8#elif __CRTL_VER >= 70000000 && !defined(_VMS_V6_SOURCE)!# ifdef __CAN_USE_EXTERN_PREFIX$# pragma __extern_prefix __save'# pragma __extern_prefix "__unix_"# else)# define geteuid() __unix_geteuid()(# define getuid() __unix_getuid() # endif#endif__uid_t geteuid (void);__uid_t getuid (void);#if __USE_LONG_GID_T$# pragma __extern_prefix __restore8#elif __CRTL_VER >= 70000000 && !defined(_VMS_V6_SOURCE)!# ifdef __CAN_USE_EXTERN_PREFIX'# pragma __extern_prefix __restore # endif#endif#if __USE_LONG_GID_T!# pragma __extern_prefix __save(# pragma __extern_prefix "__long_gid_"#endif__gid_t getgid (void);__gid_t getegid (void);#if __USE_LONG_GID_T$# pragma __extern_prefix __restore#endif__pid_t getpid (void);__pid_t getppid (void);/* I** DEC C V5.2 changed the prototypes to ISO POSIX-1 definitions in a wayH** that was binary upward compatible but not source upward compatibile.G** The old definitions are retained for compatibility with old source.*/ #ifndef _DECC_V4_SOURCE#if __USE_LONG_GID_T!#  pragma __extern_prefix __save(# pragma __extern_prefix "__long_gid_"#endif int setgid (__gid_t); int setuid (__uid_t);#if __USE_LONG_GID_T$# pragma __extern_prefix __restore#endif#else __gid_t setgid (__gid_t); __uid_t setuid (__uid_t);#endif# extern int DECC$$GL___CRTL_VER;2# define decc$$gl___crtl_ver DECC$$GL___CRTL_VER#if __CRTL_VER >= 70301000( extern int DECC$$GL___VMS_VER_BUILD;<# define decc$$gl___vms_ver_build DECC$$GL___VMS_VER_BUILD) extern int DECC$$GL___CRTL_VER_BUILD;># define decc$$gl___crtl_ver_build DECC$$GL___CRTL_VER_BUILD int decc$getmain_argc(void);- __char_ptr_ptr32 decc$getmain_argv(void);6 __char_ptr32 decc$feature_get_name (int __index);> int decc$feature_get_index (const char *__feature_name);/*7** Several decc$feature functions take a mode argument:*/##define __FEATURE_MODE_DEFVAL 0##define __FEATURE_MODE_CURVAL 1##define __FEATURE_MODE_MINVAL 2##define __FEATURE_MODE_MAXVAL 3%#define __FEATURE_MODE_INIT_STATE 4%#define __FEATURE_MODE_SYSDEFVAL 5%#define __FEATURE_MODE_GRPDEFVAL 6 #define __FEATURE_MODE_GRP 7"#define __FEATURE_MODE_RESET 8#if __CRTL_VER >= 70321000 /*I ** Acts on DECC$* feature logicals, parameter is feature name string. */9 int decc$feature_get(const char* __name, int __mode);F int decc$feature_set(const char* __name, int __mode, int __value);. int decc$fea ture_show(const char* __name);$ int decc$feature_show_all(void);#endif; int decc$feature_get_value (int __index, int __mode);H int decc$feature_set_value (int __index, int __mode, int __value);& int decc$get_filespec_style(void);- int decc$set_filespec_style(int __style);q int decc$to_vms (const char *__filename, __to_vms_callback, int __allow_wild, int __no_directory, ...);] int decc$from_vms (const char *__filename, __from_vms_callback, int __allow_wild, ...);#elsel int decc$to_vms (const char *__filename, __to_vms_callback, int __allow_wild, int __no_directory);X int decc$from_vms (const char *__filename, __from_vms_callback, int __allow_wild);#endifFint decc$set_child_standard_streams (int __fd0, int __fd1, int __fd2);#if __CRTL_VER >= 703110001int decc$set_child_default_dir(const char * dir);#endif%int decc$write_eof_to_mbx (int __fd);'int decc$validate_wchar (__wchar_t wc);5int decc$match_wild (char *__text, char *__pattern); >__char_ptr32 decc$translate_vms (const char *__vms_filespec );.unsigned int decc$fix_time (void *__vms_time);/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __UNIXLIB_LOADED */wwCԗ#ifndef __UTIME_LOADED#define __UTIME_LOADED 1N/********************************************************************* **********4** - utimbuf structure and utime function**N******************************************************************************1** Header introduced by the ISO POSIX-1 StandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I**  I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license.  I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products.  Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif#ifndef __TIME_T# define __TIME_T#ifdef __NAMESPACE_STDnamespace std {#endif typedef __time_t time_t;#ifdef __NAMESPACE_STD} /* namespace std */ using std::time_t;#endif#endifstruct utimbuf {& __time_t actime; /* access time */- __time_t modtime; /* modification time */};/*C** If the user has used /pointer_size=short or /pointer_size=long,=** we will allow long pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endif#if __CRTL_VER >= 70300000 # if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __save*# pragma __extern_prefix "__utc_" # else:# define utime(__p1,__p2) __utc_utime(__p1,__p2) # endif # endif=int utime(const char *__path, const struct utimbuf *__times);# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX+# pragma __extern_prefix __restore # endif # endif#endif/* %** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __UTIME_LOADED */wwCԗ#ifndef __UTSNAME_LOADED#define __UTSNAME_LOADED 1#pragma __nostandard#include N#if __CRTL_VER >= 70000000 /**** Supported starting with OpenVMS V7.0 ****/M/******************************************************************************&** - User informa tion**M*****************************************************************************1** Header introduced by the ISO POSIX-1 StandardM*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I**  I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#ifdef __cplusplus extern "C" {#endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*** Define the structure */!#pragma __member_alignment __save#pragma __member_alignmentstruct utsname{ 4 char sysname [31+1]; /* "OpenVMS" */G char release [31+1]; /* "0" */G char version [31+1]; /* Version of the hosting OpenVMS */G char machine [31+1]; /* Hardware name, with spaces replaced */G /* by undercores */G char nodename[1024+1]; /* DECnet node name */#ifndef _POSIX_C_SOURCEE char arch [15+1]; /* Architecture ("VAX" or "Alpha") */ char __spare [256+1];#else char __spare [15+1+256+1];#endif};$#pragma __member_alignment __restore/*M** We are done defining things which must always be 32 bit pointers. If theL** user has used /pointer_size=32 or /pointer_size=64, we will allow 64 bit*** pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*** Function prototypes*/$int uname (struct utsname * __name); /*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#endif /* __UTSNAME_LOADED */#pragma __standard #endif /* __CRTL_VER */ww Dԗ#ifndef __VARARGS_LOADED#define __VARARGS_LOADEDM/******************************************************************************0** - variable length argument lists**M*****************************************************************************>** Header introduced by the X/Open CAE Specification, Issue 4M*****************************************************************************I** I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I**  I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty.  I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*M** The header files VARARGS.H and STDARG.H cannot be used together; undo the** effects of VARARGS.H.*/#ifdef __STDARG_LOADED# undef __STDARG_LOADED# undef __STDARG_PROCESSED# undef va_start# undef va_arg# undef va_end#endif/*** Declare a va_list */#ifndef __VA_LIST# define __VA_LIST#ifdef __NAMESPACE_STDnamespace std {#endif typedef __va_list va_list;#ifdef __NAMESPACE_STD} /* namespace std */ using std::va_list;#endif#endif#define va_dcl int va_alist;#if !defined(__VAX)"# define va_start_1(ap, offset) \N ap = (__va_list) ((__char_ptr32) __VA_START_BUILTIN(va_alist) + (offset))# define va_start(ap)  \2 ap = (__va_list) __VA_START_BUILTIN(va_alist)# if __X_FLOATO# if defined(__va_arg_no_comma) || (defined(__cplusplus) && defined(__ia64))E /* Linux-style definition of va_arg, without comma operator */H# define va_arg(ap, type) (__IS_X_FLOAT_BUILTIN(type) ? \H (* ((type **) \H ((__char_ptr32)(ap = (__va_list) ((__char_ptr32) ap + \H ((sizeof(long double *) + 7) & ~7))) -  \H ((sizeof(long double *) + 7) & ~7)))[0]) \H : \H ( ((type *) \H ((__char_ptr32)(ap = (__va_list) ((__char_ptr32) ap + \H ((sizeof(type) + 7) & ~7))) - \H ((sizeof(type) + 7) & ~7)))[0]) \ ) # elseA /* VMS-styl e definition of va_arg, using comma operator */!# define va_arg(ap, type) (\0 ap = (__va_list) ((__char_ptr32) ap + \` (((__IS_X_FLOAT_BUILTIN(type) ? sizeof(long double *) : sizeof(type)) + 7) & ~7)), \* __IS_X_FLOAT_BUILTIN(type) ? \/ (** (type **)((__char_ptr32) ap - \Z (((__IS_X_FLOAT_BUILTIN(type) ? sizeof(long double *) : sizeof(type)) + 7) & ~7))) : \/ ( * (type *)((__char_ptr32) ap - \X (((__IS_X_FLOAT_BUILTIN(type) ? sizeof(long double *) : sizeof(type)) + 7) & ~7))) ) # endif# else# define va_arg(ap, type) (\E ap = (__va_list) ((__char_ptr32) ap + ((sizeof (type) + 7) & ~7)), \H (* (type *)((__char_ptr32) ap - ((sizeof (type) + 7) & ~7)))) # endif#else' void decc$va_count( int *__count );/# if defined(__cplusplus) || !defined(__DECC)5# define va_count(count) decc$va_count (&count)&# define va_start_1(ap, offset) \8 ap = (__va_list) ((__char_ptr32) &va _alist + (offset))# define va_start(ap) \ ap = (__va_list) &va_alist!# define va_arg(ap, type) (\F ap = (__va_list) ((__char_ptr32) ap + ((sizeof (type) + 3) & ~3)), \H * (type *) ((__char_ptr32) ap - ((sizeof (type) + 3) & ~3))) # elseM# define va_count(count) (__VA_START_BUILTIN(), decc$va_count (&count))&# define va_start_1(ap, offset) \! ap = (__VA_START_BUILTIN(), \= (__va_list) ((__char_ptr32) &va_alist + (offset)))# define va_start(ap) \3 ap = (__VA_START_BUILTIN(),(__va_list) &va_alist) # define va_arg(ap, type) \ (__VA_START_BUILTIN(),(\F ap = (__va_list) ((__char_ptr32) ap + ((sizeof (type) + 3) & ~3)), \I * (type *) ((__char_ptr32) ap - ((sizeof (type) + 3) & ~3)))) # endif#endif&#define va_end(ap) ap = (__va_list) 0/* ** DEC C extensions*/#ifndef _XOPEN_SOURCE# if !defined(__VAX). unsigned int __VA_COUNT_BUILTIN(void);=# define va_count(count) (count = __VA_COUNT_BUILTIN())# else+ void decc$va_count( int *__count );3# if defined(__cplusplus) || !defined(__DECC)8# define va_count(count) decc$va_count (&count) # elseP# define va_count(count) (__VA_START_BUILTIN(), decc$va_count (&count)) # endif # endif#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __VARARGS_LOADED */ww4Dԗ VMS_V84-005ww9ZDԗ#ifndef __WAIT_LOADED#define __WAIT_LOADED 1#pragma __nostandard#include #if __CRTL_VER >= 60100000M/******************************************************************************3** - Declarations for process waiting**M*****************************************************************************1** Header introduced by the ISO POSIX-1 StandardM*****************************************************************************I**  I** Copyright 2003 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty  of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#ifdef __cplusplus extern "C" {#endif/*K** Create 'public' typedefs that are either insensitive to pointer size or>** are sensitive to pointer size and must use short pointers.*/K#if !defined __PID_T && (defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCE)# define __PID_T 1 typedef __pid_t pid_t;#endif/* (** X/Open extended (XPG4 V2) extensions*/ >#if defined _XOPEN_SOURCE_EXTENDED || !defined _POSIX_C_SOURCE /* + ** pid_t, the same as in  */ #  ifndef __PID_T# define __PID_T 1 typedef __pid_t pid_t; # endif#endif#if __CRTL_VER >= 70000000/* <** Includes needed in X/Open extended (XPG4 V2) compilation*/ >#if defined _XOPEN_SOURCE_EXTENDED || !defined _POSIX_C_SOURCE.# include /* for siginfo_t */3# include /* for struct rusage */#endif/*K** Ensure that regardless of user /pointer_size usage, we begin processing#** using a 32 bit pointer context.*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*** Member align structures*/!#pragma __member_alignment __save#pragma __member_alignment/* $** Symbolic constants for waitpid()*/ #define WNOHANG 1#define WUNTRACED 2/* 0** Macros for analysis of process status values*/ '# define WIFEXITED(s) (((s)&0x7F)==0)'# define WEXITSTATUS(s) (((s)>>8)&0xFF)A# define WIFSTOPPED(s) (((s)&0xFF)==0x7F) /* not implemented */'# define WSTOPSIG(s) (((s)>>8)&0xFF)9# define WIFSIGNALED(s) (((unsigned)(((s)&0x7F)-1))<0x7E)"# define WTERMSIG(s) ((s)&0x7F)/* (** X/Open extended (XPG4 V2) extensions*/ >#if defined _XOPEN_SOURCE_EXTENDED || !defined _POSIX_C_SOURCE# define WCONTINUED 4# define WNOWAIT 8C# define WIFCONTINUED(s) (((s)&0xFF)==0xff) /* not implemented */ /* " ** Options argument to waitid */ # define WEXITED 3# define WSTOPPED 4 /* & ** idtype_t and id_t for waitid() */  typedef enum {! P_ALL, P_PID, P_PGID } idtype_t;# ifndef __ID_T# define __ID_T typedef __id_t id_t; # endif#endif/* ** DEC C extensions**'** union wait is for BSD compatibility.*/ #if !defined _POSIX_C_SOURCE# define _WSTOPPED 0x7f union wait { int w_status; /* # ** For processes that have exited */  struct {> unsigned _w_termsig:7;  /* termination signal */? unsigned _w_coredump:1; /* core dump indicator */E unsigned _w_retcode:8; /* exit code if w_termsig==0 */ unsigned short _w_PAD16; } _w_t; /* A ** For processed that have stopped. Not currently implemented. */ struct {C unsigned _w_stopval:8; /* == _WSTOPPED if stopped */B unsigned _w_stopsig:8; /* signal that stopped us */ unsigned short _w_PAD16; } _w_s; };*# define w_termsig _w_t._w_termsig+# define w_coredump _w_t._w_coredump*# define w_retcode _w_t._w_retcode*# define w_stopval _w_s._w_stopval*# define w_stopsig _w_s._w_stopsig#endif /*H** We are done defining things which must always be short pointers. IfH** the user has used /pointer_size=short or /pointer_size=long, we will5** allow long pointers to be used in function calls.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*** Function prototypes*/#if defined _POSIX_EXIT# if __CAN_USE_EXTERN_PREFIX# pragma __extern_prefix __save## pragma __extern_prefix "__posix_"# else&# define wait(__p1) __posix_wait(__p1) # endif#endif__pid_t wait(int *__stat_loc);#if defined _POSIX_EXIT# if __CAN_USE_EXTERN_PREFIX"# pragma __extern_prefix __restore # endif#endif/*F** Beginning in OpenVMS Version 7.2 waitpid, wait3 and wait4 have twoG** implementations. One implementation r eturns UNIX-style exit statusI** which can be analyzed using the macros for analysis of process statusK** values from this header. The other __vms_* returns VMS completion code.*/2#if (__CRTL_VER >= 70100322) && defined(_VMS_WAIT)$# ifdef __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __save*# pragma __extern_prefix "__vms_" # elseJ# define waitpid(__p1,__p2,__p3) __vms_waitpid(__p1,__p2,__p3)H# define wait3(__p1,__p2,__p3) __vms_wait3(__p1,__p2,__p3)M# define wait4(__p1,__p2,__p3,__p4) __vms_wait4(__p1,__p2,__p3,__p4) # endif#endifA__pid_t waitpid( __pid_t __pid, int *__stat_loc, int __options );/* 2** X/Open extended (XPG4 V2) Function prototypes */ >#if defined _XOPEN_SOURCE_EXTENDED || !defined _POSIX_C_SOURCE#if 0$ /* waitid not yet implemented */P int waitid(idtype_t __idtype, id_t __id, siginfo_t *__infop, int __options);#endifQ __pid_t wait3(int *__stat_loc, int options, struct rusage *__resource_usage);#endif/* ** DEC C extensions*/ #if !defined _POSIX_C_SOURCEK __pid_t wait4(__pid_t __pid, union wait *__exit_status, int __options, 1 struct rusage *__resource_usage);#endif2#if (__CRTL_VER >= 70100322) && defined(_VMS_WAIT)# if __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __restore # endif#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif$#pragma __member_alignment __restore#else/*L** The functions declared in this header except for the wait() are new inL** OpenVMS V7.0. The wait() function was introduced in OpenVMS V6.1 and itsL** prototype is included here without any prefixing for the users compilingL** with DEC C V5.2 or higher on OpenVMS V6.1 or V6.2. The pid_t data type7** was defined above in the common part of the header.*/__pid_t wait(int *__stat_loc);'#endif /* #if __CRTL_VER >= 70000000 */#ifdef __cplusplus }#endif'#endif /* #if __CRTL_VER >= 60100000 */#pragma __standard#endif /* __WAIT_LOADED */wwDԗ#ifndef __WCHAR_LOADED#define __WCHAR_LOADED 1#ifndef __WCHAR_PROCESSED#define __WCHAR_PROCESSED#pragma __nostandard#include >#if __CRTL_VER >= 60200000 /* Only OpenVMS V6.2 or later */M/******************************************************************************** - Wide Character**M*****************************************************************************:** Header introduced by Amendment 1 of the ISO C StandardM*****************************************************************************I** I** Copyright 2004 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I**  I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#ifdef __cplusplus extern "C" {#endif8#if !(defined(__NAMESPACE_STD) && defined(__PURE_CNAME))#include #endif#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 32#endif/*:**  Declarations required both by XPG4 and ISO C Amendment*/#ifdef __NAMESPACE_STDnamespace std {#endif#ifndef __SIZE_T# define __SIZE_T 1 typedef __size_t size_t;#endif#ifndef __WINT_T# define __WINT_T typedef __wint_t wint_t;#endif#ifdef __NAMESPACE_STD} /* namespace std */#endif#ifndef __WCHAR_T# define __WCHAR_T typedef __wchar_t wchar_t;#endif #ifndef WEOF# define WEOF ((__wint_t) -1)#endif#ifdef __NAMESPACE_STDnamespace std {#endif struct tm;#ifdef __NAMESPACE_STD} /* namespace std */#endif/*F** Declarations required only by ISO C Amendment. Conflicts arising F** by compiling for both X/OPEN and the ISO C Amendment 1 resolve in 3** favor of ISO C Amendment 1. */##if __STDC_VERSION__ == 199409 || \Q (__CRTL_VER >= 70000000 && !defined _XOPEN_SOURCE && !defined _DECC_V4_SOURCE)# ifndef WCHAR_MAX'# define WCHAR_MAX ((__wchar_t)~0) # endif# ifndef WCHAR_MIN# define WCHAR_MIN 0 # endif#ifdef __NAMESPACE_STDnamespace std {#endif# ifndef __MBSTATE_T# define __MBSTATE_T typedef struct { unsigned __f0 : 32; unsigned __f1 : 32; unsigned __f2 : 32; unsigned __f3 : 32; unsigned __f4 : 32; unsigned __f5 : 32; } mbstate_t; # endif#ifdef __NAMESPACE_STD} /* namespace std */#endif#endif/*J** Create typedefs which are guaranteed to be short pointers. These sameE** declarations may appear in other headers files and are protected.*/ #ifndef NULL# define NULL __NULL#endif /*F** When compiling with /POINTER_SIZE, change to long pointers so that?** prototypes reflect the implementation for widened pointers.*/#if __INITIAL_POINTER_SIZE# pragma __pointer_size 64#endif/*M** Create 'private' typedefs that are sensitive to pointer size and must use** long pointers.*/##if __STDC_VERSION__ == 199409 || \Q (__CRTL_VER >= 70000000 && !defined _XOPEN_SOURCE && !defined _DECC_V4_SOURCE)# ifndef __MBSTATE_PTR64 # define __MBSTATE_PTR64 1# ifdef __NAMESPACE_STD5 typedef std::mbstate_t * __mbstate_ptr64; # else0 typedef mbstate_t * __mbstate_ptr64; # endif # endif#endif8#if !(defined(__NAMESPACE_STD) && defined(__PURE_CNAME))/*G** According to the ISO C Amendment, the wide character classificationI** functions and wide character mapping functions are defined in the newF** header, so the prototypes below are under "strict XPG4"E** condition. Prevent macro expansion of isw* prototypes in cases 5** where both and are included.*/9#if __CRTL_VER < 70000000 || defined _DECC_V4_SOURCE || \7 defined _XOPEN_SOURCE || __STDC_VERSION__ != 199409# ifndef __WCTYPE_T# define __WCTYPE_T#ifdef __NAMESPACE_STDnamespace std {#endif# typedef __wctype_t wctype_t;#ifdef __NAMESPACE_STD} /* namespace std */#ifndef __NAMESPACE_STD_ONLY using std::wctype_t;#endif#endif # endif( int (iswalnum)(__wint_t __wc);( int (iswalpha)(__wint_t __wc);( int (iswcntrl)(__wint_t __wc);( int (iswdigit)(__wint_t __wc);( int (iswgraph)(__wint_t __wc);( int (iswlower)(__wint_t __wc);( int (iswprint)(__wint_t __wc);( int (iswpunct)(__wint_t __wc);( int (iswspace)(__wint_t __wc);( int (iswupper)(__wint_t __wc);) int (iswxdigit)(__wint_t __wc);/ __wctype_t wctype(const char *__property);9 int iswctype(__wint_t __wc, __wctype_t __prop);( __wint_t towlower(__wint_t __wc);( __wint_t towupper(__wint_t __wc);$# define __ISWALPHABET (iswalpha)$# define __ISWCNTRL (iswcntrl)$# define __ISWUPPER (iswupper)$# define __ISWLOWER (iswlower)$# define __ISWDIGIT (iswdigit)$# define __ISWSPACE (iswspace)$# define __ISWPUNCT (iswpunct)%# define __ISWXDIGIT (iswxdigit)$# define __ISWPRINT (iswprint)$# define __ISWGRAPH (iswgraph)$# define __ISWALNUM (iswalnum)R# define __ISWFUNCTION(c,p) (__ctypea?__ctypet[(__wint_t)(c)]&__##p:__ISW##p(c))/# define iswcntrl(c) __ISWFUNCTION(c, CNTRL)/# define iswalnum(c) __ISWFUNCTION(c, ALNUM)2# define iswalpha(c) __ISWFUNCTION(c, ALPHABET)/# define isw digit(c) __ISWFUNCTION(c, DIGIT)/# define iswgraph(c) __ISWFUNCTION(c, GRAPH)/# define iswlower(c) __ISWFUNCTION(c, LOWER)/# define iswprint(c) __ISWFUNCTION(c, PRINT)/# define iswpunct(c) __ISWFUNCTION(c, PUNCT)/# define iswspace(c) __ISWFUNCTION(c, SPACE)0# define iswxdigit(c) __ISWFUNCTION(c, XDIGIT)/# define iswupper(c) __ISWFUNCTION(c, UPPER)A#endif /* __CRTL_VER < 70000000 || defined _DECC_V4_SOURCE ... */A#endif /* !(defined(__NAMESPACE_STD) && defined(__PURE_CNAME)) */#ifdef __NAMESPACE_STDnamespace std {#endif/*;** Functions which support both 32 bit and 64 bit pointers*/&__wint_t fgetwc (__FILE * __stream);5__wint_t fputwc (__wchar_t __c, __FILE * __stream);:int fputws (const __wchar_t *__s, __FILE * __stream);#ifdef __NAMESPACE_STD # pragma __extern_prefix __save!# pragma __extern_prefix "CXXL$"#endif'__wint_t getwc (__FILE * __stream); #ifdef stdin__wint_t getwchar (void);#endif6__wint_t putwc (__wchar_t __c, __FILE * __stream); #ifdef stdout"__wint_t putwchar (__wchar_t __c);#endif#ifdef __NAMESPACE_STD## pragma __extern_prefix __restore#endif5__wint_t ungetwc (__wint_t __c, __FILE * __stream); Bint wcscmp (const __wchar_t *__ws1, const __wchar_t *__ws2); Aint wcscoll (const __wchar_t *__ws1, const __wchar_t *__ws2);D__size_t wcscspn (const __wchar_t *__ws1, const __wchar_t *__ws2); +__size_t wcslen (const __wchar_t *__ws); Pint wcsncmp (const __wchar_t *__ws1, const __wchar_t *__ws2, __size_t __n); E__size_t wcsspn (const __wchar_t *__ws1, const __wchar_t *__ws2); I__size_t wcsxfrm (__wchar_t *__ws1, const __wchar_t *__ws2, __size_t n);% #ifdef __NAMESPACE_STD} /* namespace std */#endif8#if !(defined(__NAMESPACE_STD) && defined(__PURE_CNAME))/*;** These two functions are defined by X/OPEN and not by theA** ISO C Amendment 1. Compiling for X/OPEN or on pre-OpenVMS 7.0<** systems or for compatibility with pre-DEC C V5.2 provides** these definitions. */ 9#if __CRTL_VER < 70000000 || defined _DECC_V4_SOURCE || \: defined _XOPEN_SOURCE || __STDC_VERSION__ != 199409 8int wcswidth (const __wchar_t *__pwcs, __size_t __n);!int wcwidth (__wchar_t __wc);#endifA#endif /* !(defined(__NAMESPACE_STD) && defined(__PURE_CNAME)) *//*O** The following functions have interfaces of XXX, _XXX32, and _XXX64 due onlyM** to the fact that the return argument is a pointer that is relative to one** of the arguments.*/ #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 32#endif#ifdef __NAMESPACE_STDnamespace std {#endif@__wchar_t *fgetws (__wchar_t *__s, int __n, __FILE * __stream);A__wchar_t *wcscat (__wchar_t *__ws1, __const_wchar_ptr64 __ws2);<__wchar_t *wcschr (const __wchar_t *__ws, __wchar_t __wc); B__wchar_t *wcscpy (__wchar_t *__ws1, __const_wchar_ptr64 __ws2); P__wchar_t *wcsncat (__wchar_t *__ws1, __const_wchar_ptr64 __ws2, __size_t __n); P__wchar_t *wcsncpy (__wchar_t *__ws1, __const_wchar_ptr64 __ws2, __size_t __n); H__wchar_t *wcspbrk (const __wchar_t *__ws1, __const_wchar_ptr64 __ws2); <__wchar_t *wcsrchr (const __wchar_t *__ws, __wchar_t __wc); H__wchar_t *wcswcs (const __wchar_t *__ws1, __const_wchar_ptr64 __ws2); Adouble wcstod (const __wchar_t *__nptr, __wchar_t **__endptr);Mlong int wcstol (const __wchar_t *__nptr, __wchar_t **__endptr, int __base);Qunsigned long wcstoul(const __wchar_t *__nptr, __wchar_t **__endptr, int __base);#ifdef __NAMESPACE_STD} /* namespace std */#endif #if __INITIAL_POINTER_SIZE == 32#pragma __pointer_size 64#endif5#if __INITIAL_POINTER_SIZE && !defined _ANSI_C_SOURCE# pragma __pointer_size 327 __wchar_t *_fgetws32 (__wchar_t *, int, __FILE *);= __wchar_t *_wcscat32 (__wchar_t *, __const_wchar_ptr64);: __wchar_t *_wcschr32 (const __wchar_t *, __wchar_t); > __wchar_t *_wcscpy32 (__wchar_t *, __const_wchar_ptr64); H __wchar_t *_wcsncat32 (__wchar_t *, __const_wchar_ptr64, __size_t); H __wchar_t *_wcsncpy32 (__wchar_t *, __const_wchar_ptr64, __size_t); D __wchar_t *_wcspbrk32 (const __wchar_t *, __const_wchar_ptr64); : __wchar_t *_wcsrchr32 (const __wchar_t *, __wchar_t); D __wchar_t *_wcswcs32 (const __wchar_t *, __const_wchar_ptr64); : double _wcstod32 (const __wchar_t *, __wchar_t **);? long int _wcstol32 (const __wchar_t *, __wchar_t **, int); D unsigned long _wcstoul32 (const __wchar_t *, __wchar_t **, int);# pragma __pointer_size 647 __wchar_t *_fgetws64 (__wchar_t *, int, __FILE *);; __wchar_t *_wcscat64 (__wchar_t *, const __wchar_t *);: __wchar_t *_wcschr64 (const __wchar_t *, __wchar_t); < __wchar_t *_wcscpy64 (__wchar_t *, const __wchar_t *); F __wchar_t *_wcsncat64 (__wchar_t *, const __wchar_t *, __size_t); F __wchar_t *_wcsncpy64 (__wchar_t *, const __wchar_t *, __size_t); B __wchar_t *_ wcspbrk64 (const __wchar_t *, const __wchar_t *); : __wchar_t *_wcsrchr64 (const __wchar_t *, __wchar_t); B __wchar_t *_wcswcs64 (const __wchar_t *, const __wchar_t *); : double _wcstod64 (const __wchar_t *, __wchar_t **);? long int _wcstol64 (const __wchar_t *, __wchar_t **, int);D unsigned long _wcstoul64 (const __wchar_t *, __wchar_t **, int);#endif/*G** The ISO C Amendment 1 and XPG4 specification define wcsftime() and E** wcstok() slightly differently. The default or compiling for the L** ISO C Amendment 1 provide the ISO C Amendment 1 definitions. Compiling G** for X/OPEN or on pre-OpenVMS 7.0 systems or for compatibility with L** pre-DEC C Version 5.2 provides the XPG4 definitions. Conflicts arising L** by compiling for both X/OPEN and the ISO C Amendment 1 resolve in favor ** of ISO C Amendment 1.*/?#if (__CRTL_VER >= 70000000 && __STDC_VERSION__ == 199409) || \R (__CRTL_VER >= 70000000 && !defined _XOPEN_SOURCE && !defined _DECC_V4_SOURCE) /* # ** ISO C Amendment definitions */!# ifdef __CAN_USE_EXTERN_PREFIX$# pragma __extern_prefix __save'# pragma __extern_prefix "__pdam_"# else&# define wcstok __pdam_wcstok # endif## if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32 # endif#ifdef __NAMESPACE_STDnamespace std {#endifX __wchar_t * wcstok (__wchar_t *__ws1, __const_wchar_ptr64 __ws2, __wchar_t **__ws3);#ifdef __NAMESPACE_STD} /* namespace std */#endif## if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 64 # endif!# ifdef __CAN_USE_EXTERN_PREFIX'# pragma __extern_prefix __restore # endif8# if __INITIAL_POINTER_SIZE && !defined _ANSI_C_SOURCE# pragma __pointer_size 32c __wchar_t *___pdam_wcstok32(__wchar_t *__ws1, __const_wchar_ptr64 __ws2, __wchar_t **__ws3);# pragma __pointer_size 64c __wchar_t *___pdam_wcstok64(__wchar_t *__ws1, __const_wchar_ptr64 __ws2, __wchar_t **__ws3); # endif#else  /*  ** XPG4 definitions */## if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 32 # endif#ifdef __NAMESPACE_STDnamespace std {#endifE __wchar_t * wcstok (__wchar_t *__ws1, __const_wchar_ptr64 __ws2);#ifdef __NAMESPACE_STD} /* namespace std */#endif## if __INITIAL_POINTER_SIZE == 32# pragma __pointer_size 64 # endif8# if __INITIAL_POINTER_SIZE && !defined _ANSI_C_SOURCE# pragma __pointer_size 32N __wchar_t *_wcstok32(__wchar_t *__ws1, __const_wchar_ptr64 __ws2); # pragma __pointer_size 64N __wchar_t *_wcstok64(__wchar_t *__ws1, __const_wchar_ptr64 __ws2); # endif*#endif /* wcstok() ISO/XPG4 definitions */?#if (__CRTL_VER >= 70000000 && __STDC_VERSION__ == 199409) || \R (__CRTL_VER >= 70000000 && !defined _XOPEN_SOURCE && !defined _DECC_V4_SOURCE) /* # ** ISO C Amendment definitions */# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __save/# pragma __extern_prefix "__utc_pdam_" # elseY# define wcsftime(__p1,__p2,__p3,__p4) __utc_pdam_wcsftime(__p1,__p2,__p3,__p4) # endif# else$# ifdef __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __save+# pragma __extern_prefix "__pdam_" # elseU# define wcsftime(__p1,__p2,__p3,__p4) __pdam_wcsftime(__p1,__p2,__p3,__p4) # endif # endif#ifdef __NAMESPACE_STDnamespace std {#endifq __size_t wcsftime (__wchar_t *__wcs, __size_t __maxsize, const __wchar_t *__fmt, const struct tm *__timptr);#ifdef __NAMESPACE_STD} /* namespace std */#endif!# ifdef __CAN_USE_EXTERN_PREFIX'# pragma __extern_prefix __restore # endif#else  /*  ** XPG4 definitions */#if __CRTL_VER >= 70000000# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX(# pragma __extern_prefix __save*# pragma __extern_prefix "__utc_" # elseT# define wcsftime(__p1,__p2,__p3,__p4) __utc_wcsftime(__p1,__p2,__p3,__p4) # endif # endif##endif /* __CRTL_VER >= 70000000 */#ifdef __NAMESPACE_STDnamespace std {#endifl __size_t wcsftime (__wchar_t *__wcs, __size_t __maxsize, const char *__fmt, const struct tm *__timptr);#ifdef __NAMESPACE_STD} /* namespace std */#endif#if __CRTL_VER >= 70000000# if !defined _VMS_V6_SOURCE$# ifdef __CAN_USE_EXTERN_PREFIX+# pragma __extern_prefix __restore # endif # endif#endif,#endif /* wcsftime() ISO/XPG4 definitions *//*J** Throughout this header file, for a C++ compilation with __NAMESPACE_STDM** enabled, functions from ANSI C standard that are defined as macros in thisB** header file, are defined as inline functions instead of macros.**J** This is to comply with clause 17.4.1.2 Headers [lib.headers] of the C++&** standard which says, in particular:J-6- Names that are defined as functions in C shall be defined as functions" in the C++ Standard Library.*)L*) This disallows the practice, allowed in C, of providing a "masking macro"L in addition to the function prototype. The only way to achieve equivalentJ "inline" behavior in C++ is to provide a definition as an extern inline function.*/#ifndef __NAMESPACE_STD/*** Macro definitions*/#define getwc(fp) fgetwc(fp)"#define getwchar() fgetwc(stdin)!#define putwc(c,fp) fputwc(c,fp)%#define putwchar(c) fputwc(c,stdout)#else/*** Inline functions*/namespace std {#if __INITIAL_POINTER_SIZE# pragma __pointer_size save# pragma __pointer_size 64#endif!inline wint_t getwc(__FILE* fp) { return fgetwc(fp);} #ifdef stdininline wint_t getwchar() { return fgetwc(stdin);}#else__wint_t getwchar (void);#endif,inline wint_t putwc(wchar_t c, __FILE* fp) { return fputwc(c,fp);} #ifdef stdout#inline wint_t putwchar(wchar_t c) { return fputwc(c,stdout);}#else"__wint_t putwchar (__wchar_t __c);#endif#if __INITIAL_POINTER_SIZE!# pragma __pointer_size restore#endif} /* namespace std */#endif /* __NAMESPACE_STD *//*G** The following function prototypes are new with the ISO C Amendment.M** Conflicts arising by compiling for both X/OPEN and the ISO C Amendment 1 >** resolve in favor of ISO C Amendment 1.  */#if __CRTL_VER >= 70000000&# if __STDC_VERSION__ == 199409 || \; (!defined _XOPEN_SOURCE && !defined _DECC_V4_SOURCE)#ifdef __NAMESPACE_STDnamespace std {#endif4 int fwide (__FILE * __stream, int mode);J int fwprintf (__FILE * __stream, const __wchar_t *__format, ...);J int fwscanf (__FILE * __stream, const __wchar_t *__format, ...);Q int swprintf (__wchar_t *s, __size_t n, const __wchar_t *__format, ...);M int swscanf (const __wchar_t *__s, const __wchar_t *__format, ...);V int vfwprintf (__FILE * __stream, const __wchar_t *__format, __va_list __arg);C int vwprintf (const __wchar_t *__format, __va_list __arg);] int vswprintf (__wchar_t *s, __size_t n, const __wchar_t *__format, __va_list __arg);7 int wprintf (const __wchar_t *__format, ...);7 int wscanf (const __wchar_t *__format, ...);# if __CRTL_VER >= 70301000Y int vfwscanf (__FILE  * __stream, const __wchar_t *__format, __va_list __arg);\ int vswscanf (const __wchar_t *__s, const __wchar_t *__format, __va_list __arg);F int vwscanf (const __wchar_t *__format, __va_list __arg);# endif# __wint_t btowc (int __c);& int wctob (__wint_t __c);/ int mbsinit (const mbstate_t *__ps);J __size_t mbrlen (const char *__s, __size_t __n, mbstate_t *__ps);\ __size_t mbrtowc (__wchar_t *__pwc, const char *__s, __s ize_t __n, mbstate_t *__ps);F __size_t wcrtomb (char *__s, __wchar_t __wc, mbstate_t *__ps);T int wmemcmp (const __wchar_t *__s1, const __wchar_t *__s2, __size_t __n); /*R ** The following functions have interfaces of XXX, _XXX32, and _XXX64 dueS ** only to the fact that the return argument is a pointer that is relative$ ** to one of the arguments. */'# if __INITIAL_POINTER_SIZE == 32 # pragma __pointer_size 32 # endifQ __wchar_t *wcsstr (const __wchar_t *__ws1, __const_wchar_ptr64 __ws2);Q __wchar_t *wmemchr (const __wchar_t *__s, __wchar_t __c, __size_t __n);W __wchar_t *wmemcpy (__wchar_t *__s1, __const_wchar_ptr64 __s2, __size_t __n);W __wchar_t *wmemmove (__wchar_t *__s1, __const_wchar_ptr64 __s2, __size_t __n);L __wchar_t *wmemset (__wchar_t *__s1, __wchar_t __c, __size_t __n);p __size_t mbsrtowcs (__wchar_ptr64 __dst, const char **__src, __size_t __len, __mbstate_ptr64 __ps);r __size_t wcsrtombs ( __char_ptr64 __dst, const __wchar_t **__src, __size_t __len, __mbstate_ptr64 __ps);#ifdef __NAMESPACE_STD} /* namespace std */#endif'# if __INITIAL_POINTER_SIZE == 32 # pragma __pointer_size 64 # endif<# if __INITIAL_POINTER_SIZE && !defined _ANSI_C_SOURCE # pragma __pointer_size 32I __wchar_t *_wcsstr32 (const __wchar_t *, __const_wchar_ptr64);I __wchar_t *_wmemchr32 (const __wchar_t *, __wchar_t, __size_t);M __wchar_t *_wmemcpy32 (__wchar_t *, __const_wchar_ptr64, __size_t);M __wchar_t *_wmemmove32 (__wchar_t *, __const_wchar_ptr64, __size_t);C __wchar_t *_wmemset32 (__wchar_t *, __wchar_t, __size_t);Z __size_t _mbsrtowcs32 (__wchar_ptr64, const char **, __size_t, __mbstate_ptr64);^ __size_t _wcsrtombs32 (__char_ptr64, const __wchar_t **, __size_t, __mbstate_ptr64); # pragma __pointer_size 64G __wchar_t *_wcsstr64 (const __wchar_t *, const __wchar_t *);I __wchar_t *_wmemchr64 (const __wchar_t *, __wchar_t, __size_t);K __wchar_t *_wmemcpy64 (__wchar_t *, const __wchar_t *, __size_t);K __wchar_t *_wmemmove64 (__wchar_t *, const __wchar_t *, __size_t);C __wchar_t *_wmemset64 (__wchar_t *, __wchar_t, __size_t);X __size_t _mbsrtowcs64 (__wchar_t *, const char **, __size_t, __mbstate_ptr64);Q __size_t _wcsrtombs64 (char *, const __wchar_t **, __size_t, __mbstate_ptr64); # endif # endif#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif"#endif /* OpenVMS V6.2 or later */#pragma __standard#endif /* __WCHAR_PROCESSED */>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_WCHAR_NAMES# define __USING_WCHAR_NAMES using std::fgetwc; using std::fgetws; using std::fputwc; using std::fputws; using std::getwc; using std::getwchar; using std::putwc; using std::putwchar; using std::size_t; using std::ungetwc; using std::wcscat; using std::wcschr; using std::wcscmp; using std::wcscoll; using std::wcscpy; using std::wcscspn; using std::wcsftime; using std::wcslen; using std::wcsncat; using std::wcsncmp; using std::wcsncpy; using std::wcspbrk; using std::wcsrchr; using std::wcsspn; using std::wcstod; using std::wcstok; using std::wcstol; using std::wcstoul; using std::wcsxfrm; using std::wint_t;#pragma __message __save&#pragma __message __disable __undpreid#if __CRTL_VER >= 70000000##if __STDC_VERSION__ == 199409 || \8 (!defined _XOPEN_SOURCE && !defined _DECC_V4_SOURCE) using std::btowc; using std::fwide; using std::fwprintf; using std::fwscanf; using std::mbrlen; using std::mbrtowc; using std::mbsinit; using std::mbsrtowcs; using std::mbstate_t; using std::swprintf; using std::swscanf; using std::vfwprintf; using std::vswprintf; using std::vwprintf; using std::wcrtomb; using std::wcsrtombs; using std::wcsstr; using std::wctob; using std::wmemchr; using std::wmemcmp; using std::wmemcpy; using std::wmemmove; using std::wmemset; using std::wprintf; using std::wscanf;*#endif /* if __STDC_VERSION__ == 199409 */'#endif /* #if __CRTL_VER >= 70000000 */#pragma __message __restore #endif /* __USING_WCHAR_NAMES */K#endif /* #if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY) */#endif /* __WCHAR_LOADED */ww - Wide Character classification and mapping utilities**M*******************************************************************************:** Header introduced by Amendment 1 of the ISO C Standard**K** Definitions in this header file may not be available on all versions ofK** OpenVMS. See the DEC C Runtime Library reference manual for specifics.**M*****************************************************************************I** I** Copyright 2005 Hewlett-Packard Development Company, L.P. I** I** Confidential computer software. Valid license from HP and/or I** its subsidiaries required for possession, use, or copying. I** I** Consistent with FAR 12.211 and 12.212, Commercial Computer Software, I** Computer Software Documentation, and Technical Data for Commercial I** Items are licensed to the U.S. Government under vendor's standard I** commercial license. I** I** Neither HP nor any of its subsidiaries shall be liable for technical I** or editorial errors or omissions contained herein. The information I** in this document is provided "as is" without warranty of any kind and I** is subject to change without notice. The warranties for HP products I** are set forth in the express limited warranty statements accompanying I** such products. Nothing herein should be construed as constituting an I** additional warranty. I** M******************************************************************************/#pragma __nostandard#include #ifdef __cplusplus extern "C" {#endif/*H** For inline isw*() functions, this header is using some macros definedK** in header. For C++ compilation, instead of inclusion $** header, provide definitions here.*/#ifndef __NAMESPACE_STD/*I** All includes of other header files must be done prior to altering the** pointer size mode.*/#include #elif !defined(__ctypet)*# define __ctypet (decc$$ga___ctypet) # pragma __extern_model __save)# pragma __extern_model __strict_refdef+ extern const unsigned int * __ctypet ;## pragma __extern_model __restore# define __UPPER 0x1# define __LOWER 0x2# define __DIGIT 0x4# define __SPACE 0x8# define __PUNCT 0x10# define __CNTRL 0x20# define __XDIGIT 0x40# define __PRINT 0x80# define __ALPHABET 0x100# define __ALNUM 0x104# define __GRAPH 0x200# define __BLANK 0X400#endif /* __NAMESPACE_STD *//*K** If the user has used /pointer_size=short or /pointer_size=long, we will+** begin in a 32-bit pointer size context.*/#if __INITIAL_POINTER_SIZE # pragma __pointer_size __save# pragma __pointer_size 64#endif#ifdef __NAMESPACE_STDnamespace std {#endif/*-** Define typedefs only once per compilation*/#ifndef __WINT_T# define __WINT_T typedef __wint_t wint_t;#endif#ifndef __WCTRANS_T# define __WCTRANS_T" typedef __wctrans_t wctrans_t;#endif#ifndef __WCTYPE_T# define __WCTYPE_T typedef __wctype_t wctype_t;#endif#ifdef __NAMESPACE_STD} /* namespace std */#endif #ifndef WEOF# define WEOF ((__wint_t) -1)#endif/*K** According to XPG4, the following functions are defined in the N** header. Although the header doesn't exist in XPG4, we put theseM** prototypes under "No strict XPG4" condition for the sake of a user, whichE** includes both and (in header theseN** declarations are placed under "strict XPG4 mode" condition). Also preventH** macro expansion of isw* prototypes in cases where both and** are included.*/>#if (!defined _XOPEN_SOURCE || defined __HIDE_FORBIDDEN_NAMES)#ifdef __NAMESPACE_STDnamespace std {#endif#ifdef __NAMESPACE_STD # pragma __extern_prefix __save!# pragma __extern_prefix "CXXL$"#endif$ int (iswalnum) (__wint_t __wc);$ int (iswalpha) (__wint_t __wc);$ int (iswcntrl) (__wint_t __wc);$ int (iswdigit) (__wint_t __wc);$ int (iswgraph) (__wint_t __wc);$ int (iswlower) (__wint_t __wc);$ int (iswprint) (__wint_t __wc);$ int (iswpunct) (__wint_t __wc);$ int (iswspace) (__wint_t __wc);$ int (iswupper) (__wint_t __wc);$ int (iswxdigit) (__wint_t __wc);#ifdef __NAMESPACE_STD## pragma __extern_prefix __restore#endif/ __wctype_t wctype (const char *__property);7 int iswctype (__wint_t __wc, __wctype_t __desc);& __wint_t towlower (__wint_t __wc);& __wint_t towupper (__wint_t __wc);#ifdef __NAMESPACE_STD} /* namespace std */#endifG#endif /* (!defined _XOPEN_SOURCE || defined __HIDE_FORBIDDEN_NAMES) *//*J** Throughout this header file, for a C++ compilation with __NAMESPACE_STDM** enabled, functions from ANSI C standard that are defined as macros in thisB** header fi le, are defined as inline functions instead of macros.**J** This is to comply with clause 17.4.1.2 Headers [lib.headers] of the C++&** standard which says, in particular:J-6- Names that are defined as functions in C shall be defined as functions" in the C++ Standard Library.*)L*) This disallows the practice, allowed in C, of providing a "masking macro"L in addition to the function prototype. The only way to achieve equivalentJ "inline" behavior in C++ is to provide a definition as an extern inline function.*/$# define __ISWALPHABET (iswalpha)$# define __ISWCNTRL (iswcntrl)$# define __ISWUPPER (iswupper)$# define __ISWLOWER (iswlower)$# define __ISWDIGIT (iswdigit)$# define __ISWSPACE (iswspace)$# define __ISWPUNCT (iswpunct)%# define __ISWXDIGIT (iswxdigit)$# define __ISWPRINT (iswprint)$# define __ISWGRAPH (iswgraph)$# define __ISWALNUM (iswalnum)#ifndef __NAMESPACE_STD/*** Macro definitions*/R# define __ISWFUNCTION(c,p) (__ctypea?__ctypet[(__wint_t)(c)]&__##p:__ISW##p(c))/# define iswcntrl(c) __ISWFUNCTION(c, CNTRL)/# define iswalnum(c) __ISWFUNCTION(c, ALNUM)2# define iswalpha(c) __ISWFUNCTION(c, ALPHABET)/# define iswdigit(c) __ISWFUNCTION(c, DIGIT)/# define iswgraph(c) __ISWFUNCTION(c, GRAPH)/# define iswlower(c) __ISWFUNCTION(c, LOWER)/# define iswprint(c) __ISWFUNCTION(c, PRINT)/# define iswpunct(c) __ISWFUNCTION(c, PUNCT)/#  define iswspace(c) __ISWFUNCTION(c, SPACE)0# define iswxdigit(c) __ISWFUNCTION(c, XDIGIT)/# define iswupper(c) __ISWFUNCTION(c, UPPER)#else/*** Inline functions*//*>** isw*() functions are defined as macros in header.** Undefine them, just in case.*/#undef iswalnum#undef iswalpha#undef iswcntrl#undef iswdigit#undef iswgraph#undef iswlower#undef iswprint#undef iswpunct#undef iswspace#undef iswupper#undef iswxdigitnamespace std {%#define __INLINE_ISWFUNCTION(c,p) { \9 /* no need to check __ctypea on VMS V6.2 and above */ \A return (c == WEOF ? 0 : __ctypet[(unsigned int)(c)] & __##p); \}=inline int iswcntrl(wint_t c) __INLINE_ISWFUNCTION(c, CNTRL)=inline int iswalnum(wint_t c) __INLINE_ISWFUNCTION(c, ALNUM)@inline int iswalpha(wint_t c) __INLINE_ISWFUNCTION(c, ALPHABET)=inline int iswdigit(wint_t c) __INLINE_ISWFUNCTION(c, DIGIT)=inline int iswgraph(wint_t c) __INLINE_ISWFUNCTION(c, GRAPH)=inline int iswlower(wint_t c) __INLINE_ISWFUNCTION(c, LOWER)=inline int iswprint(wint_t c) __INLINE_ISWFUNCTION(c, PRINT)=inline int iswpunct(wint_t c) __INLINE_ISWFUNCTION(c, PUNCT)=inline int iswspace(wint_t c) __INLINE_ISWFUNCTION(c, SPACE)>inline int iswxdigit(wint_t c) __INLINE_ISWFUNCTION(c, XDIGIT)=inline int iswupper(wint_t c) __INLINE_ISWFUNCTION(c, UPPER)} /* namespace std */#endif /* __NAMESPACE_STD */#ifdef __NAMESPACE_STDnamespace std {#endif/__wctrans_t wctrans (const char *__property);:__wint_t towctrans (__wint_t __wc, __wctrans_t __desc);#ifdef __NAMESPACE_STD} /* namespace std */#endif/*%** Restore the users pointer context*/#if __INITIAL_POINTER_SIZE## pragma __pointer_size __restore#endif#ifdef __cplusplus }#endif#pragma __standard#endif /* __WCTYPE_PROCESSED */>#if defined(__NAMESPACE_STD) && !defined(__NAMESPACE_STD_ONLY)# ifndef __USING_WCTYPE_NAMES #  define __USING_WCTYPE_NAMES>#if (!defined _XOPEN_SOURCE || defined __HIDE_FORBIDDEN_NAMES) using std::iswctype; using std::towlower; using std::towupper; using std::wctype;#endif using std::iswalnum; using std::iswalpha; using std::iswcntrl; using std::iswdigit; using std::iswgraph; using std::iswlower; using std::iswprint; using std::iswpunct; using std::iswspace; using std::iswupper; using std ::iswxdigit; using std::towctrans; using std::wctrans; using std::wctrans_t; using std::wctype_t; using std::wint_t;# endif#endif#endif /* __WCTYPE_LOADED */wwEԗ^ CRTL CRTL_CLASSASSERTBITYPESBUILTINSCOMPLEXCTYPECURSESC_ASM DECC$TYPESDESCRIPDIRENTDLFCNERRNOERRNODEFFCNTLFILEFLOATFPFP_CLASSFTWGLOBGRPICONVIFIF_ARP IF_TRNSTATIF_TYPESININ6 IN6_MACHTYPESINETINTSINTTYPESIOCTLIPCISO646LANGINFOLIBGENLIMITSLOCALEMATHMEMORYMMANMONETARYNAMESERNAMESER_COMPATNETDBNL_TYPESPCAP-BPFPCAPPERRORPOLL PROCESSESPWD REENTRANCYRESOLVRESOURCESCTPSCTP_UIOSEM SEMAPHORESETJMPSIGINFOSIGNALSOCKETSTATSTATVFSSTDARGSTDBOOLSTDDEFSTDIOSTDLIBSTRINGSTRINGSSTROPTSTCPTGMATHTIMETIMEBTIMERSTIMESTYPESTZFILEUIOUNISTDUNIXIOUNIXLIBUTIMEUTSNAMEVARARGSVMSWAITWCHARWCTYPE