# build/myftw.h File Reference

Portable ftw(3) using lstat() instead of stat(). More...

`#include <sys/stat.h>`

Go to the source code of this file.

## Defines

#define | MYFTW_F 0 /* Regular file. */
#define | MYFTW_D 1 /* Directory. */
#define | MYFTW_DNR 2 /* Unreadable directory. */
#define | MYFTW_NS 3 /* Unstatable file. */

## Typedefs

typedef int(* | myftwFunc )(void *fl, const char *name, struct stat *statp)

## Functions

int | myftw (const char *dir, int descriptors, myftwFunc func, void *fl)

## Detailed Description

Portable ftw(3) using lstat() instead of stat().

Definition in file myftw.h.

## Define Documentation

#define MYFTW_D 1 /* Directory. */

| Definition at line 14 of file myftw.h. Referenced by myftw(), and myftw_dir().

#define MYFTW_DNR 2 /* Unreadable directory. */

| Definition at line 16 of file myftw.h. Referenced by myftw(), and myftw_dir().

#define MYFTW_F 0 /* Regular file. */

| Definition at line 12 of file myftw.h. Referenced by myftw(), and myftw_dir().

#define MYFTW_NS 3 /* Unstatable file. */

| Definition at line 18 of file myftw.h. Referenced by myftw(), and myftw_dir().

## Typedef Documentation

typedef int(* myftwFunc)(void *fl, const char *name, struct stat *statp)

| Definition at line 25 of file myftw.h. Referenced by addFile(), myftw(), and myftw_dir().

## Function Documentation

int myftw | ( | const char * | dir,
|  | int | descriptors,
|  | myftwFunc | func,
|  | void * | fl
| ) |

| Definition at line 179 of file myftw.c. References alloca(), Closedir(), errno, Lstat(), MYFTW_D, myftw_dir(), MYFTW_DNR, MYFTW_F, MYFTW_NS, myftwFunc, Opendir(), and PATH_MAX. Referenced by addFile().