Commit Graph

12269 Commits

Author SHA1 Message Date
Andrew Borodin
eba12456eb Sync with gnulib 613bcb6205cf2b64d835c19074c5a7e7c6cb99eb
...and ab7a2b67b48deb4c253b3b6bd983690d71515265.

* src/filemanager/mountlist: do not classify a bind-mounted dir entry
as "dummy".

(ME_DUMMY_0): Rename from ME_DUMMY, but omit the "none"-testing clause.
(ME_DUMMY) [MOUNTED_GETMNTENT1]: New macro to encapsulate the exception
for bind-mounted directories.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:35:35 +04:00
Andrew Borodin
9903480096 FileOpContext::preserve: make gboolean.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:35:35 +04:00
Andrew Borodin
a5efdb67ce FileOpContext::dive_into_subdirs: make gboolean.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:35:34 +04:00
Andrew Borodin
3762269434 Don't create copy/move progress dialog for background operations.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:35:34 +04:00
Pavel Vasilyev
d4f50f0be5 src/vfs/tar/tar.c: types accuracy.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:35:18 +04:00
Pavel Vasilyev
03fd500c2e src/vfs/cpio/cpio.c: types accuracy.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:35:18 +04:00
Pavel Vasilyev
f84bbd8583 vfs_s_subclass::linear_read: return ssize_t instead of int.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:35:18 +04:00
Pavel Vasilyev
fafd75c807 lib/vfs/direntry.c: types accuracy.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:35:18 +04:00
Andrew Borodin
848318f95f lib/vfs/vfs.h: indentation.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:35:18 +04:00
Pavel Vasilyev
8d71220350 (mcview_search_update_cmd_callback): add type cast for correct condition check.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:35:18 +04:00
Andrew Borodin
06e1d21322 (mcview_find): type accuracy.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:35:13 +04:00
Andrew Borodin
1f1be9ac93 lib/tty/color.c: use unsigned type for conversion between integer and pointer.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:18:06 +04:00
Andrew Borodin
04942e5f2b (str_iscombiningmark): return gboolean instead of int
...and related changes.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:18:06 +04:00
Andrew Borodin
25689a32bb (edit_find_word_start): type accuracy for word start.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:18:06 +04:00
Andrew Borodin
b10fc3ce59 Ticket #2888: code cleanup before 4.8.7 release.
(editcmd_find): remove incorrect type cast.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-20 15:18:06 +04:00
Slava Zanko
448475d102 Merge branch '319_edit_flow_column_insertion'
* 319_edit_flow_column_insertion:
  place cursor after inserted chars by 'block move' command
  place cursor after inserted chars by 'block copy' command
  added option "Cursor after inserted block" in the options dialog of editor
  Ticket #319: place cursor after inserted chars
2012-12-20 14:11:49 +03:00
Ilia Maslakov
77c599be70 place cursor after inserted chars by 'block move' command
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2012-12-20 14:08:55 +03:00
Ilia Maslakov
7a5458fd9b place cursor after inserted chars by 'block copy' command
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2012-12-20 14:08:55 +03:00
Ilia Maslakov
d6a1de5898 added option "Cursor after inserted block" in the options dialog of editor
Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2012-12-20 14:08:55 +03:00
Ilia Maslakov
027cc24f28 Ticket #319: place cursor after inserted chars
* Added 'editor_cursor_after_inserted_block' config option (default value is: FALSE)
* Cursor placed at end of inserted chars when extern file is inserted under cursor

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2012-12-20 14:08:36 +03:00
Slava Zanko
a1dd199723 Fixes in exec_get_export_variables_ext test
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2012-12-20 13:48:26 +03:00
Slava Zanko
5624861a9d Merge branch '2883_portable_tests'
* 2883_portable_tests:
  Increase version of Check utility to 0.9.8
  Fixed exec_get_export_variables_ext test
  Ticket #2883: non-portable test
2012-12-20 13:16:13 +03:00
Slava Zanko
bc8658b9de Increase version of Check utility to 0.9.8
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2012-12-20 13:13:40 +03:00
Slava Zanko
076e53550d Fixed exec_get_export_variables_ext test
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2012-12-20 13:13:40 +03:00
Slava Zanko
5e633c7ca1 Ticket #2883: non-portable test
Test has been rewritten for support actuality.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2012-12-20 12:48:42 +03:00
Andrew Borodin
177f1dc5ba Merge branch '2926_screen_lib_flags'
* 2926_screen_lib_flags:
  Clarify usage of AM_CPPFLAGS.
  PCRE_CFLAGS are CPPFLAGS, actually.
  m4.include/mc-with-screen-slang.m4: clarify usage of CPPFLAGS, CFLAGS and LDFLAGS
  Ticket #2926: fail to check ncurses library
2012-12-18 16:29:07 +04:00
Andrew Borodin
60727b9b79 Clarify usage of AM_CPPFLAGS.
Use AM_CPPFLAGS not AM_CFLAGS for includes. GLIB_CFLAGS are CPPFLAGS, actually.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-18 16:27:49 +04:00
Andrew Borodin
7b184ddea4 PCRE_CFLAGS are CPPFLAGS, actually.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-18 16:27:49 +04:00
Andrew Borodin
f7bc3e5c21 m4.include/mc-with-screen-slang.m4: clarify usage of CPPFLAGS, CFLAGS and LDFLAGS
...in s-lang library checking.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-18 16:27:49 +04:00
Andrew Borodin
49a0b83adf Ticket #2926: fail to check ncurses library
...if --with-ncurses-inc and --with-ncurses-libs options are used.

m4.include/mc-with-screen-ncurses.m4: clarify usage of LDFLAGS in
ncurses library checking: add $ac_curses_lib_path.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-12-18 16:27:49 +04:00
Andrew Borodin
f0d1d91864 Merge branch '2924_preserve_dir_attributes'
* 2924_preserve_dir_attributes:
  (copy_dir_dir): get rid of extra string duplication.
  (copy_dir_dir): refactoring: get rid of goto dont_mkdir.
  Ticket #2924: attributes of existing directories are never preserved.
2012-11-29 14:45:50 +04:00
Andrew Borodin
33dbb1338e (copy_dir_dir): get rid of extra string duplication.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-29 14:45:18 +04:00
Andrew Borodin
ba6b7ce976 (copy_dir_dir): refactoring: get rid of goto dont_mkdir.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-29 14:45:18 +04:00
Slack
82cfece6ae Ticket #2924: attributes of existing directories are never preserved.
If superuser copies a directory tree (e.g. from a safe backup location
(with sane permission, owner, group, timestamp) over an existing tree,
any attributes are not preserved. All destination dirs retain all their
existing attributes instead of change attributes from source.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-29 14:45:18 +04:00
Slava Zanko
4ee4959cea Merge branch '2913_sanitize'
* 2913_sanitize:
  Added parameter quotation
  Added tests for name_quote function.
  exec_get_export_variables(): reproduce bug in test
  Ticket #2913: CVE-2012-4463 mc-4.8.5: Does not sanitize MC_EXT_SELECTED variable properly
2012-11-29 13:22:00 +03:00
Slava Zanko
a51df499cd Added parameter quotation
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2012-11-29 13:21:09 +03:00
Slava Zanko
467677ee6a Added tests for name_quote function.
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2012-11-29 13:20:47 +03:00
Slava Zanko
f115ac627f exec_get_export_variables(): reproduce bug in test
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2012-11-29 13:20:47 +03:00
Slava Zanko
6bdf50c5a5 Ticket #2913: CVE-2012-4463 mc-4.8.5: Does not sanitize MC_EXT_SELECTED variable properly
Paul Hartman reported the following (minor) security flaw into Gentoo's bugzilla:

https://bugs.gentoo.org/show_bug.cgi?id=436518

When multiple files are selected and F3 / Enter key is pressed on some of the files,
MC_EXT_SELECTED variable does not sanitize the whitespace characters properly
(leading into situation when first file is used as the actual value of MC_EXT_SELECTED
variable and the remaining files from the list are used as arguments passed to the
temporary script, created to handle F3 / Enter action on the first file).

A remote attacker could provide a specially-crafted archive and trick the local
Midnight Commander user into expanding and viewing it, which under certain
circumstances could lead to arbitrary code execution with the privileges of
the user running the mc executable.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2012-11-29 13:20:47 +03:00
Andrew Borodin
bf475ce339 Ticket #2934: highlight OGV files as media.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-23 14:20:04 +04:00
Andrew Borodin
7b8e790de0 src/*/*.[ch]: fix indentation.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-20 13:44:14 +04:00
Andrew Borodin
281209c79d lib/widget/*.[ch]: fix indentation.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-20 13:27:10 +04:00
Andrew Borodin
47fc9f669f Merge branch '2919_dlg_as_widget'
* 2919_dlg_as_widget: (57 commits)
  Update po/*.po and po/mc.pot files.
  Internal menu structures are opaque now.
  Add useful macros for widget type cast.
  Unify widget and dialog message handling.
  Remove DLG_WANT_IDLE. Use W_WANT_IDLE instead.
  Rename Dlg_head to WDialog.
  Rename default callbacks of widget and dialog.
  Unify some hotkeys.
  (editcmd_dialog_raw_key_query): adjust sizes and look'n'feel.
  (real_query_recursive): refactoring of dialog.
  "Directory scanning" dialog: adjust look'n'feel.
  Center text in query owerwrite and delete dialogs.
  (query_dialog): center label horizontally.
  Horizontal centering of multi-line label: center each line independently.
  (file_mask_dialog): adjust width calculation.
  (query_dialog): add horizontal line.
  Remove DLG_REVERSE flag.
  Build file operation dialogs in normal order.
  Build find file dialogs in normal order.
  Build "Background jobs" dialog in normal order.
  ...
2012-11-20 13:07:03 +04:00
Andrew Borodin
8c59d2be4b Update po/*.po and po/mc.pot files.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-19 21:49:38 +04:00
Andrew Borodin
4e90c1a229 Internal menu structures are opaque now.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-19 21:44:14 +04:00
Andrew Borodin
2ec122bc05 Add useful macros for widget type cast.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-19 21:44:14 +04:00
Andrew Borodin
665d238ffa Unify widget and dialog message handling.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-19 21:44:14 +04:00
Andrew Borodin
497b69c106 Remove DLG_WANT_IDLE. Use W_WANT_IDLE instead.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-19 21:44:13 +04:00
Andrew Borodin
843dcd104e Rename Dlg_head to WDialog.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-19 21:42:47 +04:00
Andrew Borodin
0078874613 Rename default callbacks of widget and dialog.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2012-11-19 21:42:47 +04:00