#ifndef __FTW_LOADED #define __FTW_LOADED /**************************************************************************** ** ** - walk a file tree ** ***************************************************************************** ** ** Header introduced by the X/Open CAE Specification, Issue 4 ** ** Definitions in this header file may not be available on all versions of ** OpenVMS. See the DEC C Runtime Library reference manual for specifics. ** ***************************************************************************** ** ** Copyright 2000 Compaq Computer Corporation ** ** Compaq and the Compaq logo Registered in U.S. Patent and Trademark Office. ** ** Confidential computer software. Valid license from Compaq required for ** possession, use or copying. Consistent with FAR 12.211 and 12.212, ** Commercial Computer Software, Computer Software Documentation, and ** Technical Data for Commercial Items are licensed to the U.S. Government ** under vendor's standard commercial license. ** ****************************************************************************** */ #pragma __nostandard #include #ifdef __cplusplus extern "C" { #endif /* ** 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 /* ** All includes of other header files must be done prior to altering the ** pointer size mode. */ #include /* ** Define FTW constant values */ #define FTW_D 0 /* Directory */ #define FTW_DNR 1 /* Directory without read permission */ #define FTW_F 2 /* File */ #define FTW_NS 3 /* Unknown type, stat() failed */ #if defined _XOPEN_SOURCE_EXTENDED || !defined _XOPEN_SOURCE # define FTW_SL 4 /* symbolic link */ # define FTW_SLN 5 /* symbolic link names non-existant file */ #endif /* ** The callback routine for the ftw function is always passed 32 bit addresses. */ typedef int (* __ftw_callback)(const char *, const struct stat *, int); /* ** We are done defining things which must always be 32 bit pointers. 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 #if __USE_LONG_GID_T # pragma __extern_prefix __save # pragma __extern_prefix "__long_gid_" #endif /* ** Function prototypes */ int ftw (const char * __path, __ftw_callback __action, int __depth); #if __USE_LONG_GID_T # pragma __extern_prefix __restore #endif /* ** Restore the users pointer context */ #if __INITIAL_POINTER_SIZE # pragma __pointer_size __restore #endif #ifdef __cplusplus } #endif #pragma __standard #endif /* __FTW_LOADED */