* src/copy.c (copy_internal): * src/cp.c (do_copy): * src/ln.c (do_link): Adjust to Gnulib API change. --- gnulib | 2 +- src/copy.c | 3 ++- src/cp.c | 2 +- src/ln.c | 3 ++- 4 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/gnulib b/gnulib index 1ff0e9684..ceeae5b03 160000 --- a/gnulib +++ b/gnulib @@ -1 +1 @@ -Subproject commit 1ff0e9684bb83a8277ffe22ac125ce7e90f6702b +Subproject commit ceeae5b03847392c7295e95637bacc60a6a905ee diff --git a/src/copy.c b/src/copy.c index 1f4d47737..3221b9997 100644 --- a/src/copy.c +++ b/src/copy.c @@ -2151,7 +2151,8 @@ copy_internal (char const *src_name, char const *dst_name, return false; } - char *tmp_backup = backup_file_rename (dst_name, x->backup_type); + char *tmp_backup = backup_file_rename (AT_FDCWD, dst_name, + x->backup_type); /* FIXME: use fts: Using alloca for a file name that may be arbitrarily diff --git a/src/cp.c b/src/cp.c index 21dd4441b..31726a836 100644 --- a/src/cp.c +++ b/src/cp.c @@ -759,7 +759,7 @@ do_copy (int n_files, char **file, const char *target_directory, { static struct cp_options x_tmp; - new_dest = find_backup_file_name (dest, x->backup_type); + new_dest = find_backup_file_name (AT_FDCWD, dest, x->backup_type); /* Set x->backup_type to 'no_backups' so that the normal backup mechanism is not used when performing the actual copy. backup_type must be set to 'no_backups' only *after* the above diff --git a/src/ln.c b/src/ln.c index 9f197a4b7..83fad5367 100644 --- a/src/ln.c +++ b/src/ln.c @@ -311,7 +311,8 @@ do_link (const char *source, const char *dest, int link_errno) if (backup_type != no_backups) { - dest_backup = find_backup_file_name (dest, backup_type); + dest_backup = find_backup_file_name (AT_FDCWD, dest, + backup_type); if (rename (dest, dest_backup) != 0) { int rename_errno = errno; -- 2.17.2