glob.h (98937) | glob.h (106121) |
---|---|
1/* $OpenBSD: glob.h,v 1.5 2001/03/18 17:18:58 deraadt Exp $ */ | 1/* $OpenBSD: glob.h,v 1.7 2002/02/17 19:42:21 millert Exp $ */ |
2/* $NetBSD: glob.h,v 1.5 1994/10/26 00:55:56 cgd Exp $ */ 3 4/* 5 * Copyright (c) 1989, 1993 6 * The Regents of the University of California. All rights reserved. 7 * 8 * This code is derived from software contributed to Berkeley by 9 * Guido van Rossum. --- 38 unchanged lines hidden (view full) --- 48struct stat; 49typedef struct { 50 int gl_pathc; /* Count of total paths so far. */ 51 int gl_matchc; /* Count of paths matching pattern. */ 52 int gl_offs; /* Reserved at beginning of gl_pathv. */ 53 int gl_flags; /* Copy of flags parameter to glob. */ 54 char **gl_pathv; /* List of paths matching pattern. */ 55 /* Copy of errfunc parameter to glob. */ | 2/* $NetBSD: glob.h,v 1.5 1994/10/26 00:55:56 cgd Exp $ */ 3 4/* 5 * Copyright (c) 1989, 1993 6 * The Regents of the University of California. All rights reserved. 7 * 8 * This code is derived from software contributed to Berkeley by 9 * Guido van Rossum. --- 38 unchanged lines hidden (view full) --- 48struct stat; 49typedef struct { 50 int gl_pathc; /* Count of total paths so far. */ 51 int gl_matchc; /* Count of paths matching pattern. */ 52 int gl_offs; /* Reserved at beginning of gl_pathv. */ 53 int gl_flags; /* Copy of flags parameter to glob. */ 54 char **gl_pathv; /* List of paths matching pattern. */ 55 /* Copy of errfunc parameter to glob. */ |
56 int (*gl_errfunc) __P((const char *, int)); | 56 int (*gl_errfunc)(const char *, int); |
57 58 /* 59 * Alternate filesystem access methods for glob; replacement 60 * versions of closedir(3), readdir(3), opendir(3), stat(2) 61 * and lstat(2). 62 */ | 57 58 /* 59 * Alternate filesystem access methods for glob; replacement 60 * versions of closedir(3), readdir(3), opendir(3), stat(2) 61 * and lstat(2). 62 */ |
63 void (*gl_closedir) __P((void *)); 64 struct dirent *(*gl_readdir) __P((void *)); 65 void *(*gl_opendir) __P((const char *)); 66 int (*gl_lstat) __P((const char *, struct stat *)); 67 int (*gl_stat) __P((const char *, struct stat *)); | 63 void (*gl_closedir)(void *); 64 struct dirent *(*gl_readdir)(void *); 65 void *(*gl_opendir)(const char *); 66 int (*gl_lstat)(const char *, struct stat *); 67 int (*gl_stat)(const char *, struct stat *); |
68} glob_t; 69 70/* Flags */ 71#define GLOB_APPEND 0x0001 /* Append to output from previous call. */ 72#define GLOB_DOOFFS 0x0002 /* Use gl_offs. */ 73#define GLOB_ERR 0x0004 /* Return on error. */ 74#define GLOB_MARK 0x0008 /* Append / to matching directories. */ 75#define GLOB_NOCHECK 0x0010 /* Return pattern itself if nothing matches. */ --- 10 unchanged lines hidden (view full) --- 86 87/* Error values returned by glob(3) */ 88#define GLOB_NOSPACE (-1) /* Malloc call failed. */ 89#define GLOB_ABORTED (-2) /* Unignored error. */ 90#define GLOB_NOMATCH (-3) /* No match and GLOB_NOCHECK not set. */ 91#define GLOB_NOSYS (-4) /* Function not supported. */ 92#define GLOB_ABEND GLOB_ABORTED 93 | 68} glob_t; 69 70/* Flags */ 71#define GLOB_APPEND 0x0001 /* Append to output from previous call. */ 72#define GLOB_DOOFFS 0x0002 /* Use gl_offs. */ 73#define GLOB_ERR 0x0004 /* Return on error. */ 74#define GLOB_MARK 0x0008 /* Append / to matching directories. */ 75#define GLOB_NOCHECK 0x0010 /* Return pattern itself if nothing matches. */ --- 10 unchanged lines hidden (view full) --- 86 87/* Error values returned by glob(3) */ 88#define GLOB_NOSPACE (-1) /* Malloc call failed. */ 89#define GLOB_ABORTED (-2) /* Unignored error. */ 90#define GLOB_NOMATCH (-3) /* No match and GLOB_NOCHECK not set. */ 91#define GLOB_NOSYS (-4) /* Function not supported. */ 92#define GLOB_ABEND GLOB_ABORTED 93 |
94int glob __P((const char *, int, int (*)(const char *, int), glob_t *)); 95void globfree __P((glob_t *)); | 94int glob(const char *, int, int (*)(const char *, int), glob_t *); 95void globfree(glob_t *); |
96 97#endif /* !_GLOB_H_ */ 98 99#endif /* !defined(HAVE_GLOB_H) || !defined(GLOB_HAS_ALTDIRFUNC) || 100 !defined(GLOB_HAS_GL_MATCHC */ 101 | 96 97#endif /* !_GLOB_H_ */ 98 99#endif /* !defined(HAVE_GLOB_H) || !defined(GLOB_HAS_ALTDIRFUNC) || 100 !defined(GLOB_HAS_GL_MATCHC */ 101 |