extern int always_checksum;
extern char *compare_dest;
extern int link_dest;
-extern struct file_struct **hlink_list;
/* choose whether to skip a particular file */
}
if (link_dest) {
if (preserve_perms
- && (st->st_mode & ~_S_IFMT) != (file->mode & ~_S_IFMT))
+ && (st->st_mode & CHMOD_BITS) != (file->mode & CHMOD_BITS))
return 0;
if (am_root && preserve_uid && st->st_uid != file->uid)
{
static struct sum_struct null_sum;
- if (sum == (struct sum_struct *)NULL)
+ if (sum == NULL)
sum = &null_sum;
write_int(f, sum->count);
/* if the file exists already and we aren't perserving
* permissions then act as though the remote end sent
* us the file permissions we already have */
- file->mode = (file->mode & _S_IFMT) | (st.st_mode & ~_S_IFMT);
+ file->mode = (file->mode & ~CHMOD_BITS)
+ | (st.st_mode & CHMOD_BITS);
}
if (S_ISDIR(file->mode)) {
fnamecmp = fname;
- if ((statret == -1) && (compare_dest != NULL)) {
+ if (statret == -1 && compare_dest != NULL) {
/* try the file at compare_dest instead */
int saveerrno = errno;
pathjoin(fnamecmpbuf, sizeof fnamecmpbuf, compare_dest, fname);
int phase=0;
char fbuf[MAXPATHLEN];
- if (verbose > 2)
- rprintf(FINFO,"generator starting pid=%d count=%d\n",
- (int)getpid(),flist->count);
+ if (verbose > 2) {
+ rprintf(FINFO, "generator starting pid=%ld count=%d\n",
+ (long)getpid(), flist->count);
+ }
if (verbose >= 2) {
rprintf(FINFO,