diff options
| author | Paul Green <paulg@samba.org> | 2006-05-04 19:00:37 +0000 |
|---|---|---|
| committer | Paul Green <paulg@samba.org> | 2006-05-04 19:00:37 +0000 |
| commit | b59dc8d5ae4cd0170587932550008c60871fafd9 (patch) | |
| tree | c5e5c7dbdcd6bb88fd2e0913d694b2aec6ac85bd /generator.c | |
| parent | 45ba206a947ddd611ad3cdabdbbacc2e32fca913 (diff) | |
| download | android_external_rsync-b59dc8d5ae4cd0170587932550008c60871fafd9.tar.gz android_external_rsync-b59dc8d5ae4cd0170587932550008c60871fafd9.tar.bz2 android_external_rsync-b59dc8d5ae4cd0170587932550008c60871fafd9.zip | |
Fix generator.c to avoid calling do_link() on systems that do not support
the link() function. The changes test OK on SuSE Linux and on my own
Stratus VOS system, but I would be grateful if other folks could
double-check this change. Paul G.
Diffstat (limited to 'generator.c')
| -rw-r--r-- | generator.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/generator.c b/generator.c index 0bb4e9fe..5d1077e2 100644 --- a/generator.c +++ b/generator.c @@ -751,7 +751,10 @@ static int try_dests_non(struct file_struct *file, char *fname, int ndx, && !IS_SPECIAL(file->mode) && !IS_DEVICE(file->mode) #endif ) { - if (do_link(fnamebuf, fname) < 0) { +#ifdef SUPPORT_HARD_LINKS + if (do_link(fnamebuf, fname) < 0) +#endif + { rsyserr(FERROR, errno, "failed to hard-link %s with %s", fnamebuf, fname); |
