If target file exists, MC overwrites that file without confirmation.
The bug has not been fixed comletely in
7d73ce1cbe.
Yet another test case:
1. Create files:
mkdir -p test1/1 test2/1
echo "1" > test1/1/file
echo "2" > test2/1/file
2. Run `mc test1 test2`.
3. Select directory "1" and press F6.
Result: "file" file is overwritten w/o confirmation.
Expected result: since the "file" file exists the confirmation dialog
must be shown.
The problem is: confirmation dialog requires context UI which was not
created in case of single directory move/rename operation.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Don't show error message for each not-installed program when view
documents in MS Word and Excel formats.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
* 3923_escape_fileop_filename:
(operate_one_file): remove unescape of source and destination filenames.
Ticket #3923: fix of file name escaping in file operations.
Revert "(operate_single_file): make src and dest file name unescaping"
This reverts commit ef5d346dd9.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
mplayer is not currently actively developed and some people have long
switched to MPV - use it as a fallback for "mplayer -identify" command.
Also, give the user a hint about mplayer/mpv in case none of them is
installed.
Signed-off-by: Yury V. Zaytsev <yury.zaytsev@moneymeets.com>
ClosesMidnightCommander/mc#134:
* `file -b` prints class file version, which `javap` doesn't by default
* `javap`'s stderr should be suppressed as it may print `_JAVA_OPTIONS`
if this variable is set
Signed-off-by: Yury V. Zaytsev <yury@shurup.com>
* Asterisk and underscore contexts don't play well with lists or
words containing underscores. And given that markdown files
could contain not only ASCII text, it is better to be conservative
in detecting contexts.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
If target file exists, MC overwrites that file without confirmation.
The bug was introduced in #3149.
How to reproduce:
1. Create two files: `touch a aa`.
2. Stay on "aa".
3. Make sure that Options/Confirmation.../Overwrite option is checked on.
4. Press Shift-F6
5. Edit the "to:" value to "a" ("a" file exists) and press Enter.
Actual result:
The "a" file is overwritten w/o confirmation.
Expected result:
Since the "a" file exists the confirmation dialog must be shown.
The problem is: confirmation dialog requires context UI which was not
created in case of single file rename operation.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
(edit_quit): do not call widget_select() while direct iterating editor
windows because it changes the window position in Z order. Collect
modified files in separate list.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
* 3876_cleanup: (47 commits)
(mc_deserialize_str): trivial optimization.
(edit_do_search): use gboolean. Remove unused computations.
(str_8bit_encodings[], str_utf8_encodings[]): make const.
(etags_set_definition_hash): make buf stack variable.
(convert_from_8bit_to_utf_c2): use convert_from_8bit_to_utf_c().
str_convert_to_input() never returns NULL.
(edit_collect_completions): str_convert_to_display() never returns NULL.
lib/charsets.c: fix coding style, trivial optimizations.
(mc_search__recode_str): minor optimization.
(mc_search__get_one_symbol): cosmetics.
strutil: character test functions return gboolean instead of int.
Use str_move() where possible.
Use gboolean instead of int in file/dir sort related functions.
(get_codepage_index): minor optimizations.
(ftpfs_command): minor optimization.
FTP: fix some calls of ftpfs_command().
FISH: optimize creation of FISH commands.
src/vfs/fish/fish.c: allocate buffer for command dynamically.
(vfs_url_split): Fix 2 memory leaks found by valgrind.
smbfs: code cleanup
...