2012-01-30 17:41:33 -05:00
|
|
|
/* See LICENSE file for copyright and license details. */
|
2015-03-12 19:25:32 -04:00
|
|
|
#include <sys/types.h>
|
|
|
|
|
|
|
|
struct history {
|
|
|
|
struct history *prev;
|
|
|
|
dev_t dev;
|
|
|
|
ino_t ino;
|
|
|
|
};
|
|
|
|
|
|
|
|
struct recursor {
|
|
|
|
void (*fn)(const char *, void *, struct recursor *);
|
|
|
|
struct history *hist;
|
|
|
|
int depth;
|
|
|
|
int follow;
|
|
|
|
int flags;
|
|
|
|
};
|
|
|
|
|
|
|
|
enum {
|
|
|
|
SAMEDEV = 1 << 0,
|
|
|
|
};
|
|
|
|
|
2014-11-13 15:24:47 -05:00
|
|
|
extern int cp_aflag;
|
|
|
|
extern int cp_fflag;
|
|
|
|
extern int cp_pflag;
|
|
|
|
extern int cp_rflag;
|
|
|
|
extern int cp_vflag;
|
2015-02-16 11:23:12 -05:00
|
|
|
extern int cp_HLPflag;
|
2014-07-21 12:27:20 -04:00
|
|
|
extern int cp_status;
|
2014-07-09 17:28:43 -04:00
|
|
|
|
2014-11-13 15:24:47 -05:00
|
|
|
extern int rm_fflag;
|
|
|
|
extern int rm_rflag;
|
2015-01-30 06:45:54 -05:00
|
|
|
extern int rm_status;
|
2012-01-30 17:41:33 -05:00
|
|
|
|
2015-03-12 19:25:32 -04:00
|
|
|
extern int recurse_status;
|
|
|
|
|
|
|
|
void recurse(const char *, void *, struct recursor *);
|
|
|
|
|
2015-03-02 15:43:56 -05:00
|
|
|
int cp(const char *, const char *, int);
|
2015-03-12 19:25:32 -04:00
|
|
|
void rm(const char *, void *, struct recursor *);
|