Edit File by line
/home/barbar84/public_h.../wp-conte.../plugins/sujqvwi/ExeBy/smexe_ro.../usr/include
File: glob.h
/* Copyright (C) 1991-2018 Free Software Foundation, Inc.
[0] Fix | Delete
This file is part of the GNU C Library.
[1] Fix | Delete
[2] Fix | Delete
The GNU C Library is free software; you can redistribute it and/or
[3] Fix | Delete
modify it under the terms of the GNU Lesser General Public
[4] Fix | Delete
License as published by the Free Software Foundation; either
[5] Fix | Delete
version 2.1 of the License, or (at your option) any later version.
[6] Fix | Delete
[7] Fix | Delete
The GNU C Library is distributed in the hope that it will be useful,
[8] Fix | Delete
but WITHOUT ANY WARRANTY; without even the implied warranty of
[9] Fix | Delete
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
[10] Fix | Delete
Lesser General Public License for more details.
[11] Fix | Delete
[12] Fix | Delete
You should have received a copy of the GNU Lesser General Public
[13] Fix | Delete
License along with the GNU C Library; if not, see
[14] Fix | Delete
<http://www.gnu.org/licenses/>. */
[15] Fix | Delete
[16] Fix | Delete
#ifndef _GLOB_H
[17] Fix | Delete
#define _GLOB_H 1
[18] Fix | Delete
[19] Fix | Delete
#include <sys/cdefs.h>
[20] Fix | Delete
[21] Fix | Delete
__BEGIN_DECLS
[22] Fix | Delete
[23] Fix | Delete
/* We need `size_t' for the following definitions. */
[24] Fix | Delete
#ifndef __size_t
[25] Fix | Delete
typedef __SIZE_TYPE__ __size_t;
[26] Fix | Delete
# if defined __USE_XOPEN || defined __USE_XOPEN2K8
[27] Fix | Delete
typedef __SIZE_TYPE__ size_t;
[28] Fix | Delete
# endif
[29] Fix | Delete
#else
[30] Fix | Delete
/* The GNU CC stddef.h version defines __size_t as empty. We need a real
[31] Fix | Delete
definition. */
[32] Fix | Delete
# undef __size_t
[33] Fix | Delete
# define __size_t size_t
[34] Fix | Delete
#endif
[35] Fix | Delete
[36] Fix | Delete
/* Bits set in the FLAGS argument to `glob'. */
[37] Fix | Delete
#define GLOB_ERR (1 << 0)/* Return on read errors. */
[38] Fix | Delete
#define GLOB_MARK (1 << 1)/* Append a slash to each name. */
[39] Fix | Delete
#define GLOB_NOSORT (1 << 2)/* Don't sort the names. */
[40] Fix | Delete
#define GLOB_DOOFFS (1 << 3)/* Insert PGLOB->gl_offs NULLs. */
[41] Fix | Delete
#define GLOB_NOCHECK (1 << 4)/* If nothing matches, return the pattern. */
[42] Fix | Delete
#define GLOB_APPEND (1 << 5)/* Append to results of a previous call. */
[43] Fix | Delete
#define GLOB_NOESCAPE (1 << 6)/* Backslashes don't quote metacharacters. */
[44] Fix | Delete
#define GLOB_PERIOD (1 << 7)/* Leading `.' can be matched by metachars. */
[45] Fix | Delete
[46] Fix | Delete
#if !defined __USE_POSIX2 || defined __USE_MISC
[47] Fix | Delete
# define GLOB_MAGCHAR (1 << 8)/* Set in gl_flags if any metachars seen. */
[48] Fix | Delete
# define GLOB_ALTDIRFUNC (1 << 9)/* Use gl_opendir et al functions. */
[49] Fix | Delete
# define GLOB_BRACE (1 << 10)/* Expand "{a,b}" to "a" "b". */
[50] Fix | Delete
# define GLOB_NOMAGIC (1 << 11)/* If no magic chars, return the pattern. */
[51] Fix | Delete
# define GLOB_TILDE (1 << 12)/* Expand ~user and ~ to home directories. */
[52] Fix | Delete
# define GLOB_ONLYDIR (1 << 13)/* Match only directories. */
[53] Fix | Delete
# define GLOB_TILDE_CHECK (1 << 14)/* Like GLOB_TILDE but return an error
[54] Fix | Delete
if the user name is not available. */
[55] Fix | Delete
# define __GLOB_FLAGS (GLOB_ERR|GLOB_MARK|GLOB_NOSORT|GLOB_DOOFFS| \
[56] Fix | Delete
GLOB_NOESCAPE|GLOB_NOCHECK|GLOB_APPEND| \
[57] Fix | Delete
GLOB_PERIOD|GLOB_ALTDIRFUNC|GLOB_BRACE| \
[58] Fix | Delete
GLOB_NOMAGIC|GLOB_TILDE|GLOB_ONLYDIR|GLOB_TILDE_CHECK)
[59] Fix | Delete
#else
[60] Fix | Delete
# define __GLOB_FLAGS (GLOB_ERR|GLOB_MARK|GLOB_NOSORT|GLOB_DOOFFS| \
[61] Fix | Delete
GLOB_NOESCAPE|GLOB_NOCHECK|GLOB_APPEND| \
[62] Fix | Delete
GLOB_PERIOD)
[63] Fix | Delete
#endif
[64] Fix | Delete
[65] Fix | Delete
/* Error returns from `glob'. */
[66] Fix | Delete
#define GLOB_NOSPACE 1 /* Ran out of memory. */
[67] Fix | Delete
#define GLOB_ABORTED 2 /* Read error. */
[68] Fix | Delete
#define GLOB_NOMATCH 3 /* No matches found. */
[69] Fix | Delete
#define GLOB_NOSYS 4 /* Not implemented. */
[70] Fix | Delete
#ifdef __USE_GNU
[71] Fix | Delete
/* Previous versions of this file defined GLOB_ABEND instead of
[72] Fix | Delete
GLOB_ABORTED. Provide a compatibility definition here. */
[73] Fix | Delete
# define GLOB_ABEND GLOB_ABORTED
[74] Fix | Delete
#endif
[75] Fix | Delete
[76] Fix | Delete
/* Structure describing a globbing run. */
[77] Fix | Delete
#ifdef __USE_GNU
[78] Fix | Delete
struct stat;
[79] Fix | Delete
#endif
[80] Fix | Delete
typedef struct
[81] Fix | Delete
{
[82] Fix | Delete
__size_t gl_pathc; /* Count of paths matched by the pattern. */
[83] Fix | Delete
char **gl_pathv; /* List of matched pathnames. */
[84] Fix | Delete
__size_t gl_offs; /* Slots to reserve in `gl_pathv'. */
[85] Fix | Delete
int gl_flags; /* Set to FLAGS, maybe | GLOB_MAGCHAR. */
[86] Fix | Delete
[87] Fix | Delete
/* If the GLOB_ALTDIRFUNC flag is set, the following functions
[88] Fix | Delete
are used instead of the normal file access functions. */
[89] Fix | Delete
void (*gl_closedir) (void *);
[90] Fix | Delete
#ifdef __USE_GNU
[91] Fix | Delete
struct dirent *(*gl_readdir) (void *);
[92] Fix | Delete
#else
[93] Fix | Delete
void *(*gl_readdir) (void *);
[94] Fix | Delete
#endif
[95] Fix | Delete
void *(*gl_opendir) (const char *);
[96] Fix | Delete
#ifdef __USE_GNU
[97] Fix | Delete
int (*gl_lstat) (const char *__restrict, struct stat *__restrict);
[98] Fix | Delete
int (*gl_stat) (const char *__restrict, struct stat *__restrict);
[99] Fix | Delete
#else
[100] Fix | Delete
int (*gl_lstat) (const char *__restrict, void *__restrict);
[101] Fix | Delete
int (*gl_stat) (const char *__restrict, void *__restrict);
[102] Fix | Delete
#endif
[103] Fix | Delete
} glob_t;
[104] Fix | Delete
[105] Fix | Delete
#ifdef __USE_LARGEFILE64
[106] Fix | Delete
# ifdef __USE_GNU
[107] Fix | Delete
struct stat64;
[108] Fix | Delete
# endif
[109] Fix | Delete
typedef struct
[110] Fix | Delete
{
[111] Fix | Delete
__size_t gl_pathc;
[112] Fix | Delete
char **gl_pathv;
[113] Fix | Delete
__size_t gl_offs;
[114] Fix | Delete
int gl_flags;
[115] Fix | Delete
[116] Fix | Delete
/* If the GLOB_ALTDIRFUNC flag is set, the following functions
[117] Fix | Delete
are used instead of the normal file access functions. */
[118] Fix | Delete
void (*gl_closedir) (void *);
[119] Fix | Delete
# ifdef __USE_GNU
[120] Fix | Delete
struct dirent64 *(*gl_readdir) (void *);
[121] Fix | Delete
# else
[122] Fix | Delete
void *(*gl_readdir) (void *);
[123] Fix | Delete
# endif
[124] Fix | Delete
void *(*gl_opendir) (const char *);
[125] Fix | Delete
# ifdef __USE_GNU
[126] Fix | Delete
int (*gl_lstat) (const char *__restrict, struct stat64 *__restrict);
[127] Fix | Delete
int (*gl_stat) (const char *__restrict, struct stat64 *__restrict);
[128] Fix | Delete
# else
[129] Fix | Delete
int (*gl_lstat) (const char *__restrict, void *__restrict);
[130] Fix | Delete
int (*gl_stat) (const char *__restrict, void *__restrict);
[131] Fix | Delete
# endif
[132] Fix | Delete
} glob64_t;
[133] Fix | Delete
#endif
[134] Fix | Delete
[135] Fix | Delete
/* Do glob searching for PATTERN, placing results in PGLOB.
[136] Fix | Delete
The bits defined above may be set in FLAGS.
[137] Fix | Delete
If a directory cannot be opened or read and ERRFUNC is not nil,
[138] Fix | Delete
it is called with the pathname that caused the error, and the
[139] Fix | Delete
`errno' value from the failing call; if it returns non-zero
[140] Fix | Delete
`glob' returns GLOB_ABEND; if it returns zero, the error is ignored.
[141] Fix | Delete
If memory cannot be allocated for PGLOB, GLOB_NOSPACE is returned.
[142] Fix | Delete
Otherwise, `glob' returns zero. */
[143] Fix | Delete
#if !defined __USE_FILE_OFFSET64
[144] Fix | Delete
extern int glob (const char *__restrict __pattern, int __flags,
[145] Fix | Delete
int (*__errfunc) (const char *, int),
[146] Fix | Delete
glob_t *__restrict __pglob) __THROW;
[147] Fix | Delete
[148] Fix | Delete
/* Free storage allocated in PGLOB by a previous `glob' call. */
[149] Fix | Delete
extern void globfree (glob_t *__pglob) __THROW;
[150] Fix | Delete
#else
[151] Fix | Delete
extern int __REDIRECT_NTH (glob, (const char *__restrict __pattern,
[152] Fix | Delete
int __flags,
[153] Fix | Delete
int (*__errfunc) (const char *, int),
[154] Fix | Delete
glob_t *__restrict __pglob), glob64);
[155] Fix | Delete
[156] Fix | Delete
extern void __REDIRECT_NTH (globfree, (glob_t *__pglob), globfree64);
[157] Fix | Delete
#endif
[158] Fix | Delete
[159] Fix | Delete
#ifdef __USE_LARGEFILE64
[160] Fix | Delete
extern int glob64 (const char *__restrict __pattern, int __flags,
[161] Fix | Delete
int (*__errfunc) (const char *, int),
[162] Fix | Delete
glob64_t *__restrict __pglob) __THROW;
[163] Fix | Delete
[164] Fix | Delete
extern void globfree64 (glob64_t *__pglob) __THROW;
[165] Fix | Delete
#endif
[166] Fix | Delete
[167] Fix | Delete
[168] Fix | Delete
#ifdef __USE_GNU
[169] Fix | Delete
/* Return nonzero if PATTERN contains any metacharacters.
[170] Fix | Delete
Metacharacters can be quoted with backslashes if QUOTE is nonzero.
[171] Fix | Delete
[172] Fix | Delete
This function is not part of the interface specified by POSIX.2
[173] Fix | Delete
but several programs want to use it. */
[174] Fix | Delete
extern int glob_pattern_p (const char *__pattern, int __quote) __THROW;
[175] Fix | Delete
#endif
[176] Fix | Delete
[177] Fix | Delete
__END_DECLS
[178] Fix | Delete
[179] Fix | Delete
#endif /* glob.h */
[180] Fix | Delete
[181] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function