diff options
author | Wayne Davison <wayned@samba.org> | 2009-09-02 09:06:29 -0700 |
---|---|---|
committer | Wayne Davison <wayned@samba.org> | 2009-09-02 09:06:29 -0700 |
commit | 6e310d38fcdeacb8055bb7e83d4e64c37fd54a38 (patch) | |
tree | 4a6676f79d57605fd67701953950c059c3af985e /generator.c | |
parent | 3b83a22057b71e7df2b960d3997fb4474910f30e (diff) | |
download | android_external_rsync-6e310d38fcdeacb8055bb7e83d4e64c37fd54a38.tar.gz android_external_rsync-6e310d38fcdeacb8055bb7e83d4e64c37fd54a38.tar.bz2 android_external_rsync-6e310d38fcdeacb8055bb7e83d4e64c37fd54a38.zip |
Have --fake-super turn a symlink into a file when
NO_SYMLINK_XATTRS is defined.
Diffstat (limited to 'generator.c')
-rw-r--r-- | generator.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/generator.c b/generator.c index 2aa07cd0..5f6afd6f 100644 --- a/generator.c +++ b/generator.c @@ -946,7 +946,7 @@ static int try_dests_non(struct file_struct *file, char *fname, int ndx, break; case TYPE_SYMLINK: #ifdef SUPPORT_LINKS - if ((len = readlink(cmpbuf, lnk, MAXPATHLEN-1)) <= 0) + if ((len = do_readlink(cmpbuf, lnk, MAXPATHLEN-1)) <= 0) continue; lnk[len] = '\0'; if (strcmp(lnk, F_SYMLINK(file)) != 0) @@ -1369,7 +1369,7 @@ static void recv_generator(char *fname, struct file_struct *file, int ndx, int len; if (S_ISLNK(sx.st.st_mode) - && (len = readlink(fname, lnk, MAXPATHLEN-1)) > 0 + && (len = do_readlink(fname, lnk, MAXPATHLEN-1)) > 0 && strncmp(lnk, sl, len) == 0 && sl[len] == '\0') { /* The link is pointing to the right place. */ set_file_attrs(fname, file, &sx, NULL, maybe_ATTRS_REPORT); |