source and destination are the same directory entry. In that
case, moving the destination file aside (in making the backup)
would also rename the source file and result in an error. */
- if (x->backup_type != none)
+ if (x->backup_type != no_backups)
{
if (!same_link)
{
if (command_line_arg)
{
if ( ! S_ISDIR (src_sb.st_mode)
- && x->backup_type == none
+ && x->backup_type == no_backups
&& seen_file (x->src_info, src_path, &src_sb))
{
error (0, 0, _("warning: source file %s specified more than once"),
a move using cp and rm.
Note that it works fine if you use --backup=numbered. */
if (command_line_arg
- && x->backup_type != numbered
+ && x->backup_type != numbered_backups
&& seen_file (x->dest_info, dst_path, &dst_sb))
{
error (0, 0,
}
}
- if (x->backup_type != none && !S_ISDIR (dst_sb.st_mode))
+ if (x->backup_type != no_backups && !S_ISDIR (dst_sb.st_mode))
{
char *tmp_backup = find_backup_file_name (dst_path,
x->backup_type);
where SUFFIX is determined by any version control options used. */
if (x->unlink_dest_after_failed_open
- && x->backup_type != none
+ && x->backup_type != no_backups
&& STREQ (source, dest)
&& !new_dst && S_ISREG (sb.st_mode))
{
static struct cp_options x_tmp;
new_dest = find_backup_file_name (dest, x->backup_type);
- /* Set x->backup_type to `none' so that the normal backup
+ /* 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 `none' only *after* the above
+ backup_type must be set to `no_backups' only *after* the above
call to find_backup_file_name -- that function uses
backup_type to determine the suffix it applies. */
x_tmp = *x;
- x_tmp.backup_type = none;
+ x_tmp.backup_type = no_backups;
x = &x_tmp;
}
else
x.backup_type = (make_backups
? xget_version (_("backup type"),
version_control_string)
- : none);
+ : no_backups);
if (x.preserve_mode)
x.umask_kill = ~ (mode_t) 0;