summaryrefslogtreecommitdiff
path: root/lib/fts_.h
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2005-05-09 18:53:11 +0000
committerPaul Eggert <eggert@cs.ucla.edu>2005-05-09 18:53:11 +0000
commit3ed3fb2d8194a82500df48d1e5a1152c390984f0 (patch)
treef879cced153c7e9b0e2b7e9e2622247b8c8301a9 /lib/fts_.h
parentea345c5774683ffb31ab49e5ba32536f28ae287d (diff)
downloadcoreutils-3ed3fb2d8194a82500df48d1e5a1152c390984f0.tar.xz
(FTS): Use correct type for fts_compar member.
(FTSENT): New member fts_fts. Remove members fts_ino, fts_dev, fts_nlink; no longer needed now that fts_statp is always there. All uses changed to use fts_statp instead.
Diffstat (limited to 'lib/fts_.h')
-rw-r--r--lib/fts_.h11
1 files changed, 5 insertions, 6 deletions
diff --git a/lib/fts_.h b/lib/fts_.h
index 43f68522a..f95d9fc40 100644
--- a/lib/fts_.h
+++ b/lib/fts_.h
@@ -1,6 +1,6 @@
/* Traverse a file hierarchy.
- Copyright (C) 2004 Free Software Foundation, Inc.
+ Copyright (C) 2004, 2005 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -75,7 +75,8 @@ typedef struct {
int fts_rfd; /* fd for root */
size_t fts_pathlen; /* sizeof(path) */
size_t fts_nitems; /* elements in the sort array */
- int (*fts_compar) (const void *, const void *); /* compare fn */
+ int (*fts_compar) (struct _ftsent const **, struct _ftsent const **);
+ /* compare fn */
# define FTS_COMFOLLOW 0x0001 /* follow command line symlinks */
# define FTS_LOGICAL 0x0002 /* logical walk */
@@ -126,14 +127,12 @@ typedef struct _ftsent {
long fts_number; /* local numeric value */
void *fts_pointer; /* local address value */
char *fts_accpath; /* access path */
- char *fts_path; /* root path */
+ char *fts_path; /* root path; == fts_fts->fts_path */
int fts_errno; /* errno for this node */
int fts_symfd; /* fd for symlink */
size_t fts_pathlen; /* strlen(fts_path) */
- ino_t fts_ino; /* inode */
- dev_t fts_dev; /* device */
- nlink_t fts_nlink; /* link count */
+ FTS *fts_fts; /* the file hierarchy itself */
# define FTS_ROOTPARENTLEVEL (-1)
# define FTS_ROOTLEVEL 0