mirror of
https://git.savannah.gnu.org/git/coreutils.git
synced 2026-11-17 18:02:09 +03:00
mv: fix issues with previous prompt adjustments
* src/copy.c (overwrite_ok): Fix the gettext calls so that the second string is tagged for translation. Display the correct "replace ..." prompt when in move_mode. * tests/mv/i-3.sh: Display the output on failure to ease debugging.
This commit is contained in:
1 parent
5de5d8a5c0
commit
2d8ae88a22
2 files changed
+5
-5
No files matched your search
+4
-4
@@ -1575,10 +1575,10 @@ overwrite_ok (struct cp_options const *x, char const *dst_name,
|
||||
strmode (dst_sb->st_mode, perms);
|
||||
perms[10] = '\0';
|
||||
fprintf (stderr,
|
||||
_((x->unlink_dest_before_opening
|
||||
|| x->unlink_dest_after_failed_open)
|
||||
? "%s: replace %s, overriding mode %04lo (%s)? "
|
||||
: "%s: unwritable %s (mode %04lo, %s); try anyway? "),
|
||||
(x->move_mode || x->unlink_dest_before_opening
|
||||
|| x->unlink_dest_after_failed_open)
|
||||
? _("%s: replace %s, overriding mode %04lo (%s)? ")
|
||||
: _("%s: unwritable %s (mode %04lo, %s); try anyway? "),
|
||||
program_name, quote (dst_name),
|
||||
(unsigned long int) (dst_sb->st_mode & CHMOD_MODE_BITS),
|
||||
&perms[1]);
|
||||
|
||||
+1
-1
@@ -52,7 +52,7 @@ check_overwrite_prompt()
|
||||
}
|
||||
|
||||
# Wait for up to 12.7 seconds for the expected prompt.
|
||||
retry_delay_ check_overwrite_prompt .1 7 || fail=1
|
||||
retry_delay_ check_overwrite_prompt .1 7 || { fail=1; cat out; }
|
||||
|
||||
kill $pid
|
||||
|
||||
|
||||
Reference in new issue
Block a user