From b71b7ea9d3db7062bcb1ef04071210495d62effe Mon Sep 17 00:00:00 2001 From: Andy Alt Date: Sun, 11 Jul 2021 21:58:11 -0500 Subject: [PATCH 01/33] Ticket #4270: code clean up before 4.8.28 release. MidnightCommander/#165: doc/README: grammar. Signed-off-by: Andrew Borodin --- doc/README | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/README b/doc/README index 22923032a..ab41284f4 100644 --- a/doc/README +++ b/doc/README @@ -16,8 +16,8 @@ GNU Midnight Commander (also referred to as MC) is a user shell with text-mode full-screen interface. It can be run on the OS console, in xterm and other terminal emulators. -GNU Midnight Commander allows you to manage files while making most of -you screen and giving you a clear representation of the filesystem, yet +GNU Midnight Commander allows you to manage files while making the most of +your screen and giving you a clear representation of the filesystem, yet it's simple enough to be run over a telnet or ssh session. GNU Midnight Commander is released under the GNU General Public From d19b247c6d0327c18748256878339bda0c1cf380 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 5 Sep 2021 12:25:13 +0300 Subject: [PATCH 02/33] Ticket #4384: fix accelerator conflict in Left/Right menu. Signed-off-by: Andrew Borodin --- src/filemanager/filemanager.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/filemanager/filemanager.c b/src/filemanager/filemanager.c index c6f9869f1..d317eacc5 100644 --- a/src/filemanager/filemanager.c +++ b/src/filemanager/filemanager.c @@ -199,7 +199,7 @@ create_panel_menu (void) entries = g_list_prepend (entries, menu_entry_create (_("&Listing format..."), CK_SetupListingFormat)); - entries = g_list_prepend (entries, menu_entry_create (_("&Sort order..."), CK_Sort)); + entries = g_list_prepend (entries, menu_entry_create (_("S&ort order..."), CK_Sort)); entries = g_list_prepend (entries, menu_entry_create (_("&Filter..."), CK_Filter)); #ifdef HAVE_CHARSET entries = g_list_prepend (entries, menu_entry_create (_("&Encoding..."), CK_SelectCodepage)); @@ -212,7 +212,7 @@ create_panel_menu (void) entries = g_list_prepend (entries, menu_entry_create (_("S&hell link..."), CK_ConnectFish)); #endif #ifdef ENABLE_VFS_SFTP - entries = g_list_prepend (entries, menu_entry_create (_("S&FTP link..."), CK_ConnectSftp)); + entries = g_list_prepend (entries, menu_entry_create (_("&SFTP link..."), CK_ConnectSftp)); #endif entries = g_list_prepend (entries, menu_entry_create (_("Paneli&ze"), CK_Panelize)); entries = g_list_prepend (entries, menu_separator_create ()); From cac689a81af50936d9bd336793aa4b75e00694b2 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 5 Sep 2021 12:28:32 +0300 Subject: [PATCH 03/33] Get rid of extra update of mini info. (stop_search): don't update mini info if quick search is incative. Signed-off-by: Andrew Borodin --- src/filemanager/panel.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/filemanager/panel.c b/src/filemanager/panel.c index 54f85b9d7..9045beaab 100644 --- a/src/filemanager/panel.c +++ b/src/filemanager/panel.c @@ -2771,6 +2771,9 @@ start_search (WPanel * panel) static void stop_search (WPanel * panel) { + if (!panel->quick_search.active) + return; + panel->quick_search.active = FALSE; /* if user overrdied search string, we need to store it From d410af27c0c0cfd521e4f03dd6aa261d9a207db7 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 5 Sep 2021 12:34:37 +0300 Subject: [PATCH 04/33] (start_search): ret rid of extra screen redraw. Signed-off-by: Andrew Borodin --- src/filemanager/panel.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/filemanager/panel.c b/src/filemanager/panel.c index 9045beaab..cae64bfed 100644 --- a/src/filemanager/panel.c +++ b/src/filemanager/panel.c @@ -2762,7 +2762,6 @@ start_search (WPanel * panel) panel->quick_search.ch[0] = '\0'; panel->quick_search.chpoint = 0; display_mini_info (panel); - mc_refresh (); } } From 022c3d2f946785bc766957fdc4969c84708771a3 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 5 Sep 2021 13:04:55 +0300 Subject: [PATCH 05/33] Refactoring of file operations. (copy_cmd, copy_cmd_local, rename_cmd, rename_cmd_local, delete_cmd, delete_cmd_local): move same code to panel_operate(), make inline. Signed-off-by: Andrew Borodin --- src/filemanager/cmd.c | 91 ------------------------------------------ src/filemanager/cmd.h | 77 ++++++++++++++++++++++++++++++++--- src/filemanager/file.c | 5 +++ 3 files changed, 76 insertions(+), 97 deletions(-) diff --git a/src/filemanager/cmd.c b/src/filemanager/cmd.c index 8aa9fc739..c49010c0b 100644 --- a/src/filemanager/cmd.c +++ b/src/filemanager/cmd.c @@ -80,10 +80,8 @@ #endif #include "fileopctx.h" -#include "file.h" /* file operation routines */ #include "filenot.h" #include "hotlist.h" /* hotlist_show() */ -#include "panel.h" /* WPanel */ #include "tree.h" /* tree_chdir() */ #include "filemanager.h" /* change_panel() */ #include "command.h" /* cmdline */ @@ -769,66 +767,6 @@ edit_cmd_new (void) vfs_path_free (fname_vpath, TRUE); } -/* --------------------------------------------------------------------------------------------- */ -/** Invoked by F5. Copy, default to the other panel. */ - -void -copy_cmd (WPanel * panel) -{ - save_cwds_stat (); - - if (panel_operate (panel, OP_COPY, FALSE)) - { - update_panels (UP_OPTIMIZE, UP_KEEPSEL); - repaint_screen (); - } -} - -/* --------------------------------------------------------------------------------------------- */ -/** Invoked by F6. Move/rename, default to the other panel, ignore marks. */ - -void -rename_cmd (WPanel * panel) -{ - save_cwds_stat (); - - if (panel_operate (panel, OP_MOVE, FALSE)) - { - update_panels (UP_OPTIMIZE, UP_KEEPSEL); - repaint_screen (); - } -} - -/* --------------------------------------------------------------------------------------------- */ -/** Invoked by F15. Copy, default to the same panel, ignore marks. */ - -void -copy_cmd_local (WPanel * panel) -{ - save_cwds_stat (); - - if (panel_operate (panel, OP_COPY, TRUE)) - { - update_panels (UP_OPTIMIZE, UP_KEEPSEL); - repaint_screen (); - } -} - -/* --------------------------------------------------------------------------------------------- */ -/** Invoked by F16. Move/rename, default to the same panel. */ - -void -rename_cmd_local (WPanel * panel) -{ - save_cwds_stat (); - - if (panel_operate (panel, OP_MOVE, TRUE)) - { - update_panels (UP_OPTIMIZE, UP_KEEPSEL); - repaint_screen (); - } -} - /* --------------------------------------------------------------------------------------------- */ void @@ -880,35 +818,6 @@ mkdir_cmd (WPanel * panel) g_free (dir); } -/* --------------------------------------------------------------------------------------------- */ - -void -delete_cmd (WPanel * panel) -{ - save_cwds_stat (); - - if (panel_operate (panel, OP_DELETE, FALSE)) - { - update_panels (UP_OPTIMIZE, UP_KEEPSEL); - repaint_screen (); - } -} - -/* --------------------------------------------------------------------------------------------- */ -/** Invoked by F18. Remove selected file, regardless of marked files. */ - -void -delete_cmd_local (WPanel * panel) -{ - save_cwds_stat (); - - if (panel_operate (panel, OP_DELETE, TRUE)) - { - update_panels (UP_OPTIMIZE, UP_KEEPSEL); - repaint_screen (); - } -} - /* --------------------------------------------------------------------------------------------- */ /** Invoked from the left/right menus */ diff --git a/src/filemanager/cmd.h b/src/filemanager/cmd.h index 2ddb32a57..0630fe07a 100644 --- a/src/filemanager/cmd.h +++ b/src/filemanager/cmd.h @@ -9,6 +9,7 @@ #include "lib/global.h" +#include "file.h" /* panel_operate() */ #include "panel.h" /*** typedefs(not structures) and defined constants **********************************************/ @@ -56,13 +57,7 @@ void edit_cmd_new (void); #ifdef USE_INTERNAL_EDIT void edit_cmd_force_internal (const WPanel * panel); #endif -void copy_cmd (WPanel * panel); -void copy_cmd_local (WPanel * panel); -void rename_cmd (WPanel * panel); -void rename_cmd_local (WPanel * panel); void mkdir_cmd (WPanel * panel); -void delete_cmd (WPanel * panel); -void delete_cmd_local (WPanel * panel); void filter_cmd (void); void reread_cmd (void); void vfs_list (WPanel * panel); @@ -104,5 +99,75 @@ const char *chattr_get_as_str (unsigned long attr); /* find.c */ void find_cmd (WPanel * panel); +/* --------------------------------------------------------------------------------------------- */ /*** inline functions ****************************************************************************/ +/* --------------------------------------------------------------------------------------------- */ + +/** + * Copy, default to the other panel. + */ + +static inline void +copy_cmd (WPanel * panel) +{ + panel_operate (panel, OP_COPY, FALSE); +} + +/* --------------------------------------------------------------------------------------------- */ +/** + * Copy, default to the same panel, ignore marks. + */ + +static inline void +copy_cmd_local (WPanel * panel) +{ + panel_operate (panel, OP_COPY, TRUE); +} + +/* --------------------------------------------------------------------------------------------- */ +/** + * Move/rename, default to the other panel. + */ + +static inline void +rename_cmd (WPanel * panel) +{ + panel_operate (panel, OP_MOVE, FALSE); +} + +/* --------------------------------------------------------------------------------------------- */ +/** + * Move/rename, default to the same panel, ignore marks. + */ + +static inline void +rename_cmd_local (WPanel * panel) +{ + panel_operate (panel, OP_MOVE, TRUE); +} + +/* --------------------------------------------------------------------------------------------- */ +/** + * Remove. + */ + +static inline void +delete_cmd (WPanel * panel) +{ + panel_operate (panel, OP_DELETE, FALSE); +} + +/* --------------------------------------------------------------------------------------------- */ +/** + * Remove, ignore marks. + */ + +static inline void +delete_cmd_local (WPanel * panel) +{ + panel_operate (panel, OP_DELETE, TRUE); +} + +/* --------------------------------------------------------------------------------------------- */ + #endif /* MC__CMD_H */ diff --git a/src/filemanager/file.c b/src/filemanager/file.c index 38c26f6ee..3414bac0e 100644 --- a/src/filemanager/file.c +++ b/src/filemanager/file.c @@ -3240,6 +3240,8 @@ panel_operate (void *source_panel, FileOperation operation, gboolean force_singl linklist = free_linklist (linklist); dest_dirs = free_linklist (dest_dirs); + save_cwds_stat (); + if (single_entry) { source = check_single_entry (panel, force_single, &src_stat); @@ -3459,6 +3461,9 @@ panel_operate (void *source_panel, FileOperation operation, gboolean force_singl ret_fast: file_op_context_destroy (ctx); + update_panels (UP_OPTIMIZE, UP_KEEPSEL); + repaint_screen (); + return ret_val; } From 6623a9014fd66029503cdb544b720aae4662a047 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 5 Sep 2021 15:46:41 +0300 Subject: [PATCH 06/33] (panel_operate): update panel content before screen refresh. Signed-off-by: Andrew Borodin --- src/filemanager/file.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/filemanager/file.c b/src/filemanager/file.c index 3414bac0e..1e97ae8f8 100644 --- a/src/filemanager/file.c +++ b/src/filemanager/file.c @@ -3459,10 +3459,9 @@ panel_operate (void *source_panel, FileOperation operation, gboolean force_singl file_op_total_context_destroy (tctx); ret_fast: - file_op_context_destroy (ctx); - + /* update panels before redraw screen in file_op_total_context_destroy() */ update_panels (UP_OPTIMIZE, UP_KEEPSEL); - repaint_screen (); + file_op_context_destroy (ctx); return ret_val; } From 4fce4fa7c344592dbd961d712f1bae45b6afd5dc Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 12 Sep 2021 09:45:09 +0300 Subject: [PATCH 07/33] sftpfs: trivial optimization. * (sftpfs_opendir): call sftpfs_fix_filename() before loop. * (sftpfs_mkdir): likewise. * (sftpfs_rmdir): likewise. * (sftpfs_open_file): likewise. * (sftpfs_stat_init): likewise. * (sftpfs_readlink): likewise. * (sftpfs_utime): likewise. * (sftpfs_chmod): likewise. * (sftpfs_unlink): likewise. * (sftpfs_rename): likewise. Signed-off-by: Andrew Borodin --- src/vfs/sftpfs/dir.c | 20 +++++++++---------- src/vfs/sftpfs/file.c | 6 +++--- src/vfs/sftpfs/internal.c | 42 +++++++++++++++++---------------------- 3 files changed, 30 insertions(+), 38 deletions(-) diff --git a/src/vfs/sftpfs/dir.c b/src/vfs/sftpfs/dir.c index 568827433..6cbfd0628 100644 --- a/src/vfs/sftpfs/dir.c +++ b/src/vfs/sftpfs/dir.c @@ -70,6 +70,7 @@ sftpfs_opendir (const vfs_path_t * vpath, GError ** mcerror) sftpfs_super_t *sftpfs_super; const vfs_path_element_t *path_element; LIBSSH2_SFTP_HANDLE *handle; + const GString *fixfname; mc_return_val_if_error (mcerror, NULL); @@ -80,13 +81,12 @@ sftpfs_opendir (const vfs_path_t * vpath, GError ** mcerror) sftpfs_super = SFTP_SUPER (super); + fixfname = sftpfs_fix_filename (path_element->path); + while (TRUE) { - const GString *fixfname; int libssh_errno; - fixfname = sftpfs_fix_filename (path_element->path); - handle = libssh2_sftp_open_ex (sftpfs_super->sftp_session, fixfname->str, fixfname->len, 0, 0, LIBSSH2_SFTP_OPENDIR); @@ -177,6 +177,7 @@ sftpfs_mkdir (const vfs_path_t * vpath, mode_t mode, GError ** mcerror) struct vfs_s_super *super; sftpfs_super_t *sftpfs_super; const vfs_path_element_t *path_element; + const GString *fixfname; mc_return_val_if_error (mcerror, -1); @@ -192,12 +193,10 @@ sftpfs_mkdir (const vfs_path_t * vpath, mode_t mode, GError ** mcerror) if (sftpfs_super->sftp_session == NULL) return -1; + fixfname = sftpfs_fix_filename (path_element->path); + do { - const GString *fixfname; - - fixfname = sftpfs_fix_filename (path_element->path); - res = libssh2_sftp_mkdir_ex (sftpfs_super->sftp_session, fixfname->str, fixfname->len, mode); if (res >= 0) @@ -227,6 +226,7 @@ sftpfs_rmdir (const vfs_path_t * vpath, GError ** mcerror) struct vfs_s_super *super; sftpfs_super_t *sftpfs_super; const vfs_path_element_t *path_element; + const GString *fixfname; mc_return_val_if_error (mcerror, -1); @@ -242,12 +242,10 @@ sftpfs_rmdir (const vfs_path_t * vpath, GError ** mcerror) if (sftpfs_super->sftp_session == NULL) return -1; + fixfname = sftpfs_fix_filename (path_element->path); + do { - const GString *fixfname; - - fixfname = sftpfs_fix_filename (path_element->path); - res = libssh2_sftp_rmdir_ex (sftpfs_super->sftp_session, fixfname->str, fixfname->len); if (res >= 0) break; diff --git a/src/vfs/sftpfs/file.c b/src/vfs/sftpfs/file.c index 6ef92b832..bd1bb4ee6 100644 --- a/src/vfs/sftpfs/file.c +++ b/src/vfs/sftpfs/file.c @@ -131,6 +131,7 @@ sftpfs_open_file (vfs_file_handler_t * fh, int flags, mode_t mode, GError ** mce sftpfs_file_handler_t *file = SFTP_FILE_HANDLER (fh); sftpfs_super_t *super = SFTP_SUPER (fh->ino->super); char *name; + const GString *fixfname; (void) mode; mc_return_val_if_error (mcerror, FALSE); @@ -156,13 +157,12 @@ sftpfs_open_file (vfs_file_handler_t * fh, int flags, mode_t mode, GError ** mce else sftp_open_flags = LIBSSH2_FXF_READ; + fixfname = sftpfs_fix_filename (name); + while (TRUE) { - const GString *fixfname; int libssh_errno; - fixfname = sftpfs_fix_filename (name); - file->handle = libssh2_sftp_open_ex (super->sftp_session, fixfname->str, fixfname->len, sftp_open_flags, sftp_open_mode, LIBSSH2_SFTP_OPENFILE); diff --git a/src/vfs/sftpfs/internal.c b/src/vfs/sftpfs/internal.c index 016df81e2..b1576efe2 100644 --- a/src/vfs/sftpfs/internal.c +++ b/src/vfs/sftpfs/internal.c @@ -142,17 +142,16 @@ sftpfs_stat_init (sftpfs_super_t ** super, const vfs_path_element_t ** path_elem const vfs_path_t * vpath, GError ** mcerror, int stat_type, LIBSSH2_SFTP_ATTRIBUTES * attrs) { + const GString *fixfname; int res; if (!sftpfs_op_init (super, path_element, vpath, mcerror)) return -1; + fixfname = sftpfs_fix_filename ((*path_element)->path); + do { - const GString *fixfname; - - fixfname = sftpfs_fix_filename ((*path_element)->path); - res = libssh2_sftp_stat_ex ((*super)->sftp_session, fixfname->str, fixfname->len, stat_type, attrs); if (res >= 0) @@ -346,17 +345,16 @@ sftpfs_readlink (const vfs_path_t * vpath, char *buf, size_t size, GError ** mce { sftpfs_super_t *super = NULL; const vfs_path_element_t *path_element = NULL; + const GString *fixfname; int res; if (!sftpfs_op_init (&super, &path_element, vpath, mcerror)) return -1; + fixfname = sftpfs_fix_filename (path_element->path); + do { - const GString *fixfname; - - fixfname = sftpfs_fix_filename (path_element->path); - res = libssh2_sftp_symlink_ex (super->sftp_session, fixfname->str, fixfname->len, buf, size, LIBSSH2_SFTP_READLINK); @@ -442,6 +440,7 @@ sftpfs_utime (const vfs_path_t * vpath, time_t atime, time_t mtime, GError ** mc sftpfs_super_t *super = NULL; const vfs_path_element_t *path_element = NULL; LIBSSH2_SFTP_ATTRIBUTES attrs; + const GString *fixfname; int res; res = sftpfs_stat_init (&super, &path_element, vpath, mcerror, LIBSSH2_SFTP_LSTAT, &attrs); @@ -452,12 +451,10 @@ sftpfs_utime (const vfs_path_t * vpath, time_t atime, time_t mtime, GError ** mc attrs.atime = atime; attrs.mtime = mtime; + fixfname = sftpfs_fix_filename (path_element->path); + do { - const GString *fixfname; - - fixfname = sftpfs_fix_filename (path_element->path); - res = libssh2_sftp_stat_ex (super->sftp_session, fixfname->str, fixfname->len, LIBSSH2_SFTP_SETSTAT, &attrs); @@ -497,6 +494,7 @@ sftpfs_chmod (const vfs_path_t * vpath, mode_t mode, GError ** mcerror) sftpfs_super_t *super = NULL; const vfs_path_element_t *path_element = NULL; LIBSSH2_SFTP_ATTRIBUTES attrs; + const GString *fixfname; int res; res = sftpfs_stat_init (&super, &path_element, vpath, mcerror, LIBSSH2_SFTP_LSTAT, &attrs); @@ -506,12 +504,10 @@ sftpfs_chmod (const vfs_path_t * vpath, mode_t mode, GError ** mcerror) attrs.flags = LIBSSH2_SFTP_ATTR_PERMISSIONS; attrs.permissions = mode; + fixfname = sftpfs_fix_filename (path_element->path); + do { - const GString *fixfname; - - fixfname = sftpfs_fix_filename (path_element->path); - res = libssh2_sftp_stat_ex (super->sftp_session, fixfname->str, fixfname->len, LIBSSH2_SFTP_SETSTAT, &attrs); @@ -549,17 +545,16 @@ sftpfs_unlink (const vfs_path_t * vpath, GError ** mcerror) { sftpfs_super_t *super = NULL; const vfs_path_element_t *path_element = NULL; + const GString *fixfname; int res; if (!sftpfs_op_init (&super, &path_element, vpath, mcerror)) return -1; + fixfname = sftpfs_fix_filename (path_element->path); + do { - const GString *fixfname; - - fixfname = sftpfs_fix_filename (path_element->path); - res = libssh2_sftp_unlink_ex (super->sftp_session, fixfname->str, fixfname->len); if (res >= 0) break; @@ -591,6 +586,7 @@ sftpfs_rename (const vfs_path_t * vpath1, const vfs_path_t * vpath2, GError ** m const GString *ctmp_path; char *tmp_path; unsigned int tmp_path_len; + const GString *fixfname; int res; if (!sftpfs_op_init (&super, &path_element2, vpath2, mcerror)) @@ -602,12 +598,10 @@ sftpfs_rename (const vfs_path_t * vpath1, const vfs_path_t * vpath2, GError ** m path_element1 = vfs_path_get_by_index (vpath1, -1); + fixfname = sftpfs_fix_filename (path_element1->path); + do { - const GString *fixfname; - - fixfname = sftpfs_fix_filename (path_element1->path); - res = libssh2_sftp_rename_ex (super->sftp_session, fixfname->str, fixfname->len, tmp_path, tmp_path_len, LIBSSH2_SFTP_SYMLINK); From d04abc5a7659c617004e7e797bdadcd0c2d5ac08 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 12 Sep 2021 10:13:11 +0300 Subject: [PATCH 08/33] sftpfs: refactoring. Merge init.c, vfs_class.c, and vfs_subclass.c to sftpfs.c. Rename files: init.h -> sftpfs.h. Rename variables: sftpfs_class -> vfs_sftpfs_class. Rename functions: sftpfs_cb_is_equal_connection -> sftpfs_archive_same sftpfs_cb_init_connection -> sftpfs_new_archive sftpfs_cb_open_connection -> sftpfs_open_archive sftpfs_cb_close_connection -> sftpfs_free_archive to be consistent with other VFSes. Signed-off-by: Andrew Borodin --- src/vfs/plugins_init.c | 2 +- src/vfs/sftpfs/Makefile.am | 4 +- src/vfs/sftpfs/file.c | 2 +- src/vfs/sftpfs/init.c | 67 ------- src/vfs/sftpfs/internal.h | 4 +- src/vfs/sftpfs/{vfs_class.c => sftpfs.c} | 233 +++++++++++++++++++---- src/vfs/sftpfs/{init.h => sftpfs.h} | 6 +- src/vfs/sftpfs/vfs_subclass.c | 201 ------------------- 8 files changed, 203 insertions(+), 316 deletions(-) delete mode 100644 src/vfs/sftpfs/init.c rename src/vfs/sftpfs/{vfs_class.c => sftpfs.c} (73%) rename src/vfs/sftpfs/{init.h => sftpfs.h} (87%) delete mode 100644 src/vfs/sftpfs/vfs_subclass.c diff --git a/src/vfs/plugins_init.c b/src/vfs/plugins_init.c index 8383dee9a..7eab57daf 100644 --- a/src/vfs/plugins_init.c +++ b/src/vfs/plugins_init.c @@ -55,7 +55,7 @@ #endif #ifdef ENABLE_VFS_SFTP -#include "sftpfs/init.h" +#include "sftpfs/sftpfs.h" #endif #ifdef ENABLE_VFS_SFS diff --git a/src/vfs/sftpfs/Makefile.am b/src/vfs/sftpfs/Makefile.am index 423f38730..35e25c6cf 100644 --- a/src/vfs/sftpfs/Makefile.am +++ b/src/vfs/sftpfs/Makefile.am @@ -8,7 +8,5 @@ libvfs_sftpfs_la_SOURCES = \ connection.c \ dir.c \ file.c \ - init.c init.h \ internal.c internal.h \ - vfs_class.c \ - vfs_subclass.c + sftpfs.c sftpfs.h diff --git a/src/vfs/sftpfs/file.c b/src/vfs/sftpfs/file.c index bd1bb4ee6..3c98886e7 100644 --- a/src/vfs/sftpfs/file.c +++ b/src/vfs/sftpfs/file.c @@ -136,7 +136,7 @@ sftpfs_open_file (vfs_file_handler_t * fh, int flags, mode_t mode, GError ** mce (void) mode; mc_return_val_if_error (mcerror, FALSE); - name = vfs_s_fullpath (sftpfs_class, fh->ino); + name = vfs_s_fullpath (vfs_sftpfs_ops, fh->ino); if (name == NULL) return FALSE; diff --git a/src/vfs/sftpfs/init.c b/src/vfs/sftpfs/init.c deleted file mode 100644 index fd3505390..000000000 --- a/src/vfs/sftpfs/init.c +++ /dev/null @@ -1,67 +0,0 @@ -/* Virtual File System: SFTP file system. - The interface function - - Copyright (C) 2011-2021 - Free Software Foundation, Inc. - - Written by: - Ilia Maslakov , 2011 - Slava Zanko , 2011, 2012 - - This file is part of the Midnight Commander. - - The Midnight Commander is free software: you can redistribute it - and/or modify it under the terms of the GNU General Public License as - published by the Free Software Foundation, either version 3 of the License, - or (at your option) any later version. - - The Midnight Commander is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - */ - -#include - -#include "lib/global.h" -#include "lib/vfs/netutil.h" - -#include "init.h" -#include "internal.h" - -/*** global variables ****************************************************************************/ - -struct vfs_s_subclass sftpfs_subclass; -struct vfs_class *sftpfs_class = VFS_CLASS (&sftpfs_subclass); - -/*** file scope macro definitions ****************************************************************/ - -/*** file scope type declarations ****************************************************************/ - -/*** file scope variables ************************************************************************/ - -/*** file scope functions ************************************************************************/ -/* --------------------------------------------------------------------------------------------- */ - -/* --------------------------------------------------------------------------------------------- */ -/*** public functions ****************************************************************************/ -/* --------------------------------------------------------------------------------------------- */ -/** - * Initialization of SFTP Virtual File Sysytem. - */ - -void -vfs_init_sftpfs (void) -{ - tcp_init (); - - vfs_init_subclass (&sftpfs_subclass, "sftpfs", VFSF_NOLINKS | VFSF_REMOTE, "sftp"); - sftpfs_init_class (); - sftpfs_init_subclass (); - vfs_register_class (sftpfs_class); -} - -/* --------------------------------------------------------------------------------------------- */ diff --git a/src/vfs/sftpfs/internal.h b/src/vfs/sftpfs/internal.h index 643ce5e3c..bf3fd3018 100644 --- a/src/vfs/sftpfs/internal.h +++ b/src/vfs/sftpfs/internal.h @@ -62,12 +62,10 @@ typedef struct extern GString *sftpfs_filename_buffer; extern struct vfs_s_subclass sftpfs_subclass; -extern struct vfs_class *sftpfs_class; +extern struct vfs_class *vfs_sftpfs_ops; /*** declarations of public functions ************************************************************/ -void sftpfs_init_class (void); -void sftpfs_init_subclass (void); void sftpfs_init_config_variables_patterns (void); void sftpfs_deinit_config_variables_patterns (void); diff --git a/src/vfs/sftpfs/vfs_class.c b/src/vfs/sftpfs/sftpfs.c similarity index 73% rename from src/vfs/sftpfs/vfs_class.c rename to src/vfs/sftpfs/sftpfs.c index 472c8d79c..5e620a77f 100644 --- a/src/vfs/sftpfs/vfs_class.c +++ b/src/vfs/sftpfs/sftpfs.c @@ -1,12 +1,13 @@ /* Virtual File System: SFTP file system. - The VFS class functions + The interface function Copyright (C) 2011-2021 Free Software Foundation, Inc. Written by: Ilia Maslakov , 2011 - Slava Zanko , 2011, 2012 + Slava Zanko , 2011-2013 + Andrew Borodin , 2021 This file is part of the Midnight Commander. @@ -26,22 +27,32 @@ #include #include +#include +#include /* memset() */ #include "lib/global.h" -#include "lib/widget.h" +#include "lib/vfs/netutil.h" +#include "lib/vfs/utilvfs.h" #include "lib/vfs/gc.h" +#include "lib/widget.h" #include "lib/tty/tty.h" /* tty_enable_interrupt_key () */ #include "internal.h" +#include "sftpfs.h" + /*** global variables ****************************************************************************/ +struct vfs_s_subclass sftpfs_subclass; +struct vfs_class *vfs_sftpfs_ops = VFS_CLASS (&sftpfs_subclass); /* used in file.c */ + /*** file scope macro definitions ****************************************************************/ /*** file scope type declarations ****************************************************************/ /*** file scope variables ************************************************************************/ +/* --------------------------------------------------------------------------------------------- */ /*** file scope functions ************************************************************************/ /* --------------------------------------------------------------------------------------------- */ /** @@ -326,6 +337,7 @@ sftpfs_cb_utime (const vfs_path_t * vpath, mc_timesbuf_t * times) { int rc; GError *mcerror = NULL; + #ifdef HAVE_UTIMENSAT time_t atime = (*times)[0].tv_sec; time_t mtime = (*times)[1].tv_sec; @@ -485,7 +497,7 @@ sftpfs_cb_close (void *data) super->fd_usage--; if (super->fd_usage == 0) - vfs_stamp_create (sftpfs_class, super); + vfs_stamp_create (vfs_sftpfs_ops, super); rc = sftpfs_close_file (fh, &mcerror); mc_error_message (&mcerror, NULL); @@ -493,7 +505,7 @@ sftpfs_cb_close (void *data) if (fh->handle != -1) close (fh->handle); - vfs_s_free_inode (sftpfs_class, fh->ino); + vfs_s_free_inode (vfs_sftpfs_ops, fh->ino); return rc; } @@ -630,6 +642,7 @@ static int sftpfs_cb_errno (struct vfs_class *me) { (void) me; + return errno; } @@ -661,48 +674,194 @@ sftpfs_cb_fill_names (struct vfs_class *me, fill_names_f func) } } -/* --------------------------------------------------------------------------------------------- */ -/*** public functions ****************************************************************************/ /* --------------------------------------------------------------------------------------------- */ /** - * Initialization of VFS class structure. + * Callback for checking if connection is equal to existing connection. * - * @return the VFS class structure. + * @param vpath_element path element with connetion data + * @param super data with exists connection + * @param vpath unused + * @param cookie unused + * @return TRUE if connections is equal, FALSE otherwise */ -void -sftpfs_init_class (void) +static gboolean +sftpfs_archive_same (const vfs_path_element_t * vpath_element, struct vfs_s_super *super, + const vfs_path_t * vpath, void *cookie) { - sftpfs_class->init = sftpfs_cb_init; - sftpfs_class->done = sftpfs_cb_done; + int result; + vfs_path_element_t *orig_connect_info; - sftpfs_class->fill_names = sftpfs_cb_fill_names; + (void) vpath; + (void) cookie; - sftpfs_class->opendir = sftpfs_cb_opendir; - sftpfs_class->readdir = sftpfs_cb_readdir; - sftpfs_class->closedir = sftpfs_cb_closedir; - sftpfs_class->mkdir = sftpfs_cb_mkdir; - sftpfs_class->rmdir = sftpfs_cb_rmdir; + orig_connect_info = SFTP_SUPER (super)->original_connection_info; - sftpfs_class->stat = sftpfs_cb_stat; - sftpfs_class->lstat = sftpfs_cb_lstat; - sftpfs_class->fstat = sftpfs_cb_fstat; - sftpfs_class->readlink = sftpfs_cb_readlink; - sftpfs_class->symlink = sftpfs_cb_symlink; - sftpfs_class->link = sftpfs_cb_link; - sftpfs_class->utime = sftpfs_cb_utime; - sftpfs_class->mknod = sftpfs_cb_mknod; - sftpfs_class->chown = sftpfs_cb_chown; - sftpfs_class->chmod = sftpfs_cb_chmod; + result = ((g_strcmp0 (vpath_element->host, orig_connect_info->host) == 0) + && (g_strcmp0 (vpath_element->user, orig_connect_info->user) == 0) + && (vpath_element->port == orig_connect_info->port)); - sftpfs_class->open = sftpfs_cb_open; - sftpfs_class->read = sftpfs_cb_read; - sftpfs_class->write = sftpfs_cb_write; - sftpfs_class->close = sftpfs_cb_close; - sftpfs_class->lseek = sftpfs_cb_lseek; - sftpfs_class->unlink = sftpfs_cb_unlink; - sftpfs_class->rename = sftpfs_cb_rename; - sftpfs_class->ferrno = sftpfs_cb_errno; + return result; +} + +/* --------------------------------------------------------------------------------------------- */ + +static struct vfs_s_super * +sftpfs_new_archive (struct vfs_class *me) +{ + sftpfs_super_t *arch; + + arch = g_new0 (sftpfs_super_t, 1); + arch->base.me = me; + arch->base.name = g_strdup (PATH_SEP_STR); + arch->auth_type = NONE; + arch->config_auth_type = NONE; + arch->socket_handle = LIBSSH2_INVALID_SOCKET; + + return VFS_SUPER (arch); +} + +/* --------------------------------------------------------------------------------------------- */ +/** + * Callback for opening new connection. + * + * @param super connection data + * @param vpath unused + * @param vpath_element path element with connetion data + * @return 0 if success, -1 otherwise + */ + +static int +sftpfs_open_archive (struct vfs_s_super *super, const vfs_path_t * vpath, + const vfs_path_element_t * vpath_element) +{ + GError *mcerror = NULL; + sftpfs_super_t *sftpfs_super = SFTP_SUPER (super); + int ret_value; + + (void) vpath; + + if (vpath_element->host == NULL || *vpath_element->host == '\0') + { + vfs_print_message ("%s", _("sftp: Invalid host name.")); + vpath_element->class->verrno = EPERM; + return -1; + } + + sftpfs_super->original_connection_info = vfs_path_element_clone (vpath_element); + super->path_element = vfs_path_element_clone (vpath_element); + + sftpfs_fill_connection_data_from_config (super, &mcerror); + if (mc_error_message (&mcerror, &ret_value)) + { + vpath_element->class->verrno = ret_value; + return -1; + } + + super->root = + vfs_s_new_inode (vpath_element->class, super, + vfs_s_default_stat (vpath_element->class, S_IFDIR | 0755)); + + ret_value = sftpfs_open_connection (super, &mcerror); + mc_error_message (&mcerror, NULL); + return ret_value; +} + +/* --------------------------------------------------------------------------------------------- */ +/** + * Callback for closing connection. + * + * @param me unused + * @param super connection data + */ + +static void +sftpfs_free_archive (struct vfs_class *me, struct vfs_s_super *super) +{ + GError *mcerror = NULL; + + (void) me; + + sftpfs_close_connection (super, "Normal Shutdown", &mcerror); + + vfs_path_element_free (SFTP_SUPER (super)->original_connection_info); + + mc_error_message (&mcerror, NULL); +} + +/* --------------------------------------------------------------------------------------------- */ +/** + * Callback for getting directory content. + * + * @param me unused + * @param dir unused + * @param remote_path unused + * @return always 0 + */ + +static int +sftpfs_cb_dir_load (struct vfs_class *me, struct vfs_s_inode *dir, char *remote_path) +{ + (void) me; + (void) dir; + (void) remote_path; + + return 0; +} + +/* --------------------------------------------------------------------------------------------- */ +/*** public functions ****************************************************************************/ +/* --------------------------------------------------------------------------------------------- */ +/** + * Initialization of SFTP Virtual File Sysytem. + */ + +void +vfs_init_sftpfs (void) +{ + tcp_init (); + + vfs_init_subclass (&sftpfs_subclass, "sftpfs", VFSF_NOLINKS | VFSF_REMOTE, "sftp"); + + vfs_sftpfs_ops->init = sftpfs_cb_init; + vfs_sftpfs_ops->done = sftpfs_cb_done; + + vfs_sftpfs_ops->fill_names = sftpfs_cb_fill_names; + + vfs_sftpfs_ops->opendir = sftpfs_cb_opendir; + vfs_sftpfs_ops->readdir = sftpfs_cb_readdir; + vfs_sftpfs_ops->closedir = sftpfs_cb_closedir; + vfs_sftpfs_ops->mkdir = sftpfs_cb_mkdir; + vfs_sftpfs_ops->rmdir = sftpfs_cb_rmdir; + + vfs_sftpfs_ops->stat = sftpfs_cb_stat; + vfs_sftpfs_ops->lstat = sftpfs_cb_lstat; + vfs_sftpfs_ops->fstat = sftpfs_cb_fstat; + vfs_sftpfs_ops->readlink = sftpfs_cb_readlink; + vfs_sftpfs_ops->symlink = sftpfs_cb_symlink; + vfs_sftpfs_ops->link = sftpfs_cb_link; + vfs_sftpfs_ops->utime = sftpfs_cb_utime; + vfs_sftpfs_ops->mknod = sftpfs_cb_mknod; + vfs_sftpfs_ops->chown = sftpfs_cb_chown; + vfs_sftpfs_ops->chmod = sftpfs_cb_chmod; + + vfs_sftpfs_ops->open = sftpfs_cb_open; + vfs_sftpfs_ops->read = sftpfs_cb_read; + vfs_sftpfs_ops->write = sftpfs_cb_write; + vfs_sftpfs_ops->close = sftpfs_cb_close; + vfs_sftpfs_ops->lseek = sftpfs_cb_lseek; + vfs_sftpfs_ops->unlink = sftpfs_cb_unlink; + vfs_sftpfs_ops->rename = sftpfs_cb_rename; + vfs_sftpfs_ops->ferrno = sftpfs_cb_errno; + + sftpfs_subclass.archive_same = sftpfs_archive_same; + sftpfs_subclass.new_archive = sftpfs_new_archive; + sftpfs_subclass.open_archive = sftpfs_open_archive; + sftpfs_subclass.free_archive = sftpfs_free_archive; + sftpfs_subclass.fh_new = sftpfs_fh_new; + sftpfs_subclass.dir_load = sftpfs_cb_dir_load; + + vfs_register_class (vfs_sftpfs_ops); } /* --------------------------------------------------------------------------------------------- */ diff --git a/src/vfs/sftpfs/init.h b/src/vfs/sftpfs/sftpfs.h similarity index 87% rename from src/vfs/sftpfs/init.h rename to src/vfs/sftpfs/sftpfs.h index 7ad0bce85..d3a193510 100644 --- a/src/vfs/sftpfs/init.h +++ b/src/vfs/sftpfs/sftpfs.h @@ -3,8 +3,8 @@ * \brief Header: SFTP FS */ -#ifndef MC__VFS_SFTPFS_INIT_H -#define MC__VFS_SFTPFS_INIT_H +#ifndef MC__VFS_SFTPFS_H +#define MC__VFS_SFTPFS_H /*** typedefs(not structures) and defined constants **********************************************/ @@ -20,4 +20,4 @@ void vfs_init_sftpfs (void); /*** inline functions ****************************************************************************/ -#endif /* MC__VFS_SFTPFS_INIT_H */ +#endif /* MC__VFS_SFTPFS_H */ diff --git a/src/vfs/sftpfs/vfs_subclass.c b/src/vfs/sftpfs/vfs_subclass.c deleted file mode 100644 index 0094d51d3..000000000 --- a/src/vfs/sftpfs/vfs_subclass.c +++ /dev/null @@ -1,201 +0,0 @@ -/* Virtual File System: SFTP file system. - The VFS subclass functions - - Copyright (C) 2011-2021 - Free Software Foundation, Inc. - - Written by: - Ilia Maslakov , 2011 - Slava Zanko , 2011, 2012, 2013 - - This file is part of the Midnight Commander. - - The Midnight Commander is free software: you can redistribute it - and/or modify it under the terms of the GNU General Public License as - published by the Free Software Foundation, either version 3 of the License, - or (at your option) any later version. - - The Midnight Commander is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - */ - -#include -#include -#include -#include /* memset() */ - -#include "lib/global.h" -#include "lib/widget.h" -#include "lib/vfs/utilvfs.h" - -#include "internal.h" - -/*** global variables ****************************************************************************/ - -/*** file scope macro definitions ****************************************************************/ - -/*** file scope type declarations ****************************************************************/ - -/*** file scope variables ************************************************************************/ - -/*** file scope functions ************************************************************************/ -/* --------------------------------------------------------------------------------------------- */ -/** - * Callback for checking if connection is equal to existing connection. - * - * @param vpath_element path element with connetion data - * @param super data with exists connection - * @param vpath unused - * @param cookie unused - * @return TRUE if connections is equal, FALSE otherwise - */ - -static gboolean -sftpfs_cb_is_equal_connection (const vfs_path_element_t * vpath_element, struct vfs_s_super *super, - const vfs_path_t * vpath, void *cookie) -{ - int result; - vfs_path_element_t *orig_connect_info; - - (void) vpath; - (void) cookie; - - orig_connect_info = SFTP_SUPER (super)->original_connection_info; - - result = ((g_strcmp0 (vpath_element->host, orig_connect_info->host) == 0) - && (g_strcmp0 (vpath_element->user, orig_connect_info->user) == 0) - && (vpath_element->port == orig_connect_info->port)); - - return result; -} - -/* --------------------------------------------------------------------------------------------- */ - -static struct vfs_s_super * -sftpfs_cb_init_connection (struct vfs_class *me) -{ - sftpfs_super_t *arch; - - arch = g_new0 (sftpfs_super_t, 1); - arch->base.me = me; - arch->base.name = g_strdup (PATH_SEP_STR); - arch->auth_type = NONE; - arch->config_auth_type = NONE; - arch->socket_handle = LIBSSH2_INVALID_SOCKET; - - return VFS_SUPER (arch); -} - -/* --------------------------------------------------------------------------------------------- */ -/** - * Callback for opening new connection. - * - * @param super connection data - * @param vpath unused - * @param vpath_element path element with connetion data - * @return 0 if success, -1 otherwise - */ - -static int -sftpfs_cb_open_connection (struct vfs_s_super *super, - const vfs_path_t * vpath, const vfs_path_element_t * vpath_element) -{ - GError *mcerror = NULL; - sftpfs_super_t *sftpfs_super = SFTP_SUPER (super); - int ret_value; - - (void) vpath; - - if (vpath_element->host == NULL || *vpath_element->host == '\0') - { - vfs_print_message ("%s", _("sftp: Invalid host name.")); - vpath_element->class->verrno = EPERM; - return -1; - } - - sftpfs_super->original_connection_info = vfs_path_element_clone (vpath_element); - super->path_element = vfs_path_element_clone (vpath_element); - - sftpfs_fill_connection_data_from_config (super, &mcerror); - if (mc_error_message (&mcerror, &ret_value)) - { - vpath_element->class->verrno = ret_value; - return -1; - } - - super->root = - vfs_s_new_inode (vpath_element->class, super, - vfs_s_default_stat (vpath_element->class, S_IFDIR | 0755)); - - ret_value = sftpfs_open_connection (super, &mcerror); - mc_error_message (&mcerror, NULL); - return ret_value; -} - -/* --------------------------------------------------------------------------------------------- */ -/** - * Callback for closing connection. - * - * @param me unused - * @param super connection data - */ - -static void -sftpfs_cb_close_connection (struct vfs_class *me, struct vfs_s_super *super) -{ - GError *mcerror = NULL; - - (void) me; - sftpfs_close_connection (super, "Normal Shutdown", &mcerror); - - vfs_path_element_free (SFTP_SUPER (super)->original_connection_info); - - mc_error_message (&mcerror, NULL); -} - -/* --------------------------------------------------------------------------------------------- */ -/** - * Callback for getting directory content. - * - * @param me unused - * @param dir unused - * @param remote_path unused - * @return always 0 - */ - -static int -sftpfs_cb_dir_load (struct vfs_class *me, struct vfs_s_inode *dir, char *remote_path) -{ - (void) me; - (void) dir; - (void) remote_path; - - return 0; -} - -/* --------------------------------------------------------------------------------------------- */ -/*** public functions ****************************************************************************/ -/* --------------------------------------------------------------------------------------------- */ -/** - * Initialization of VFS subclass structure. - * - * @return VFS subclass structure. - */ - -void -sftpfs_init_subclass (void) -{ - sftpfs_subclass.archive_same = sftpfs_cb_is_equal_connection; - sftpfs_subclass.new_archive = sftpfs_cb_init_connection; - sftpfs_subclass.open_archive = sftpfs_cb_open_connection; - sftpfs_subclass.free_archive = sftpfs_cb_close_connection; - sftpfs_subclass.fh_new = sftpfs_fh_new; - sftpfs_subclass.dir_load = sftpfs_cb_dir_load; -} - -/* --------------------------------------------------------------------------------------------- */ From 437211791f3cd47407c77450cb0f2f4d1e4a9faa Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 19 Jun 2021 13:21:28 +0300 Subject: [PATCH 09/33] file operations: use g_get_real_time() instead of gettimeofday(). Signed-off-by: Andrew Borodin --- src/filemanager/file.c | 79 ++++++++++++++++++------------------- src/filemanager/filegui.c | 6 +-- src/filemanager/fileopctx.h | 3 +- 3 files changed, 43 insertions(+), 45 deletions(-) diff --git a/src/filemanager/file.c b/src/filemanager/file.c index 1e97ae8f8..25c0cf117 100644 --- a/src/filemanager/file.c +++ b/src/filemanager/file.c @@ -101,6 +101,8 @@ const char *op_names[3] = { #define FILEOP_UPDATE_INTERVAL 2 #define FILEOP_STALLING_INTERVAL 4 +#define FILEOP_UPDATE_INTERVAL_US (FILEOP_UPDATE_INTERVAL * G_USEC_PER_SEC) +#define FILEOP_STALLING_INTERVAL_US (FILEOP_STALLING_INTERVAL * G_USEC_PER_SEC) /*** file scope type declarations ****************************************************************/ @@ -809,25 +811,26 @@ panel_operate_init_totals (const WPanel * panel, const vfs_path_t * source, static FileProgressStatus progress_update_one (file_op_total_context_t * tctx, file_op_context_t * ctx, off_t add) { - struct timeval tv_current; - static struct timeval tv_start = { 0, 0 }; + gint64 tv_current; + static gint64 tv_start = -1; tctx->progress_count++; tctx->progress_bytes += (uintmax_t) add; - if (tv_start.tv_sec == 0) - { - gettimeofday (&tv_start, (struct timezone *) NULL); - } - gettimeofday (&tv_current, (struct timezone *) NULL); - if ((tv_current.tv_sec - tv_start.tv_sec) > FILEOP_UPDATE_INTERVAL) + if (tv_start < 0) + tv_start = g_get_real_time (); + + tv_current = g_get_real_time (); + + if (tv_current - tv_start > FILEOP_UPDATE_INTERVAL_US) { if (verbose && ctx->dialog_type == FILEGUI_DIALOG_MULTI_ITEM) { file_progress_show_count (ctx, tctx->progress_count, ctx->progress_count); file_progress_show_total (tctx, ctx, tctx->progress_bytes, TRUE); } - tv_start.tv_sec = tv_current.tv_sec; + + tv_start = tv_current; } return check_progress_buttons (ctx); @@ -1109,16 +1112,16 @@ files_error (const char *format, const char *file1, const char *file2) static void copy_file_file_display_progress (file_op_total_context_t * tctx, file_op_context_t * ctx, - struct timeval tv_current, struct timeval tv_transfer_start, - off_t file_size, off_t n_read_total) + gint64 tv_current, gint64 tv_transfer_start, off_t file_size, + off_t n_read_total) { - long dt; + gint64 dt; - /* 1. Update rotating dash after some time */ + /* Update rotating dash after some time */ rotate_dash (TRUE); - /* 3. Compute ETA */ - dt = (tv_current.tv_sec - tv_transfer_start.tv_sec); + /* Compute ETA */ + dt = (tv_current - tv_transfer_start) / G_USEC_PER_SEC; if (n_read_total == 0) ctx->eta_secs = 0.0; @@ -1128,13 +1131,11 @@ copy_file_file_display_progress (file_op_total_context_t * tctx, file_op_context ctx->bps = n_read_total / ((dt < 1) ? 1 : dt); } - /* 4. Compute BPS rate */ - ctx->bps_time = (tv_current.tv_sec - tv_transfer_start.tv_sec); - if (ctx->bps_time < 1) - ctx->bps_time = 1; + /* Compute BPS rate */ + ctx->bps_time = MAX (1, dt); ctx->bps = n_read_total / ctx->bps_time; - /* 5. Compute total ETA and BPS */ + /* Compute total ETA and BPS */ if (ctx->progress_bytes != 0) { uintmax_t remain_bytes; @@ -1142,10 +1143,10 @@ copy_file_file_display_progress (file_op_total_context_t * tctx, file_op_context remain_bytes = ctx->progress_bytes - tctx->copied_bytes; #if 1 { - int total_secs = tv_current.tv_sec - tctx->transfer_start.tv_sec; + gint64 total_secs; - if (total_secs < 1) - total_secs = 1; + total_secs = (tv_current - tctx->transfer_start) / G_USEC_PER_SEC; + total_secs = MAX (1, total_secs); tctx->bps = tctx->copied_bytes / total_secs; tctx->eta_secs = (tctx->bps != 0) ? remain_bytes / tctx->bps : 0; @@ -2224,7 +2225,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, gboolean dst_exists = FALSE, appending = FALSE; off_t file_size = -1; FileProgressStatus return_status, temp_status; - struct timeval tv_transfer_start; + gint64 tv_transfer_start; dest_status_t dst_status = DEST_NONE; int open_flags; vfs_path_t *src_vpath = NULL, *dst_vpath = NULL; @@ -2390,7 +2391,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, } } - gettimeofday (&tv_transfer_start, (struct timezone *) NULL); + tv_transfer_start = g_get_real_time (); while ((src_desc = mc_open (src_vpath, O_RDONLY | O_LINEAR)) < 0 && !ctx->skip_all) { @@ -2529,7 +2530,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, ctx->eta_secs = 0.0; ctx->bps = 0; - if (tctx->bps == 0 || (file_size / (tctx->bps)) > FILEOP_UPDATE_INTERVAL) + if (tctx->bps == 0 || (file_size / tctx->bps) > FILEOP_UPDATE_INTERVAL) file_progress_show (ctx, 0, file_size, "", TRUE); else file_progress_show (ctx, 1, 1, "", TRUE); @@ -2540,8 +2541,8 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, { size_t bufsize; off_t n_read_total = 0; - struct timeval tv_current, tv_last_update, tv_last_input; - int secs, update_secs; + gint64 tv_current, tv_last_update, tv_last_input; + gint64 usecs, update_usecs; const char *stalled_msg = ""; gboolean is_first_time = TRUE; @@ -2571,7 +2572,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, if (n_read == 0) break; - gettimeofday (&tv_current, NULL); + tv_current = g_get_real_time (); if (n_read > 0) { @@ -2579,7 +2580,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, n_read_total += n_read; - gettimeofday (&tv_last_input, NULL); + tv_last_input = g_get_real_time (); /* dst_write */ while ((n_written = mc_write (dest_desc, t, (size_t) n_read)) < n_read) @@ -2620,24 +2621,22 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, tctx->copied_bytes = tctx->progress_bytes + n_read_total + ctx->do_reget; - secs = (tv_current.tv_sec - tv_last_update.tv_sec); - update_secs = (tv_current.tv_sec - tv_last_input.tv_sec); + usecs = tv_current - tv_last_update; + update_usecs = tv_current - tv_last_input; - if (is_first_time || secs > FILEOP_UPDATE_INTERVAL) + if (is_first_time || usecs > FILEOP_UPDATE_INTERVAL_US) { - copy_file_file_display_progress (tctx, ctx, - tv_current, - tv_transfer_start, file_size, n_read_total); + copy_file_file_display_progress (tctx, ctx, tv_current, tv_transfer_start, + file_size, n_read_total); tv_last_update = tv_current; } is_first_time = FALSE; - if (update_secs > FILEOP_STALLING_INTERVAL) + if (update_usecs > FILEOP_STALLING_INTERVAL_US) stalled_msg = _("(stalled)"); - force_update = - (tv_current.tv_sec - tctx->transfer_start.tv_sec) > FILEOP_UPDATE_INTERVAL; + force_update = (tv_current - tctx->transfer_start) > FILEOP_UPDATE_INTERVAL_US; if (verbose && ctx->dialog_type == FILEGUI_DIALOG_MULTI_ITEM) { @@ -3273,7 +3272,7 @@ panel_operate (void *source_panel, FileOperation operation, gboolean force_singl } tctx = file_op_total_context_new (); - gettimeofday (&tctx->transfer_start, (struct timezone *) NULL); + tctx->transfer_start = g_get_real_time (); #ifdef ENABLE_BACKGROUND /* Did the user select to do a background operation? */ diff --git a/src/filemanager/filegui.c b/src/filemanager/filegui.c index 446eeed1f..ea02b9f26 100644 --- a/src/filemanager/filegui.c +++ b/src/filemanager/filegui.c @@ -1057,11 +1057,11 @@ file_progress_show_total (file_op_total_context_t * tctx, file_op_context_t * ct if (ui->time_label != NULL) { - struct timeval tv_current; + gint64 tv_current; char buffer4[BUF_TINY]; - gettimeofday (&tv_current, NULL); - file_frmt_time (buffer2, tv_current.tv_sec - tctx->transfer_start.tv_sec); + tv_current = g_get_real_time (); + file_frmt_time (buffer2, (tv_current - tctx->transfer_start) / G_USEC_PER_SEC); if (ctx->progress_totals_computed) { diff --git a/src/filemanager/fileopctx.h b/src/filemanager/fileopctx.h index 89170fdc2..348507e26 100644 --- a/src/filemanager/fileopctx.h +++ b/src/filemanager/fileopctx.h @@ -10,7 +10,6 @@ #include #include -#include #include /* uintmax_t */ #include "lib/global.h" @@ -171,7 +170,7 @@ typedef struct uintmax_t copied_bytes; size_t bps; size_t bps_count; - struct timeval transfer_start; + gint64 transfer_start; double eta_secs; gboolean ask_overwrite; From 78df2f5b56da6b70439d4a1d7d12d98c73cc88ef Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 19 Jun 2021 13:38:27 +0300 Subject: [PATCH 10/33] (progress_update_one): don't call g_get_real_time() twice at first time. Signed-off-by: Andrew Borodin --- src/filemanager/file.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/filemanager/file.c b/src/filemanager/file.c index 25c0cf117..9140caa84 100644 --- a/src/filemanager/file.c +++ b/src/filemanager/file.c @@ -817,11 +817,11 @@ progress_update_one (file_op_total_context_t * tctx, file_op_context_t * ctx, of tctx->progress_count++; tctx->progress_bytes += (uintmax_t) add; - if (tv_start < 0) - tv_start = g_get_real_time (); - tv_current = g_get_real_time (); + if (tv_start < 0) + tv_start = tv_current; + if (tv_current - tv_start > FILEOP_UPDATE_INTERVAL_US) { if (verbose && ctx->dialog_type == FILEGUI_DIALOG_MULTI_ITEM) From bb1ab8488b530c9cdbc5dd5e6d57e2c120c7be53 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 19 Jun 2021 15:07:45 +0300 Subject: [PATCH 11/33] (copy_file_file_display_progress): don't calculate BPS twice. Signed-off-by: Andrew Borodin --- src/filemanager/file.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/filemanager/file.c b/src/filemanager/file.c index 9140caa84..23e68b743 100644 --- a/src/filemanager/file.c +++ b/src/filemanager/file.c @@ -1126,10 +1126,7 @@ copy_file_file_display_progress (file_op_total_context_t * tctx, file_op_context if (n_read_total == 0) ctx->eta_secs = 0.0; else - { ctx->eta_secs = ((dt / (double) n_read_total) * file_size) - dt; - ctx->bps = n_read_total / ((dt < 1) ? 1 : dt); - } /* Compute BPS rate */ ctx->bps_time = MAX (1, dt); From e8e3204e6140fd35f5f36b1e83fd659568b2f056 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 19 Jun 2021 13:49:22 +0300 Subject: [PATCH 12/33] (copy_file_file): don't call g_get_real_time() twice... in case of successful copying of file content. Signed-off-by: Andrew Borodin --- src/filemanager/file.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/filemanager/file.c b/src/filemanager/file.c index 23e68b743..fc5997542 100644 --- a/src/filemanager/file.c +++ b/src/filemanager/file.c @@ -2538,7 +2538,8 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, { size_t bufsize; off_t n_read_total = 0; - gint64 tv_current, tv_last_update, tv_last_input; + gint64 tv_current, tv_last_update; + gint64 tv_last_input = 0; gint64 usecs, update_usecs; const char *stalled_msg = ""; gboolean is_first_time = TRUE; @@ -2577,7 +2578,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, n_read_total += n_read; - tv_last_input = g_get_real_time (); + tv_last_input = tv_current; /* dst_write */ while ((n_written = mc_write (dest_desc, t, (size_t) n_read)) < n_read) From eefc7c12752db6219475e241a90939a4a1e2af94 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 19 Jun 2021 14:17:04 +0300 Subject: [PATCH 13/33] (copy_file_file_display_progress): rename argument to make it clearer. (copy_file_file): rename variable to make it clearer. Signed-off-by: Andrew Borodin --- src/filemanager/file.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/filemanager/file.c b/src/filemanager/file.c index fc5997542..611d39e65 100644 --- a/src/filemanager/file.c +++ b/src/filemanager/file.c @@ -1113,7 +1113,7 @@ files_error (const char *format, const char *file1, const char *file2) static void copy_file_file_display_progress (file_op_total_context_t * tctx, file_op_context_t * ctx, gint64 tv_current, gint64 tv_transfer_start, off_t file_size, - off_t n_read_total) + off_t file_part) { gint64 dt; @@ -1123,14 +1123,14 @@ copy_file_file_display_progress (file_op_total_context_t * tctx, file_op_context /* Compute ETA */ dt = (tv_current - tv_transfer_start) / G_USEC_PER_SEC; - if (n_read_total == 0) + if (file_part == 0) ctx->eta_secs = 0.0; else - ctx->eta_secs = ((dt / (double) n_read_total) * file_size) - dt; + ctx->eta_secs = ((dt / (double) file_part) * file_size) - dt; /* Compute BPS rate */ ctx->bps_time = MAX (1, dt); - ctx->bps = n_read_total / ctx->bps_time; + ctx->bps = file_part / ctx->bps_time; /* Compute total ETA and BPS */ if (ctx->progress_bytes != 0) @@ -2537,7 +2537,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, if (return_status == FILE_CONT) { size_t bufsize; - off_t n_read_total = 0; + off_t file_part = 0; gint64 tv_current, tv_last_update; gint64 tv_last_input = 0; gint64 usecs, update_usecs; @@ -2576,7 +2576,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, { char *t = buf; - n_read_total += n_read; + file_part += n_read; tv_last_input = tv_current; @@ -2617,7 +2617,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, } } - tctx->copied_bytes = tctx->progress_bytes + n_read_total + ctx->do_reget; + tctx->copied_bytes = tctx->progress_bytes + file_part + ctx->do_reget; usecs = tv_current - tv_last_update; update_usecs = tv_current - tv_last_input; @@ -2625,7 +2625,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, if (is_first_time || usecs > FILEOP_UPDATE_INTERVAL_US) { copy_file_file_display_progress (tctx, ctx, tv_current, tv_transfer_start, - file_size, n_read_total); + file_size, file_part); tv_last_update = tv_current; } @@ -2642,7 +2642,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, file_progress_show_total (tctx, ctx, tctx->copied_bytes, force_update); } - file_progress_show (ctx, n_read_total + ctx->do_reget, file_size, stalled_msg, + file_progress_show (ctx, file_part + ctx->do_reget, file_size, stalled_msg, force_update); mc_refresh (); From 93a4ecc11eb7629c79996f0c8e19437adc149b20 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 19 Sep 2021 14:43:18 +0300 Subject: [PATCH 14/33] lib/keybind.h: remove unneeded includes. Signed-off-by: Andrew Borodin --- lib/keybind.h | 3 --- 1 file changed, 3 deletions(-) diff --git a/lib/keybind.h b/lib/keybind.h index 965fef7fb..9c0fe98a1 100644 --- a/lib/keybind.h +++ b/lib/keybind.h @@ -1,9 +1,6 @@ #ifndef MC__KEYBIND_H #define MC__KEYBIND_H -#include -#include /* time_t */ - #include "lib/global.h" /*** typedefs(not structures) and defined constants **********************************************/ From c32c4b316b25cedd3095b94bdeb2de6a93937a93 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 19 Sep 2021 14:43:48 +0300 Subject: [PATCH 15/33] lib/util.c: remove unneeded include. Signed-off-by: Andrew Borodin --- lib/util.c | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/util.c b/lib/util.c index 0692e983e..8d36ebdf9 100644 --- a/lib/util.c +++ b/lib/util.c @@ -40,7 +40,6 @@ #include #include #include -#include #include #include #include From 62d2580302678f29a0129bb796d3a24f2b8d38b8 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 19 Sep 2021 17:13:56 +0300 Subject: [PATCH 16/33] Reimplement compiler options checking. --- acinclude.m4 | 4 + configure.ac | 2 +- m4.include/ax_append_compile_flags.m4 | 46 ++++++++ m4.include/ax_append_flag.m4 | 50 ++++++++ m4.include/ax_check_compile_flag.m4 | 53 +++++++++ m4.include/ax_require_defined.m4 | 37 ++++++ m4.include/mc-cflags.m4 | 162 ++++++++++++-------------- 7 files changed, 264 insertions(+), 90 deletions(-) create mode 100644 m4.include/ax_append_compile_flags.m4 create mode 100644 m4.include/ax_append_flag.m4 create mode 100644 m4.include/ax_check_compile_flag.m4 create mode 100644 m4.include/ax_require_defined.m4 diff --git a/acinclude.m4 b/acinclude.m4 index 41aea5917..0422d7ff1 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -7,6 +7,10 @@ m4_include([m4.include/gnulib/windows-stat-inodes.m4]) m4_include([m4.include/gnulib/sys_types_h.m4]) m4_include([m4.include/ax_path_lib_pcre.m4]) m4_include([m4.include/dx_doxygen.m4]) +m4_include([m4.include/ax_require_defined.m4]) +m4_include([m4.include/ax_check_compile_flag.m4]) +m4_include([m4.include/ax_append_flag.m4]) +m4_include([m4.include/ax_append_compile_flags.m4]) m4_include([m4.include/mc-cflags.m4]) m4_include([m4.include/ax_gcc_func_attribute.m4]) m4_include([m4.include/mc-check-search-type.m4]) diff --git a/configure.ac b/configure.ac index b22371f99..f21b456d9 100644 --- a/configure.ac +++ b/configure.ac @@ -53,7 +53,7 @@ fi AC_ARG_ENABLE([werror], AS_HELP_STRING([--enable-werror], [Handle all compiler warnings as errors])) if test "x$enable_werror" = xyes; then - mc_CHECK_ONE_CFLAG([-Werror]) + AX_APPEND_COMPILE_FLAGS([-Werror], [mc_configured_cflags]) fi dnl Compiler can generate warnings for unrecognized flags added to CFLAGS diff --git a/m4.include/ax_append_compile_flags.m4 b/m4.include/ax_append_compile_flags.m4 new file mode 100644 index 000000000..9c856356c --- /dev/null +++ b/m4.include/ax_append_compile_flags.m4 @@ -0,0 +1,46 @@ +# ============================================================================ +# https://www.gnu.org/software/autoconf-archive/ax_append_compile_flags.html +# ============================================================================ +# +# SYNOPSIS +# +# AX_APPEND_COMPILE_FLAGS([FLAG1 FLAG2 ...], [FLAGS-VARIABLE], [EXTRA-FLAGS], [INPUT]) +# +# DESCRIPTION +# +# For every FLAG1, FLAG2 it is checked whether the compiler works with the +# flag. If it does, the flag is added FLAGS-VARIABLE +# +# If FLAGS-VARIABLE is not specified, the current language's flags (e.g. +# CFLAGS) is used. During the check the flag is always added to the +# current language's flags. +# +# If EXTRA-FLAGS is defined, it is added to the current language's default +# flags (e.g. CFLAGS) when the check is done. The check is thus made with +# the flags: "CFLAGS EXTRA-FLAGS FLAG". This can for example be used to +# force the compiler to issue an error when a bad flag is given. +# +# INPUT gives an alternative input source to AC_COMPILE_IFELSE. +# +# NOTE: This macro depends on the AX_APPEND_FLAG and +# AX_CHECK_COMPILE_FLAG. Please keep this macro in sync with +# AX_APPEND_LINK_FLAGS. +# +# LICENSE +# +# Copyright (c) 2011 Maarten Bosmans +# +# Copying and distribution of this file, with or without modification, are +# permitted in any medium without royalty provided the copyright notice +# and this notice are preserved. This file is offered as-is, without any +# warranty. + +#serial 7 + +AC_DEFUN([AX_APPEND_COMPILE_FLAGS], +[AX_REQUIRE_DEFINED([AX_CHECK_COMPILE_FLAG]) +AX_REQUIRE_DEFINED([AX_APPEND_FLAG]) +for flag in $1; do + AX_CHECK_COMPILE_FLAG([$flag], [AX_APPEND_FLAG([$flag], [$2])], [], [$3], [$4]) +done +])dnl AX_APPEND_COMPILE_FLAGS diff --git a/m4.include/ax_append_flag.m4 b/m4.include/ax_append_flag.m4 new file mode 100644 index 000000000..dd6d8b614 --- /dev/null +++ b/m4.include/ax_append_flag.m4 @@ -0,0 +1,50 @@ +# =========================================================================== +# https://www.gnu.org/software/autoconf-archive/ax_append_flag.html +# =========================================================================== +# +# SYNOPSIS +# +# AX_APPEND_FLAG(FLAG, [FLAGS-VARIABLE]) +# +# DESCRIPTION +# +# FLAG is appended to the FLAGS-VARIABLE shell variable, with a space +# added in between. +# +# If FLAGS-VARIABLE is not specified, the current language's flags (e.g. +# CFLAGS) is used. FLAGS-VARIABLE is not changed if it already contains +# FLAG. If FLAGS-VARIABLE is unset in the shell, it is set to exactly +# FLAG. +# +# NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. +# +# LICENSE +# +# Copyright (c) 2008 Guido U. Draheim +# Copyright (c) 2011 Maarten Bosmans +# +# Copying and distribution of this file, with or without modification, are +# permitted in any medium without royalty provided the copyright notice +# and this notice are preserved. This file is offered as-is, without any +# warranty. + +#serial 8 + +AC_DEFUN([AX_APPEND_FLAG], +[dnl +AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_SET_IF +AS_VAR_PUSHDEF([FLAGS], [m4_default($2,_AC_LANG_PREFIX[FLAGS])]) +AS_VAR_SET_IF(FLAGS,[ + AS_CASE([" AS_VAR_GET(FLAGS) "], + [*" $1 "*], [AC_RUN_LOG([: FLAGS already contains $1])], + [ + AS_VAR_APPEND(FLAGS,[" $1"]) + AC_RUN_LOG([: FLAGS="$FLAGS"]) + ]) + ], + [ + AS_VAR_SET(FLAGS,[$1]) + AC_RUN_LOG([: FLAGS="$FLAGS"]) + ]) +AS_VAR_POPDEF([FLAGS])dnl +])dnl AX_APPEND_FLAG diff --git a/m4.include/ax_check_compile_flag.m4 b/m4.include/ax_check_compile_flag.m4 new file mode 100644 index 000000000..bd753b34d --- /dev/null +++ b/m4.include/ax_check_compile_flag.m4 @@ -0,0 +1,53 @@ +# =========================================================================== +# https://www.gnu.org/software/autoconf-archive/ax_check_compile_flag.html +# =========================================================================== +# +# SYNOPSIS +# +# AX_CHECK_COMPILE_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS], [INPUT]) +# +# DESCRIPTION +# +# Check whether the given FLAG works with the current language's compiler +# or gives an error. (Warnings, however, are ignored) +# +# ACTION-SUCCESS/ACTION-FAILURE are shell commands to execute on +# success/failure. +# +# If EXTRA-FLAGS is defined, it is added to the current language's default +# flags (e.g. CFLAGS) when the check is done. The check is thus made with +# the flags: "CFLAGS EXTRA-FLAGS FLAG". This can for example be used to +# force the compiler to issue an error when a bad flag is given. +# +# INPUT gives an alternative input source to AC_COMPILE_IFELSE. +# +# NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. Please keep this +# macro in sync with AX_CHECK_{PREPROC,LINK}_FLAG. +# +# LICENSE +# +# Copyright (c) 2008 Guido U. Draheim +# Copyright (c) 2011 Maarten Bosmans +# +# Copying and distribution of this file, with or without modification, are +# permitted in any medium without royalty provided the copyright notice +# and this notice are preserved. This file is offered as-is, without any +# warranty. + +#serial 6 + +AC_DEFUN([AX_CHECK_COMPILE_FLAG], +[AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_IF +AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_[]_AC_LANG_ABBREV[]flags_$4_$1])dnl +AC_CACHE_CHECK([whether _AC_LANG compiler accepts $1], CACHEVAR, [ + ax_check_save_flags=$[]_AC_LANG_PREFIX[]FLAGS + _AC_LANG_PREFIX[]FLAGS="$[]_AC_LANG_PREFIX[]FLAGS $4 $1" + AC_COMPILE_IFELSE([m4_default([$5],[AC_LANG_PROGRAM()])], + [AS_VAR_SET(CACHEVAR,[yes])], + [AS_VAR_SET(CACHEVAR,[no])]) + _AC_LANG_PREFIX[]FLAGS=$ax_check_save_flags]) +AS_VAR_IF(CACHEVAR,yes, + [m4_default([$2], :)], + [m4_default([$3], :)]) +AS_VAR_POPDEF([CACHEVAR])dnl +])dnl AX_CHECK_COMPILE_FLAGS diff --git a/m4.include/ax_require_defined.m4 b/m4.include/ax_require_defined.m4 new file mode 100644 index 000000000..17c3eab7d --- /dev/null +++ b/m4.include/ax_require_defined.m4 @@ -0,0 +1,37 @@ +# =========================================================================== +# https://www.gnu.org/software/autoconf-archive/ax_require_defined.html +# =========================================================================== +# +# SYNOPSIS +# +# AX_REQUIRE_DEFINED(MACRO) +# +# DESCRIPTION +# +# AX_REQUIRE_DEFINED is a simple helper for making sure other macros have +# been defined and thus are available for use. This avoids random issues +# where a macro isn't expanded. Instead the configure script emits a +# non-fatal: +# +# ./configure: line 1673: AX_CFLAGS_WARN_ALL: command not found +# +# It's like AC_REQUIRE except it doesn't expand the required macro. +# +# Here's an example: +# +# AX_REQUIRE_DEFINED([AX_CHECK_LINK_FLAG]) +# +# LICENSE +# +# Copyright (c) 2014 Mike Frysinger +# +# Copying and distribution of this file, with or without modification, are +# permitted in any medium without royalty provided the copyright notice +# and this notice are preserved. This file is offered as-is, without any +# warranty. + +#serial 2 + +AC_DEFUN([AX_REQUIRE_DEFINED], [dnl + m4_ifndef([$1], [m4_fatal([macro ]$1[ is not defined; is a m4 file missing?])]) +])dnl AX_REQUIRE_DEFINED diff --git a/m4.include/mc-cflags.m4 b/m4.include/mc-cflags.m4 index 9faac606a..264f5c106 100644 --- a/m4.include/mc-cflags.m4 +++ b/m4.include/mc-cflags.m4 @@ -3,104 +3,88 @@ dnl dnl Check flags supported by C compiler dnl dnl @author Slava Zanko -dnl @version 2013-01-16 +dnl @modified by Andrew Borodin +dnl @version 2021-09-19 dnl @license GPL dnl @copyright Free Software Foundation, Inc. -AC_DEFUN([mc_CHECK_ONE_CFLAG],[ - - AC_MSG_CHECKING([whether ${CC} accepts $1]) - - safe_CFLAGS=$CFLAGS - - case "$CC" in - clang*) - CFLAGS="-Werror $1" - ;; - *) - CFLAGS="$1" - ;; - esac - - AC_COMPILE_IFELSE( - [AC_LANG_PROGRAM([], [[return 0;]])], - [mc_check_one_cflag=yes], - [mc_check_one_cflag=no]) - - CFLAGS=$safe_CFLAGS - AC_MSG_RESULT([$mc_check_one_cflag]) - - if test x$mc_check_one_cflag = xyes; then - mc_configured_cflags="$mc_configured_cflags $1" - fi -]) - AC_DEFUN([mc_CHECK_CFLAGS],[ AC_LANG_PUSH(C) mc_configured_cflags="" -dnl Sorted -f options: -dnl AC_MSG_CHECKING([CC is $CC]) -case "$CC" in - gcc*) - mc_CHECK_ONE_CFLAG([-fdiagnostics-show-option]) -dnl mc_CHECK_ONE_CFLAG([-fno-stack-protector]) - ;; - *) - ;; -esac +dnl AC_MSG_CHECKING([CC is $CC]) -dnl Sorted -W options: - mc_CHECK_ONE_CFLAG([-Wassign-enum]) - mc_CHECK_ONE_CFLAG([-Wbad-function-cast]) - mc_CHECK_ONE_CFLAG([-Wcomment]) - mc_CHECK_ONE_CFLAG([-Wconditional-uninitialized]) - mc_CHECK_ONE_CFLAG([-Wdeclaration-after-statement]) - mc_CHECK_ONE_CFLAG([-Wfloat-conversion]) - mc_CHECK_ONE_CFLAG([-Wfloat-equal]) - mc_CHECK_ONE_CFLAG([-Wformat]) - mc_CHECK_ONE_CFLAG([-Wformat-security]) - mc_CHECK_ONE_CFLAG([-Wformat-signedness]) - mc_CHECK_ONE_CFLAG([-Wimplicit]) - mc_CHECK_ONE_CFLAG([-Wimplicit-fallthrough]) - mc_CHECK_ONE_CFLAG([-Wignored-qualifiers]) - mc_CHECK_ONE_CFLAG([-Wlogical-not-parentheses]) - mc_CHECK_ONE_CFLAG([-Wmaybe-uninitialized]) - mc_CHECK_ONE_CFLAG([-Wmissing-braces]) - mc_CHECK_ONE_CFLAG([-Wmissing-declarations]) - mc_CHECK_ONE_CFLAG([-Wmissing-field-initializers]) - mc_CHECK_ONE_CFLAG([-Wmissing-format-attribute]) - mc_CHECK_ONE_CFLAG([-Wmissing-parameter-type]) - mc_CHECK_ONE_CFLAG([-Wmissing-prototypes]) - mc_CHECK_ONE_CFLAG([-Wmissing-variable-declarations]) - mc_CHECK_ONE_CFLAG([-Wnested-externs]) - mc_CHECK_ONE_CFLAG([-Wno-long-long]) - mc_CHECK_ONE_CFLAG([-Wno-unreachable-code]) - mc_CHECK_ONE_CFLAG([-Wparentheses]) - mc_CHECK_ONE_CFLAG([-Wpointer-arith]) - mc_CHECK_ONE_CFLAG([-Wpointer-sign]) - mc_CHECK_ONE_CFLAG([-Wredundant-decls]) - mc_CHECK_ONE_CFLAG([-Wreturn-type]) - mc_CHECK_ONE_CFLAG([-Wsequence-point]) - mc_CHECK_ONE_CFLAG([-Wshadow]) - mc_CHECK_ONE_CFLAG([-Wsign-compare]) -dnl mc_CHECK_ONE_CFLAG([-Wstrict-aliasing]) - mc_CHECK_ONE_CFLAG([-Wstrict-prototypes]) - mc_CHECK_ONE_CFLAG([-Wswitch]) - mc_CHECK_ONE_CFLAG([-Wswitch-default]) - mc_CHECK_ONE_CFLAG([-Wtype-limits]) - mc_CHECK_ONE_CFLAG([-Wundef]) - mc_CHECK_ONE_CFLAG([-Wuninitialized]) - mc_CHECK_ONE_CFLAG([-Wunreachable-code]) - mc_CHECK_ONE_CFLAG([-Wunused-but-set-variable]) - mc_CHECK_ONE_CFLAG([-Wunused-function]) - mc_CHECK_ONE_CFLAG([-Wunused-label]) - mc_CHECK_ONE_CFLAG([-Wunused-parameter]) - mc_CHECK_ONE_CFLAG([-Wunused-result]) - mc_CHECK_ONE_CFLAG([-Wunused-value]) - mc_CHECK_ONE_CFLAG([-Wunused-variable]) - mc_CHECK_ONE_CFLAG([-Wwrite-strings]) + dnl https://stackoverflow.com/questions/52557417/how-to-check-support-compile-flag-in-autoconf-for-clang + case "$CC" in + clang*) + EXTRA_OPTION="-Werror" + ;; + *) + EXTRA_OPTION="" + ;; + esac + + dnl Sorted -f options: + case "$CC" in + gcc*) + AX_APPEND_COMPILE_FLAGS([-fdiagnostics-show-option], [mc_configured_cflags]) +dnl AX_APPEND_COMPILE_FLAGS([-fno-stack-protector], [mc_configured_cflags]) + ;; + *) + ;; + esac + + dnl Sorted -W options: + AX_APPEND_COMPILE_FLAGS([-Wassign-enum], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wbad-function-cast], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wcomment], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wconditional-uninitialized], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wdeclaration-after-statement], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wfloat-conversion], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wfloat-equal], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wformat], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wformat-security], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wformat-signedness], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wimplicit], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wimplicit-fallthrough], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wignored-qualifiers], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wlogical-not-parentheses], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wmaybe-uninitialized], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wmissing-braces], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wmissing-declarations], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wmissing-field-initializers], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wmissing-format-attribute], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wmissing-parameter-type], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wmissing-prototypes], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wmissing-variable-declarations], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wnested-externs], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wno-long-long], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wno-unreachable-code], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wparentheses], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wpointer-arith], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wpointer-sign], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wredundant-decls], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wreturn-type], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wsequence-point], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wshadow], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wsign-compare], [mc_configured_cflags], [$EXTRA_OPTION]) +dnl AX_APPEND_COMPILE_FLAGS([-Wstrict-aliasing], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wstrict-prototypes], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wswitch], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wswitch-default], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wtype-limits], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wundef], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wuninitialized], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wunreachable-code], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wunused-but-set-variable], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wunused-function], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wunused-label], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wunused-parameter], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wunused-result], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wunused-value], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wunused-variable], [mc_configured_cflags], [$EXTRA_OPTION]) + AX_APPEND_COMPILE_FLAGS([-Wwrite-strings], [mc_configured_cflags], [$EXTRA_OPTION]) AC_LANG_POP() ]) From a4adc095092605f194bef1abf2295e47f5f595ad Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 26 Sep 2021 09:54:16 +0300 Subject: [PATCH 17/33] (file_mask_dialog): indentation. Signed-off-by: Andrew Borodin --- src/filemanager/filegui.c | 13 ++++++------- src/filemanager/filegui.h | 7 +++---- 2 files changed, 9 insertions(+), 11 deletions(-) diff --git a/src/filemanager/filegui.c b/src/filemanager/filegui.c index ea02b9f26..4cd6cbd16 100644 --- a/src/filemanager/filegui.c +++ b/src/filemanager/filegui.c @@ -1270,8 +1270,7 @@ file_progress_real_query_replace (file_op_context_t * ctx, enum OperationMode mo /* --------------------------------------------------------------------------------------------- */ char * -file_mask_dialog (file_op_context_t * ctx, FileOperation operation, - gboolean only_one, +file_mask_dialog (file_op_context_t * ctx, FileOperation operation, gboolean only_one, const char *format, const void *text, const char *def_text, gboolean * do_bg) { size_t fmd_xlen; @@ -1336,16 +1335,16 @@ file_mask_dialog (file_op_context_t * ctx, FileOperation operation, quick_widget_t quick_widgets[] = { /* *INDENT-OFF* */ - QUICK_LABELED_INPUT (fmd_buf, input_label_above, - easy_patterns ? "*" : "^(.*)$", "input-def", &source_mask, - NULL, FALSE, FALSE, INPUT_COMPLETE_FILENAMES), + QUICK_LABELED_INPUT (fmd_buf, input_label_above, easy_patterns ? "*" : "^(.*)$", + "input-def", &source_mask, NULL, FALSE, FALSE, + INPUT_COMPLETE_FILENAMES), QUICK_START_COLUMNS, QUICK_SEPARATOR (FALSE), QUICK_NEXT_COLUMN, QUICK_CHECKBOX (N_("&Using shell patterns"), &source_easy_patterns, NULL), QUICK_STOP_COLUMNS, - QUICK_LABELED_INPUT (N_("to:"), input_label_above, - def_text_secure, "input2", &dest_dir, NULL, FALSE, FALSE, INPUT_COMPLETE_FILENAMES), + QUICK_LABELED_INPUT (N_("to:"), input_label_above, def_text_secure, "input2", &dest_dir, + NULL, FALSE, FALSE, INPUT_COMPLETE_FILENAMES), QUICK_SEPARATOR (TRUE), QUICK_START_COLUMNS, QUICK_CHECKBOX (N_("Follow &links"), &ctx->follow_links, NULL), diff --git a/src/filemanager/filegui.h b/src/filemanager/filegui.h index af541c2f4..3fe6fe7cd 100644 --- a/src/filemanager/filegui.h +++ b/src/filemanager/filegui.h @@ -22,10 +22,9 @@ void file_op_context_create_ui (file_op_context_t * ctx, gboolean with_eta, filegui_dialog_type_t dialog_type); void file_op_context_destroy_ui (file_op_context_t * ctx); -char *file_mask_dialog (file_op_context_t * ctx, FileOperation operation, - gboolean only_one, - const char *format, const void *text, - const char *def_text, gboolean * do_bg); +char *file_mask_dialog (file_op_context_t * ctx, FileOperation operation, gboolean only_one, + const char *format, const void *text, const char *def_text, + gboolean * do_bg); FileProgressStatus check_progress_buttons (file_op_context_t * ctx); From 40675220c1a9d6e2cb5ab8bec651d7fdadba9825 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 2 Oct 2021 13:09:34 +0300 Subject: [PATCH 18/33] lib/tty/key.c: use named constants for time intervals. Signed-off-by: Andrew Borodin --- lib/tty/key.c | 33 ++++++++++++++++++--------------- 1 file changed, 18 insertions(+), 15 deletions(-) diff --git a/lib/tty/key.c b/lib/tty/key.c index 57d0929c1..d78085f89 100644 --- a/lib/tty/key.c +++ b/lib/tty/key.c @@ -89,11 +89,11 @@ /*** global variables ****************************************************************************/ -int mou_auto_repeat = 100; -int double_click_speed = 250; +int mou_auto_repeat = 100; /* ms */ +int double_click_speed = 250; /* ms */ gboolean old_esc_mode = TRUE; /* timeout for old_esc_mode in usec */ -int old_esc_mode_timeout = 1000000; /* settable via env */ +int old_esc_mode_timeout = G_USEC_PER_SEC; /* us, settable via env */ gboolean use_8th_bit_as_meta = FALSE; gboolean bracketed_pasting_in_progress = FALSE; @@ -220,8 +220,11 @@ const key_code_name_t key_name_conv_tab[] = { /*** file scope macro definitions ****************************************************************/ +#define MC_MSEC_PER_SEC 1000 +#define MC_USEC_PER_MSEC 1000 + #define GET_TIME(tv) (gettimeofday(&tv, (struct timezone *) NULL)) -#define DIF_TIME(t1, t2) ((t2.tv_sec - t1.tv_sec) * 1000 + (t2.tv_usec - t1.tv_usec)/1000) +#define DIF_TIME(t1, t2) ((t2.tv_sec - t1.tv_sec) * MC_USEC_PER_MSEC + (t2.tv_usec - t1.tv_usec)/MC_USEC_PER_MSEC) /* The maximum sequence length (32 + null terminator) */ #define SEQ_BUFFER_LEN 33 @@ -640,7 +643,7 @@ try_channels (gboolean set_timeout) if (set_timeout) { time_out.tv_sec = 0; - time_out.tv_usec = 100000; + time_out.tv_usec = 100 * MC_USEC_PER_MSEC; timeptr = &time_out; } @@ -1153,8 +1156,8 @@ getch_with_timeout (unsigned int delay_us) int c; struct timeval time_out; - time_out.tv_sec = delay_us / 1000000u; - time_out.tv_usec = delay_us % 1000000u; + time_out.tv_sec = delay_us / G_USEC_PER_SEC; + time_out.tv_usec = delay_us % G_USEC_PER_SEC; tty_nodelay (TRUE); FD_ZERO (&Read_FD_Set); FD_SET (input_fd, &Read_FD_Set); @@ -1797,11 +1800,11 @@ get_key_code (int no_delay) return -1; GET_TIME (current); - time_out.tv_sec = old_esc_mode_timeout / 1000000 + esctime.tv_sec; - time_out.tv_usec = old_esc_mode_timeout % 1000000 + esctime.tv_usec; - if (time_out.tv_usec > 1000000) + time_out.tv_sec = old_esc_mode_timeout / G_USEC_PER_SEC + esctime.tv_sec; + time_out.tv_usec = old_esc_mode_timeout % G_USEC_PER_SEC + esctime.tv_usec; + if (time_out.tv_usec > G_USEC_PER_SEC) { - time_out.tv_usec -= 1000000; + time_out.tv_usec -= G_USEC_PER_SEC; time_out.tv_sec++; } if (current.tv_sec < time_out.tv_sec || @@ -2000,7 +2003,7 @@ tty_get_event (struct Gpm_Event *event, gboolean redo_event, gboolean block) if (redo_event) { - time_out.tv_usec = mou_auto_repeat * 1000; + time_out.tv_usec = mou_auto_repeat * MC_USEC_PER_MSEC; time_out.tv_sec = 0; time_addr = &time_out; @@ -2166,7 +2169,7 @@ char * learn_key (void) { /* LEARN_TIMEOUT in usec */ -#define LEARN_TIMEOUT 200000 +#define LEARN_TIMEOUT (200 * MC_USEC_PER_MSEC) fd_set Read_FD_Set; struct timeval endtime; @@ -2183,9 +2186,9 @@ learn_key (void) GET_TIME (endtime); endtime.tv_usec += LEARN_TIMEOUT; - if (endtime.tv_usec > 1000000) + if (endtime.tv_usec > G_USEC_PER_SEC) { - endtime.tv_usec -= 1000000; + endtime.tv_usec -= G_USEC_PER_SEC; endtime.tv_sec++; } From 8885987f1df300aa2554157c35c4d31ca060b94f Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 2 Oct 2021 12:47:26 +0300 Subject: [PATCH 19/33] (xmouse_get_event): use g_get_real_time () to simplify time comparision. Signed-off-by: Andrew Borodin --- lib/tty/key.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/lib/tty/key.c b/lib/tty/key.c index d78085f89..06d0bc53d 100644 --- a/lib/tty/key.c +++ b/lib/tty/key.c @@ -223,8 +223,7 @@ const key_code_name_t key_name_conv_tab[] = { #define MC_MSEC_PER_SEC 1000 #define MC_USEC_PER_MSEC 1000 -#define GET_TIME(tv) (gettimeofday(&tv, (struct timezone *) NULL)) -#define DIF_TIME(t1, t2) ((t2.tv_sec - t1.tv_sec) * MC_USEC_PER_MSEC + (t2.tv_usec - t1.tv_usec)/MC_USEC_PER_MSEC) +#define GET_TIME(tv) (gettimeofday(&tv, (struct timezone *) NULL)) /* The maximum sequence length (32 + null terminator) */ #define SEQ_BUFFER_LEN 33 @@ -744,8 +743,7 @@ getch_with_delay (void) static void xmouse_get_event (Gpm_Event * ev, gboolean extended) { - static struct timeval tv1 = { 0, 0 }; /* Force first click as single */ - static struct timeval tv2; + static gint64 tv1 = 0; /* Force first click as single */ static int clicks = 0; static int last_btn = 0; int btn; @@ -814,13 +812,12 @@ xmouse_get_event (Gpm_Event * ev, gboolean extended) /* don't generate GPM_UP after mouse wheel */ /* need for menu event handling */ ev->type = 0; - tv1.tv_sec = 0; - tv1.tv_usec = 0; + tv1 = 0; } else { ev->type = GPM_UP | (GPM_SINGLE << clicks); - GET_TIME (tv1); + tv1 = g_get_real_time (); } ev->buttons = 0; last_btn = 0; @@ -834,6 +831,8 @@ xmouse_get_event (Gpm_Event * ev, gboolean extended) } else { + gint64 tv2; + if (btn >= 32 && btn <= 34) { btn -= 32; @@ -842,8 +841,8 @@ xmouse_get_event (Gpm_Event * ev, gboolean extended) else ev->type = GPM_DOWN; - GET_TIME (tv2); - if (tv1.tv_sec != 0 && DIF_TIME (tv1, tv2) < double_click_speed) + tv2 = g_get_real_time (); + if (tv1 != 0 && tv2 - tv1 < (gint64) double_click_speed * MC_USEC_PER_MSEC) { clicks++; clicks %= 3; From 254a311cc040b88963a8199a87a729a47f4b6688 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 2 Oct 2021 13:26:07 +0300 Subject: [PATCH 20/33] (get_key_code): use g_get_real_time () to simplify time comparision. Signed-off-by: Andrew Borodin --- lib/tty/key.c | 22 ++++------------------ 1 file changed, 4 insertions(+), 18 deletions(-) diff --git a/lib/tty/key.c b/lib/tty/key.c index 06d0bc53d..8e5032f86 100644 --- a/lib/tty/key.c +++ b/lib/tty/key.c @@ -1733,7 +1733,7 @@ get_key_code (int no_delay) { int c; static key_def *this = NULL, *parent; - static struct timeval esctime = { -1, -1 }; + static gint64 esc_time = -1; static int lastnodelay = -1; if (no_delay != lastnodelay) @@ -1792,22 +1792,8 @@ get_key_code (int no_delay) tty_nodelay (FALSE); if (c == -1) { - struct timeval current, time_out; - if (this == NULL || parent == NULL || parent->action != MCKEY_ESCAPE || !old_esc_mode || - esctime.tv_sec == -1) - return -1; - - GET_TIME (current); - time_out.tv_sec = old_esc_mode_timeout / G_USEC_PER_SEC + esctime.tv_sec; - time_out.tv_usec = old_esc_mode_timeout % G_USEC_PER_SEC + esctime.tv_usec; - if (time_out.tv_usec > G_USEC_PER_SEC) - { - time_out.tv_usec -= G_USEC_PER_SEC; - time_out.tv_sec++; - } - if (current.tv_sec < time_out.tv_sec || - (current.tv_sec == time_out.tv_sec && current.tv_usec < time_out.tv_usec)) + esc_time == -1 || g_get_real_time () < esc_time + old_esc_mode_timeout) return -1; this = NULL; @@ -1871,11 +1857,11 @@ get_key_code (int no_delay) { if (no_delay != 0) { - GET_TIME (esctime); + esc_time = g_get_real_time (); goto nodelay_try_again; } - esctime.tv_sec = -1; + esc_time = -1; c = getch_with_timeout (old_esc_mode_timeout); if (c != -1) continue; From 0e09fc3088d2878e5b86b08c4155400b17ffcd67 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 2 Oct 2021 13:54:45 +0300 Subject: [PATCH 21/33] (learn_key): use g_get_real_time () to simplify time comparision. Signed-off-by: Andrew Borodin --- lib/tty/key.c | 40 +++++++++++++++------------------------- 1 file changed, 15 insertions(+), 25 deletions(-) diff --git a/lib/tty/key.c b/lib/tty/key.c index 8e5032f86..8b349d5e1 100644 --- a/lib/tty/key.c +++ b/lib/tty/key.c @@ -223,8 +223,6 @@ const key_code_name_t key_name_conv_tab[] = { #define MC_MSEC_PER_SEC 1000 #define MC_USEC_PER_MSEC 1000 -#define GET_TIME(tv) (gettimeofday(&tv, (struct timezone *) NULL)) - /* The maximum sequence length (32 + null terminator) */ #define SEQ_BUFFER_LEN 33 @@ -2153,12 +2151,11 @@ tty_getch (void) char * learn_key (void) { - /* LEARN_TIMEOUT in usec */ -#define LEARN_TIMEOUT (200 * MC_USEC_PER_MSEC) + /* LEARN_TIMEOUT in ms */ +#define LEARN_TIMEOUT 200 fd_set Read_FD_Set; - struct timeval endtime; - struct timeval time_out; + gint64 end_time; int c; char buffer[256]; char *p = buffer; @@ -2169,32 +2166,25 @@ learn_key (void) c = tty_lowlevel_getch (); /* Sanity check, should be unnecessary */ learn_store_key (buffer, &p, c); - GET_TIME (endtime); - endtime.tv_usec += LEARN_TIMEOUT; - if (endtime.tv_usec > G_USEC_PER_SEC) - { - endtime.tv_usec -= G_USEC_PER_SEC; - endtime.tv_sec++; - } + end_time = g_get_real_time () + LEARN_TIMEOUT * MC_USEC_PER_MSEC; tty_nodelay (TRUE); while (TRUE) { while ((c = tty_lowlevel_getch ()) == -1) { - GET_TIME (time_out); - time_out.tv_usec = endtime.tv_usec - time_out.tv_usec; - if (time_out.tv_usec < 0) - time_out.tv_sec++; - time_out.tv_sec = endtime.tv_sec - time_out.tv_sec; - if (time_out.tv_sec >= 0 && time_out.tv_usec > 0) - { - FD_ZERO (&Read_FD_Set); - FD_SET (input_fd, &Read_FD_Set); - select (input_fd + 1, &Read_FD_Set, NULL, NULL, &time_out); - } - else + gint64 time_out; + struct timeval tv; + + time_out = end_time - g_get_real_time (); + if (time_out <= 0) break; + + tv.tv_sec = time_out / G_USEC_PER_SEC; + tv.tv_usec = time_out % G_USEC_PER_SEC; + FD_ZERO (&Read_FD_Set); + FD_SET (input_fd, &Read_FD_Set); + select (input_fd + 1, &Read_FD_Set, NULL, NULL, &tv); } if (c == -1) break; From 31008bcc8e984e95c36c0597d437e6098ce088d6 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 2 Oct 2021 14:00:32 +0300 Subject: [PATCH 22/33] (learn_key): return NULL if buffer is empty. (learn_button): simplify tests: seq is never empty here. Signed-off-by: Andrew Borodin --- lib/tty/key.c | 2 +- src/learn.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/tty/key.c b/lib/tty/key.c index 8b349d5e1..11a6329c7 100644 --- a/lib/tty/key.c +++ b/lib/tty/key.c @@ -2193,7 +2193,7 @@ learn_key (void) tty_keypad (TRUE); tty_nodelay (FALSE); *p = '\0'; - return g_strdup (buffer); + return (buffer[0] != '\0' ? g_strdup (buffer) : NULL); #undef LEARN_TIMEOUT } diff --git a/src/learn.c b/src/learn.c index 4a9a6d924..c92610e96 100644 --- a/src/learn.c +++ b/src/learn.c @@ -105,7 +105,7 @@ learn_button (WButton * button, int action) */ gboolean seq_ok = FALSE; - if (*seq != '\0' && strcmp (seq, "\\e") != 0 && strcmp (seq, "\\e\\e") != 0 + if (strcmp (seq, "\\e") != 0 && strcmp (seq, "\\e\\e") != 0 && strcmp (seq, "^m") != 0 && strcmp (seq, "^i") != 0 && (seq[1] != '\0' || *seq < ' ' || *seq > '~')) { From 4e8b00f003c168750fe683891c1bdb8029aa0e44 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 3 Oct 2021 17:12:42 +0300 Subject: [PATCH 23/33] Use g_get_monotonic_time() instead of g_get_real_time(). Signed-off-by: Andrew Borodin --- lib/tty/key.c | 12 ++++++------ lib/util.c | 2 +- lib/vfs/direntry.c | 2 +- lib/vfs/gc.c | 6 +++--- lib/widget/wtools.c | 2 +- src/filemanager/file.c | 8 ++++---- src/filemanager/filegui.c | 2 +- src/vfs/fish/fish.c | 2 +- src/vfs/ftpfs/ftpfs.c | 6 +++--- 9 files changed, 21 insertions(+), 21 deletions(-) diff --git a/lib/tty/key.c b/lib/tty/key.c index 11a6329c7..4553180f9 100644 --- a/lib/tty/key.c +++ b/lib/tty/key.c @@ -815,7 +815,7 @@ xmouse_get_event (Gpm_Event * ev, gboolean extended) else { ev->type = GPM_UP | (GPM_SINGLE << clicks); - tv1 = g_get_real_time (); + tv1 = g_get_monotonic_time (); } ev->buttons = 0; last_btn = 0; @@ -839,7 +839,7 @@ xmouse_get_event (Gpm_Event * ev, gboolean extended) else ev->type = GPM_DOWN; - tv2 = g_get_real_time (); + tv2 = g_get_monotonic_time (); if (tv1 != 0 && tv2 - tv1 < (gint64) double_click_speed * MC_USEC_PER_MSEC) { clicks++; @@ -1791,7 +1791,7 @@ get_key_code (int no_delay) if (c == -1) { if (this == NULL || parent == NULL || parent->action != MCKEY_ESCAPE || !old_esc_mode || - esc_time == -1 || g_get_real_time () < esc_time + old_esc_mode_timeout) + esc_time == -1 || g_get_monotonic_time () < esc_time + old_esc_mode_timeout) return -1; this = NULL; @@ -1855,7 +1855,7 @@ get_key_code (int no_delay) { if (no_delay != 0) { - esc_time = g_get_real_time (); + esc_time = g_get_monotonic_time (); goto nodelay_try_again; } @@ -2166,7 +2166,7 @@ learn_key (void) c = tty_lowlevel_getch (); /* Sanity check, should be unnecessary */ learn_store_key (buffer, &p, c); - end_time = g_get_real_time () + LEARN_TIMEOUT * MC_USEC_PER_MSEC; + end_time = g_get_monotonic_time () + LEARN_TIMEOUT * MC_USEC_PER_MSEC; tty_nodelay (TRUE); while (TRUE) @@ -2176,7 +2176,7 @@ learn_key (void) gint64 time_out; struct timeval tv; - time_out = end_time - g_get_real_time (); + time_out = end_time - g_get_monotonic_time (); if (time_out <= 0) break; diff --git a/lib/util.c b/lib/util.c index 8d36ebdf9..5fb1c7fdc 100644 --- a/lib/util.c +++ b/lib/util.c @@ -1521,7 +1521,7 @@ mc_time_elapsed (gint64 * timestamp, gint64 delay) { gint64 now; - now = g_get_real_time (); + now = g_get_monotonic_time (); if (now >= *timestamp && now < *timestamp + delay) return FALSE; diff --git a/lib/vfs/direntry.c b/lib/vfs/direntry.c index 887f354f8..6bd6c3924 100644 --- a/lib/vfs/direntry.c +++ b/lib/vfs/direntry.c @@ -870,7 +870,7 @@ vfs_s_dir_uptodate (struct vfs_class *me, struct vfs_s_inode *ino) return 0; } - tim = g_get_real_time (); + tim = g_get_monotonic_time (); return (tim < ino->timestamp); } diff --git a/lib/vfs/gc.c b/lib/vfs/gc.c index cd3aa10fe..195e8a50d 100644 --- a/lib/vfs/gc.c +++ b/lib/vfs/gc.c @@ -129,7 +129,7 @@ vfs_addstamp (struct vfs_class *v, vfsid id) stamp = g_new (struct vfs_stamping, 1); stamp->v = v; stamp->id = id; - stamp->time = g_get_real_time (); + stamp->time = g_get_monotonic_time (); stamps = g_slist_append (stamps, stamp); } @@ -152,7 +152,7 @@ vfs_stamp (struct vfs_class *v, vfsid id) stamp = g_slist_find_custom (stamps, &what, vfs_stamp_compare); if (stamp != NULL && stamp->data != NULL) { - VFS_STAMPING (stamp->data)->time = g_get_real_time (); + VFS_STAMPING (stamp->data)->time = g_get_monotonic_time (); ret = TRUE; } @@ -247,7 +247,7 @@ vfs_expire (gboolean now) return; locked = TRUE; - curr_time = g_get_real_time (); + curr_time = g_get_monotonic_time (); exp_time = curr_time - vfs_timeout * G_USEC_PER_SEC; if (now) diff --git a/lib/widget/wtools.c b/lib/widget/wtools.c index 9a2d2c888..2ae88608e 100644 --- a/lib/widget/wtools.c +++ b/lib/widget/wtools.c @@ -587,7 +587,7 @@ status_msg_init (status_msg_t * sm, const char *title, double delay, status_msg_ /* repaint screen to remove previous finished dialog */ mc_refresh (); - start = g_get_real_time (); + start = g_get_monotonic_time (); sm->dlg = dlg_create (TRUE, 0, 0, 7, MIN (MAX (40, COLS / 2), COLS), WPOS_CENTER, FALSE, dialog_colors, NULL, NULL, NULL, title); diff --git a/src/filemanager/file.c b/src/filemanager/file.c index 611d39e65..d6b315d42 100644 --- a/src/filemanager/file.c +++ b/src/filemanager/file.c @@ -817,7 +817,7 @@ progress_update_one (file_op_total_context_t * tctx, file_op_context_t * ctx, of tctx->progress_count++; tctx->progress_bytes += (uintmax_t) add; - tv_current = g_get_real_time (); + tv_current = g_get_monotonic_time (); if (tv_start < 0) tv_start = tv_current; @@ -2388,7 +2388,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, } } - tv_transfer_start = g_get_real_time (); + tv_transfer_start = g_get_monotonic_time (); while ((src_desc = mc_open (src_vpath, O_RDONLY | O_LINEAR)) < 0 && !ctx->skip_all) { @@ -2570,7 +2570,7 @@ copy_file_file (file_op_total_context_t * tctx, file_op_context_t * ctx, if (n_read == 0) break; - tv_current = g_get_real_time (); + tv_current = g_get_monotonic_time (); if (n_read > 0) { @@ -3270,7 +3270,7 @@ panel_operate (void *source_panel, FileOperation operation, gboolean force_singl } tctx = file_op_total_context_new (); - tctx->transfer_start = g_get_real_time (); + tctx->transfer_start = g_get_monotonic_time (); #ifdef ENABLE_BACKGROUND /* Did the user select to do a background operation? */ diff --git a/src/filemanager/filegui.c b/src/filemanager/filegui.c index 4cd6cbd16..07108345f 100644 --- a/src/filemanager/filegui.c +++ b/src/filemanager/filegui.c @@ -1060,7 +1060,7 @@ file_progress_show_total (file_op_total_context_t * tctx, file_op_context_t * ct gint64 tv_current; char buffer4[BUF_TINY]; - tv_current = g_get_real_time (); + tv_current = g_get_monotonic_time (); file_frmt_time (buffer2, (tv_current - tctx->transfer_start) / G_USEC_PER_SEC); if (ctx->progress_totals_computed) diff --git a/src/vfs/fish/fish.c b/src/vfs/fish/fish.c index d47792ba2..3aef84d51 100644 --- a/src/vfs/fish/fish.c +++ b/src/vfs/fish/fish.c @@ -765,7 +765,7 @@ fish_dir_load (struct vfs_class *me, struct vfs_s_inode *dir, char *remote_path) vfs_print_message (_("fish: Reading directory %s..."), remote_path); - dir->timestamp = g_get_real_time () + fish_directory_timeout * G_USEC_PER_SEC; + dir->timestamp = g_get_monotonic_time () + fish_directory_timeout * G_USEC_PER_SEC; quoted_path = strutils_shell_escape (remote_path); (void) fish_command_v (me, super, NONE, FISH_SUPER (super)->scr_ls, "FISH_FILENAME=%s;\n", diff --git a/src/vfs/ftpfs/ftpfs.c b/src/vfs/ftpfs/ftpfs.c index 82c2a5957..32a77f6b2 100644 --- a/src/vfs/ftpfs/ftpfs.c +++ b/src/vfs/ftpfs/ftpfs.c @@ -1493,14 +1493,14 @@ ftpfs_linear_abort (struct vfs_class *me, vfs_file_handler_t * fh) gint64 start_tim; char buf[BUF_8K]; - start_tim = g_get_real_time (); + start_tim = g_get_monotonic_time (); /* flush the remaining data */ while (read (dsock, buf, sizeof (buf)) > 0) { gint64 tim; - tim = g_get_real_time (); + tim = g_get_monotonic_time (); if (tim > start_tim + ABORT_TIMEOUT) { @@ -1752,7 +1752,7 @@ ftpfs_dir_load (struct vfs_class *me, struct vfs_s_inode *dir, char *remote_path return (-1); } - dir->timestamp = g_get_real_time () + ftpfs_directory_timeout * G_USEC_PER_SEC; + dir->timestamp = g_get_monotonic_time () + ftpfs_directory_timeout * G_USEC_PER_SEC; if (ftp_super->strict == RFC_STRICT) sock = ftpfs_open_data_connection (me, super, "LIST", 0, TYPE_ASCII, 0); From ccbac47385c3ac17a2fee1ff031b79ac9e36d541 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 3 Oct 2021 17:14:15 +0300 Subject: [PATCH 24/33] Remove get_process_stats() test. The GLib API is used for measurement of time intervals. Signed-off-by: Andrew Borodin --- configure.ac | 7 ------- lib/utilunix.c | 12 ------------ 2 files changed, 19 deletions(-) diff --git a/configure.ac b/configure.ac index f21b456d9..4f0fb9723 100644 --- a/configure.ac +++ b/configure.ac @@ -311,13 +311,6 @@ if test x$with_mmap != xno; then fi fi -dnl Sequent wants getprocessstats -AC_CHECK_LIB(seq, get_process_stats, [ - LIBS="$LIBS -lseq" - AC_DEFINE(HAVE_GET_PROCESS_STATS, 1, - [Define if you have function `get_process_stats' and -have to use that instead of gettimeofday])]) - mc_GET_FS_INFO diff --git a/lib/utilunix.c b/lib/utilunix.c index acd7cb07a..f8d4dc366 100644 --- a/lib/utilunix.c +++ b/lib/utilunix.c @@ -991,18 +991,6 @@ canonicalize_pathname (char *path) /* --------------------------------------------------------------------------------------------- */ -#ifdef HAVE_GET_PROCESS_STATS -int -gettimeofday (struct timeval *tp, void *tzp) -{ - (void) tzp; - - return get_process_stats (tp, PS_SELF, 0, 0); -} -#endif /* HAVE_GET_PROCESS_STATS */ - -/* --------------------------------------------------------------------------------------------- */ - char * mc_realpath (const char *path, char *resolved_path) { From e71972003e1f9f8a09335e8a7f954352677f741e Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 10 Oct 2021 13:24:07 +0300 Subject: [PATCH 25/33] lib/strutil/strutilutf8.c: use MB_LEN_MAX constant. Signed-off-by: Andrew Borodin --- lib/strutil/strutilutf8.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/lib/strutil/strutilutf8.c b/lib/strutil/strutilutf8.c index 0c187bb92..f4f1841d2 100644 --- a/lib/strutil/strutilutf8.c +++ b/lib/strutil/strutilutf8.c @@ -27,6 +27,7 @@ #include #include +#include /* MB_LEN_MAX */ #include #include "lib/global.h" @@ -51,7 +52,7 @@ struct utf8_tool struct term_form { - char text[BUF_MEDIUM * 6]; + char text[BUF_MEDIUM * MB_LEN_MAX]; size_t width; gboolean compose; }; @@ -512,7 +513,7 @@ str_utf8_make_make_term_form (const char *text, size_t length) static const char * str_utf8_term_form (const char *text) { - static char result[BUF_MEDIUM * 6]; + static char result[BUF_MEDIUM * MB_LEN_MAX]; const struct term_form *pre_form; pre_form = str_utf8_make_make_term_form (text, (size_t) (-1)); @@ -677,7 +678,7 @@ utf8_tool_compose (char *buffer, size_t size) static const char * str_utf8_fit_to_term (const char *text, int width, align_crt_t just_mode) { - static char result[BUF_MEDIUM * 6]; + static char result[BUF_MEDIUM * MB_LEN_MAX]; const struct term_form *pre_form; struct utf8_tool tool; @@ -750,7 +751,7 @@ str_utf8_fit_to_term (const char *text, int width, align_crt_t just_mode) static const char * str_utf8_term_trim (const char *text, int width) { - static char result[BUF_MEDIUM * 6]; + static char result[BUF_MEDIUM * MB_LEN_MAX]; const struct term_form *pre_form; struct utf8_tool tool; @@ -827,7 +828,7 @@ str_utf8_term_char_width (const char *text) static const char * str_utf8_term_substring (const char *text, int start, int width) { - static char result[BUF_MEDIUM * 6]; + static char result[BUF_MEDIUM * MB_LEN_MAX]; const struct term_form *pre_form; struct utf8_tool tool; @@ -858,7 +859,7 @@ str_utf8_term_substring (const char *text, int start, int width) static const char * str_utf8_trunc (const char *text, int width) { - static char result[MC_MAXPATHLEN * 6 * 2]; + static char result[MC_MAXPATHLEN * MB_LEN_MAX * 2]; const struct term_form *pre_form; struct utf8_tool tool; @@ -920,7 +921,7 @@ str_utf8_column_to_pos (const char *text, size_t pos) { gunichar uni; - uni = g_utf8_get_char_validated (text, 6); + uni = g_utf8_get_char_validated (text, MB_LEN_MAX); if ((uni != (gunichar) (-1)) && (uni != (gunichar) (-2))) { if (g_unichar_isprint (uni)) From 8010b08584faae97f81709064609ef78d18daa2d Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 10 Oct 2021 17:33:50 +0300 Subject: [PATCH 26/33] (complete_engine, insert_text): don't calculate text length twice. Signed-off-by: Andrew Borodin --- lib/widget/input_complete.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/lib/widget/input_complete.c b/lib/widget/input_complete.c index 1e9c04948..ba1f2e818 100644 --- a/lib/widget/input_complete.c +++ b/lib/widget/input_complete.c @@ -983,7 +983,11 @@ insert_text (WInput * in, char *text, ssize_t size) text_len = strlen (text); buff_len = str_length (in->buffer); - size = MIN (size, (ssize_t) text_len) + start - end; + if (size < 0) + size = (ssize_t) text_len; + else + size = MIN (size, (ssize_t) text_len); + size += start - end; if (strlen (in->buffer) + size >= (size_t) in->current_max_size) { /* Expand the buffer */ @@ -1210,7 +1214,7 @@ complete_engine (WInput * in, int what_to_do) { char *lc_complete = in->completions[0]; - if (!insert_text (in, lc_complete, strlen (lc_complete)) || in->completions[1] != NULL) + if (!insert_text (in, lc_complete, -1) || in->completions[1] != NULL) tty_beep (); else input_complete_free (in); @@ -1278,7 +1282,7 @@ complete_engine (WInput * in, int what_to_do) { listbox_get_current (complete_list, &q, NULL); if (q != NULL) - insert_text (in, q, strlen (q)); + insert_text (in, q, -1); } if (q != NULL || end != min_end) input_complete_free (in); From a147082c7335e2ce866942642291670f613ef51a Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Thu, 21 Oct 2021 21:46:19 +0300 Subject: [PATCH 27/33] (string_file_name): use mc_g_string_copy. Signed-off-by: Andrew Borodin --- src/filemanager/panel.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/filemanager/panel.c b/src/filemanager/panel.c index cae64bfed..b91f303bb 100644 --- a/src/filemanager/panel.c +++ b/src/filemanager/panel.c @@ -455,8 +455,7 @@ string_file_name (file_entry_t * fe, int len) { (void) len; - g_string_set_size (string_file_name_buffer, 0); - g_string_append_len (string_file_name_buffer, fe->fname->str, fe->fname->len); + mc_g_string_copy (string_file_name_buffer, fe->fname); return string_file_name_buffer->str; } From 19591c4475fe466a994725b77ef37228f3aa37ea Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 7 Nov 2021 12:47:54 +0300 Subject: [PATCH 28/33] mceditor: use MB_LEN_MAX constant. Signed-off-by: Andrew Borodin --- src/editor/editwidget.c | 4 ++-- src/editor/editwidget.h | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/editor/editwidget.c b/src/editor/editwidget.c index c8c372b7b..6d34b54d7 100644 --- a/src/editor/editwidget.c +++ b/src/editor/editwidget.c @@ -516,12 +516,12 @@ edit_translate_key (WEdit * edit, long x_key, int *cmd, int *ch) #else int c; - if (edit->charpoint >= 4) + if (edit->charpoint >= MB_LEN_MAX) { edit->charpoint = 0; edit->charbuf[edit->charpoint] = '\0'; } - if (edit->charpoint < 4) + if (edit->charpoint < MB_LEN_MAX) { edit->charbuf[edit->charpoint++] = x_key; edit->charbuf[edit->charpoint] = '\0'; diff --git a/src/editor/editwidget.h b/src/editor/editwidget.h index 446ef07ac..da0fb508f 100644 --- a/src/editor/editwidget.h +++ b/src/editor/editwidget.h @@ -5,6 +5,8 @@ #ifndef MC__EDIT_WIDGET_H #define MC__EDIT_WIDGET_H +#include /* MB_LEN_MAX */ + #include "lib/search.h" /* mc_search_t */ #include "lib/widget.h" /* Widget */ @@ -80,7 +82,7 @@ struct WEdit /* multibyte support */ gboolean utf8; /* It's multibyte file codeset */ GIConv converter; - char charbuf[4 + 1]; + char charbuf[MB_LEN_MAX + 1]; int charpoint; #endif From 529c7d70ddaaf4d82e82aea11170e837d1c0aded Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 7 Nov 2021 12:54:17 +0300 Subject: [PATCH 29/33] src/editor/editwidget.c: grammar. Signed-off-by: Andrew Borodin --- src/editor/editwidget.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/editor/editwidget.c b/src/editor/editwidget.c index 6d34b54d7..95d673710 100644 --- a/src/editor/editwidget.c +++ b/src/editor/editwidget.c @@ -494,7 +494,7 @@ edit_dialog_command_execute (WDialog * h, long command) /* --------------------------------------------------------------------------------------------- */ /* * Translate the keycode into either 'command' or 'char_for_insertion'. - * 'command' is one of the editor commands from cmddef.h. + * 'command' is one of the editor commands from lib/keybind.h. */ static gboolean @@ -530,7 +530,7 @@ edit_translate_key (WEdit * edit, long x_key, int *cmd, int *ch) /* input from 8-bit locale */ if (!mc_global.utf8_display) { - /* source in 8-bit codeset */ + /* source is in 8-bit codeset */ c = convert_from_input_c (x_key); if (is_printable (c)) @@ -556,7 +556,7 @@ edit_translate_key (WEdit * edit, long x_key, int *cmd, int *ch) if (edit->utf8) { - /* source in UTF-8 codeset */ + /* source is in UTF-8 codeset */ if (res < 0) { char_for_insertion = x_key; @@ -576,7 +576,7 @@ edit_translate_key (WEdit * edit, long x_key, int *cmd, int *ch) /* 8-bit source */ if (res < 0) { - /* not finised multibyte input (in meddle multibyte utf-8 char) */ + /* not finished multibyte input (we're in the middle of multibyte utf-8 char) */ goto fin; } @@ -589,7 +589,7 @@ edit_translate_key (WEdit * edit, long x_key, int *cmd, int *ch) goto fin; } - /* unprinteble utf input, skip it */ + /* non-printable utf-8 input, skip it */ edit->charbuf[0] = '\0'; edit->charpoint = 0; } From 9149a6d13284e4428e7eab301f0f85c95e14cf80 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 23 Oct 2021 20:40:17 +0300 Subject: [PATCH 30/33] (delete_region, copy_region): rename arguments. Signed-off-by: Andrew Borodin --- lib/widget/input.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/widget/input.c b/lib/widget/input.c index 2fd4fa587..cda2c5c09 100644 --- a/lib/widget/input.c +++ b/lib/widget/input.c @@ -149,10 +149,10 @@ input_eval_marks (WInput * in, long *start_mark, long *end_mark) /* --------------------------------------------------------------------------------------------- */ static void -delete_region (WInput * in, int x_first, int x_last) +delete_region (WInput * in, int start, int end) { - int first = MIN (x_first, x_last); - int last = MAX (x_first, x_last); + int first = MIN (start, end); + int last = MAX (start, end); input_mark_cmd (in, FALSE); in->point = first; @@ -487,10 +487,10 @@ delete_char (WInput * in) /* --------------------------------------------------------------------------------------------- */ static void -copy_region (WInput * in, int x_first, int x_last) +copy_region (WInput * in, int start, int end) { - int first = MIN (x_first, x_last); - int last = MAX (x_first, x_last); + int first = MIN (start, end); + int last = MAX (start, end); if (last == first) { From b6c8f319e9834481ec63fedd848faf1e68e4c7a1 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 13 Nov 2021 19:17:12 +0300 Subject: [PATCH 31/33] mc.lib: [terminal:linux] is same as [terminal:console]. Signed-off-by: Andrew Borodin --- misc/mc.lib | 28 +--------------------------- 1 file changed, 1 insertion(+), 27 deletions(-) diff --git a/misc/mc.lib b/misc/mc.lib index 04ce1025f..031243422 100644 --- a/misc/mc.lib +++ b/misc/mc.lib @@ -42,33 +42,7 @@ kpslash=\\eOQ kpnumlock=\\eOP [terminal:linux] -insert=\\e[2~ -f11=\\e[23~ -f12=\\e[24~ -f13=\\e[25~ -f14=\\e[26~ -f15=\\e[28~ -f16=\\e[29~ -f17=\\e[31~ -f18=\\e[32~ -f19=\\e[33~ -f20=\\e[34~ -kpleft=\\eOt -kpright=\\eOv -kpup=\\eOx -kpdown=\\eOr -kphome=\\eOw -kpend=\\eOq -kpnpage=\\eOs -kpppage=\\eOy -kpplus=\\eOl -kpminus=\\eOS -kpasterisk=\\eOR -kpinsert=\\eOp -kpdelete=\\eOn -kpenter=\\eOM -kpslash=\\eOQ -kpnumlock=\\eOP +copy=console [terminal:xterm] insert=\\e[2~ From a73886ef9046211cc6fade2e5728ce1323697740 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sat, 13 Nov 2021 19:24:59 +0300 Subject: [PATCH 32/33] mc.lib: move xterm alt-shift-arrow definitions to lib/tty/key.c. Signed-off-by: Andrew Borodin --- lib/tty/key.c | 5 +++++ misc/mc.lib | 6 ------ 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/lib/tty/key.c b/lib/tty/key.c index 4553180f9..7651da999 100644 --- a/lib/tty/key.c +++ b/lib/tty/key.c @@ -382,6 +382,11 @@ static key_define_t xterm_key_defines[] = { {KEY_M_CTRL | KEY_M_ALT | KEY_HOME, ESC_STR "OH", MCKEY_NOACTION}, {KEY_M_CTRL | KEY_M_ALT | KEY_END, ESC_STR "OF", MCKEY_NOACTION}, + {KEY_M_SHIFT | KEY_M_ALT | KEY_UP, ESC_STR "[1;4A", MCKEY_NOACTION}, + {KEY_M_SHIFT | KEY_M_ALT | KEY_DOWN, ESC_STR "[1;4B", MCKEY_NOACTION}, + {KEY_M_SHIFT | KEY_M_ALT | KEY_RIGHT, ESC_STR "[1;4C", MCKEY_NOACTION}, + {KEY_M_SHIFT | KEY_M_ALT | KEY_LEFT, ESC_STR "[1;4D", MCKEY_NOACTION}, + /* rxvt keys with modifiers */ {KEY_M_SHIFT | KEY_UP, ESC_STR "[a", MCKEY_NOACTION}, {KEY_M_SHIFT | KEY_DOWN, ESC_STR "[b", MCKEY_NOACTION}, diff --git a/misc/mc.lib b/misc/mc.lib index 031243422..90c37c110 100644 --- a/misc/mc.lib +++ b/misc/mc.lib @@ -84,12 +84,6 @@ right=\\eOC left=\\e[D left=\\eOD -# arrows with modifiers -alt-shift-right=\\e[1\;4C -alt-shift-left=\\e[1\;4D -alt-shift-up=\\e[1\;4A -alt-shift-down=\\e[1\;4B - [terminal:alacritty] copy=xterm From 9707afc084d64c90aefb0ae1c02ce52727419f6e Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Sun, 21 Nov 2021 15:19:19 +0300 Subject: [PATCH 33/33] Upate po/*.po files. Signed-off-by: Andrew Borodin --- po/az.po | 10 +- po/be.po | 8 +- po/bg.po | 8 +- po/ca.po | 8 +- po/cs.po | 8 +- po/da.po | 8 +- po/de.po | 8 +- po/de_CH.po | 6 +- po/el.po | 8 +- po/en_GB.po | 6 +- po/eo.po | 8 +- po/es.po | 8 +- po/et.po | 8 +- po/eu.po | 8 +- po/fa.po | 9 +- po/fi.po | 8 +- po/fr.po | 8 +- po/fr_CA.po | 6 +- po/gl.po | 8 +- po/hr.po | 6 +- po/hu.po | 8 +- po/ia.po | 9 +- po/id.po | 6 +- po/it.po | 11 +- po/ja.po | 10 +- po/ka.po | 7 +- po/kk.po | 6 +- po/ko.po | 8 +- po/lt.po | 10 +- po/lv.po | 10 +- po/mc.pot | 380 ++++++++++++++++++++++++++-------------------------- po/mn.po | 10 +- po/nb.po | 8 +- po/nl.po | 8 +- po/pl.po | 8 +- po/pt.po | 8 +- po/pt_BR.po | 10 +- po/ro.po | 8 +- po/ru.po | 8 +- po/sk.po | 8 +- po/sl.po | 10 +- po/sr.po | 8 +- po/sv.po | 8 +- po/szl.po | 6 +- po/ta.po | 6 +- po/te.po | 6 +- po/tr.po | 8 +- po/uk.po | 8 +- po/vi.po | 10 +- po/wa.po | 10 +- po/zh_CN.po | 8 +- po/zh_TW.po | 8 +- 52 files changed, 437 insertions(+), 355 deletions(-) diff --git a/po/az.po b/po/az.po index dd7ed3d3a..03a0f20b7 100644 --- a/po/az.po +++ b/po/az.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Azerbaijani (http://www.transifex.com/mc/mc/language/az/)\n" @@ -2864,7 +2864,8 @@ msgstr "&Ağac" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Sıralama əmri..." msgid "&Filter..." @@ -2879,8 +2880,9 @@ msgstr "FT&P bağı ..." msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." -msgstr "" +#, fuzzy +msgid "&SFTP link..." +msgstr "FT&P bağı ..." msgid "Paneli&ze" msgstr "" diff --git a/po/be.po b/po/be.po index e3787c6e7..3bb003750 100644 --- a/po/be.po +++ b/po/be.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Belarusian (http://www.transifex.com/mc/mc/language/be/)\n" @@ -3056,7 +3056,8 @@ msgstr "Дрэва(&T)" msgid "&Listing format..." msgstr "Фармат спіса(&L)..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "Упарадкаваць(&S)..." msgid "&Filter..." @@ -3071,7 +3072,8 @@ msgstr "Злучэнне праз FTP(&F)..." msgid "S&hell link..." msgstr "Злучэнне праз абалонку(&H)..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "Злучэнне праз SFTP(&F)..." msgid "Paneli&ze" diff --git a/po/bg.po b/po/bg.po index 1ae0f7007..ee2a75228 100644 --- a/po/bg.po +++ b/po/bg.po @@ -11,7 +11,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Bulgarian (http://www.transifex.com/mc/mc/language/bg/)\n" @@ -3032,7 +3032,8 @@ msgstr "Дърво" msgid "&Listing format..." msgstr "&Формат на списък" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "Ред на сортиране..." msgid "&Filter..." @@ -3047,7 +3048,8 @@ msgstr "FTP връзка..." msgid "S&hell link..." msgstr "S&hell връзка..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "S&FTP връзка..." msgid "Paneli&ze" diff --git a/po/ca.po b/po/ca.po index babb9c1a9..cdbfa7534 100644 --- a/po/ca.po +++ b/po/ca.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Catalan (http://www.transifex.com/mc/mc/language/ca/)\n" @@ -3074,7 +3074,8 @@ msgstr "Ar&bre" msgid "&Listing format..." msgstr "Format del &llistat..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Ordenació..." msgid "&Filter..." @@ -3089,7 +3090,8 @@ msgstr "Enllaç per a F&TP..." msgid "S&hell link..." msgstr "Enllaç per a l'i&ntèrpret..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "Enllaç per a &SFTP..." msgid "Paneli&ze" diff --git a/po/cs.po b/po/cs.po index 69fd83c1b..0f8cc594e 100644 --- a/po/cs.po +++ b/po/cs.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Czech (http://www.transifex.com/mc/mc/language/cs/)\n" @@ -3066,7 +3066,8 @@ msgstr "S&trom" msgid "&Listing format..." msgstr "&Formát výpisu…" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Pořadí…" msgid "&Filter..." @@ -3081,7 +3082,8 @@ msgstr "FT&P spojení…" msgid "S&hell link..." msgstr "S&hell spojení…" -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "SFTP sp&ojení…" msgid "Paneli&ze" diff --git a/po/da.po b/po/da.po index caaabc7ef..e39a94fcc 100644 --- a/po/da.po +++ b/po/da.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Danish (http://www.transifex.com/mc/mc/language/da/)\n" @@ -3060,7 +3060,8 @@ msgstr "&Træ" msgid "&Listing format..." msgstr "&Listeformat..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Sorteringsrækkefølge..." msgid "&Filter..." @@ -3075,7 +3076,8 @@ msgstr "FT&P-henvisning..." msgid "S&hell link..." msgstr "S&kalhenvisning..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "S&FTP-link..." msgid "Paneli&ze" diff --git a/po/de.po b/po/de.po index 8ea1b4e11..572f651c1 100644 --- a/po/de.po +++ b/po/de.po @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: German (http://www.transifex.com/mc/mc/language/de/)\n" @@ -3077,7 +3077,8 @@ msgstr "&Baum" msgid "&Listing format..." msgstr "&Listenformat..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Sortierreihenfolge..." msgid "&Filter..." @@ -3092,7 +3093,8 @@ msgstr "FT&P-Verbindung..." msgid "S&hell link..." msgstr "S&hell-Verbindung..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "S&FTP-Verbindung..." msgid "Paneli&ze" diff --git a/po/de_CH.po b/po/de_CH.po index 20f8eac4a..dd69dc736 100644 --- a/po/de_CH.po +++ b/po/de_CH.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2015-02-26 09:48+0000\n" "Last-Translator: Piotr Drąg \n" "Language-Team: German (Switzerland) (http://www.transifex.com/projects/p/mc/" @@ -2862,7 +2862,7 @@ msgstr "" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +msgid "S&ort order..." msgstr "" msgid "&Filter..." @@ -2877,7 +2877,7 @@ msgstr "" msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." +msgid "&SFTP link..." msgstr "" msgid "Paneli&ze" diff --git a/po/el.po b/po/el.po index a8eee07cc..76ac0e0c6 100644 --- a/po/el.po +++ b/po/el.po @@ -12,7 +12,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Greek (http://www.transifex.com/mc/mc/language/el/)\n" @@ -2948,7 +2948,8 @@ msgstr "&Δέντρο" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Σειρά ταξινόμησης..." msgid "&Filter..." @@ -2963,7 +2964,8 @@ msgstr "Δεσμος FT&P..." msgid "S&hell link..." msgstr "Δεσμος κε&λύφους..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "Δεσμός S&FTP..." msgid "Paneli&ze" diff --git a/po/en_GB.po b/po/en_GB.po index 680dde2ec..9d45ba71a 100644 --- a/po/en_GB.po +++ b/po/en_GB.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: English (United Kingdom) (http://www.transifex.com/mc/mc/" @@ -2880,7 +2880,7 @@ msgstr "" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +msgid "S&ort order..." msgstr "" msgid "&Filter..." @@ -2895,7 +2895,7 @@ msgstr "" msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." +msgid "&SFTP link..." msgstr "" msgid "Paneli&ze" diff --git a/po/eo.po b/po/eo.po index eb822205e..a0c9a6a33 100644 --- a/po/eo.po +++ b/po/eo.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Esperanto (http://www.transifex.com/mc/mc/language/eo/)\n" @@ -3058,7 +3058,8 @@ msgstr "&Arbo" msgid "&Listing format..." msgstr "&Listo-aranĝo..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Ordigi laŭ..." msgid "&Filter..." @@ -3073,7 +3074,8 @@ msgstr "FT&P-ligilo..." msgid "S&hell link..." msgstr "Ŝ&ela ligilo..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "&SFTP-ligilo..." msgid "Paneli&ze" diff --git a/po/es.po b/po/es.po index 00b97bddd..7467f9004 100644 --- a/po/es.po +++ b/po/es.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-08-03 17:59+0000\n" "Last-Translator: David Martin \n" "Language-Team: Spanish (http://www.transifex.com/mc/mc/language/es/)\n" @@ -3066,7 +3066,8 @@ msgstr "ár&Bol" msgid "&Listing format..." msgstr "for&Mato de listado..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Ordenar..." msgid "&Filter..." @@ -3081,7 +3082,8 @@ msgstr "conexión por FT&P..." msgid "S&hell link..." msgstr "conexión por SS&H..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "conexión por SF&TP..." msgid "Paneli&ze" diff --git a/po/et.po b/po/et.po index 1deac5464..e4b51a3d2 100644 --- a/po/et.po +++ b/po/et.po @@ -11,7 +11,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-08-08 12:32+0000\n" "Last-Translator: Priit Jõerüüt \n" "Language-Team: Estonian (http://www.transifex.com/mc/mc/language/et/)\n" @@ -3047,7 +3047,8 @@ msgstr "&Puu" msgid "&Listing format..." msgstr "&Loendi vormindus" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Sortimine..." msgid "&Filter..." @@ -3062,7 +3063,8 @@ msgstr "F&TP ühendus..." msgid "S&hell link..." msgstr "K&esta ühendus..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "S&FTP ühendus..." msgid "Paneli&ze" diff --git a/po/eu.po b/po/eu.po index e40939b51..18bc0f3f6 100644 --- a/po/eu.po +++ b/po/eu.po @@ -9,7 +9,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Basque (http://www.transifex.com/mc/mc/language/eu/)\n" @@ -3053,7 +3053,8 @@ msgstr "Zu&haitza" msgid "&Listing format..." msgstr "&Zerrenda formatua" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Sailkatzeko ordena..." msgid "&Filter..." @@ -3068,7 +3069,8 @@ msgstr "FT&P esteka..." msgid "S&hell link..." msgstr "S&hell esteka..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "S&FTP esteka..." msgid "Paneli&ze" diff --git a/po/fa.po b/po/fa.po index e289029e4..ceba4b551 100644 --- a/po/fa.po +++ b/po/fa.po @@ -12,7 +12,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Persian (http://www.transifex.com/mc/mc/language/fa/)\n" @@ -2866,8 +2866,9 @@ msgstr "" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." -msgstr "" +#, fuzzy +msgid "S&ort order..." +msgstr "ترتیب مرتب‌سازی" msgid "&Filter..." msgstr "" @@ -2881,7 +2882,7 @@ msgstr "" msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." +msgid "&SFTP link..." msgstr "" msgid "Paneli&ze" diff --git a/po/fi.po b/po/fi.po index 52da46930..be445008c 100644 --- a/po/fi.po +++ b/po/fi.po @@ -11,7 +11,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Finnish (http://www.transifex.com/mc/mc/language/fi/)\n" @@ -2968,7 +2968,8 @@ msgstr "&Puu" msgid "&Listing format..." msgstr "&Luettelomuoto..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Järjestys" msgid "&Filter..." @@ -2983,7 +2984,8 @@ msgstr "FT&P linkki..." msgid "S&hell link..." msgstr "S&hell linkki..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "S&FTP linkki..." msgid "Paneli&ze" diff --git a/po/fr.po b/po/fr.po index bcd0e8433..2a7636f3f 100644 --- a/po/fr.po +++ b/po/fr.po @@ -17,7 +17,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: French (http://www.transifex.com/mc/mc/language/fr/)\n" @@ -3055,7 +3055,8 @@ msgstr "&Arborescence" msgid "&Listing format..." msgstr "Format de &Listing ..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Ordre de tri..." msgid "&Filter..." @@ -3070,7 +3071,8 @@ msgstr "Lien &FTP..." msgid "S&hell link..." msgstr "Lien S&hell..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "Lien &SFTP..." msgid "Paneli&ze" diff --git a/po/fr_CA.po b/po/fr_CA.po index d62074c61..bc72691c6 100644 --- a/po/fr_CA.po +++ b/po/fr_CA.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2015-02-26 09:48+0000\n" "Last-Translator: Piotr Drąg \n" "Language-Team: French (Canada) (http://www.transifex.com/projects/p/mc/" @@ -2862,7 +2862,7 @@ msgstr "" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +msgid "S&ort order..." msgstr "" msgid "&Filter..." @@ -2877,7 +2877,7 @@ msgstr "" msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." +msgid "&SFTP link..." msgstr "" msgid "Paneli&ze" diff --git a/po/gl.po b/po/gl.po index 1ec0cd57a..581549991 100644 --- a/po/gl.po +++ b/po/gl.po @@ -12,7 +12,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Galician (http://www.transifex.com/mc/mc/language/gl/)\n" @@ -3057,7 +3057,8 @@ msgstr "Ár&Bore" msgid "&Listing format..." msgstr "Formato de &ista..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Ordenar..." msgid "&Filter..." @@ -3072,7 +3073,8 @@ msgstr "Conexión por FT&P..." msgid "S&hell link..." msgstr "Conexión por &Terminal..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "Ligazón S&FTP..." msgid "Paneli&ze" diff --git a/po/hr.po b/po/hr.po index 9b237b331..7d3fa992b 100644 --- a/po/hr.po +++ b/po/hr.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Croatian (http://www.transifex.com/mc/mc/language/hr/)\n" @@ -2862,7 +2862,7 @@ msgstr "" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +msgid "S&ort order..." msgstr "" msgid "&Filter..." @@ -2877,7 +2877,7 @@ msgstr "" msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." +msgid "&SFTP link..." msgstr "" msgid "Paneli&ze" diff --git a/po/hu.po b/po/hu.po index f0e24ddea..13fa77d00 100644 --- a/po/hu.po +++ b/po/hu.po @@ -12,7 +12,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Hungarian (http://www.transifex.com/mc/mc/language/hu/)\n" @@ -3031,7 +3031,8 @@ msgstr "Köny&vtárfa" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Rendezési mód..." msgid "&Filter..." @@ -3046,7 +3047,8 @@ msgstr "&FTP-kapcsolat..." msgid "S&hell link..." msgstr "Sh&ell-kapcsolat..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "S&FTP link..." msgid "Paneli&ze" diff --git a/po/ia.po b/po/ia.po index 7ea1bee0f..21ff06f71 100644 --- a/po/ia.po +++ b/po/ia.po @@ -10,7 +10,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Interlingua (http://www.transifex.com/mc/mc/language/ia/)\n" @@ -2882,7 +2882,7 @@ msgstr "&Arbore" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +msgid "S&ort order..." msgstr "" msgid "&Filter..." @@ -2897,8 +2897,9 @@ msgstr "Ligamine FT&P..." msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." -msgstr "" +#, fuzzy +msgid "&SFTP link..." +msgstr "Ligamine FT&P..." msgid "Paneli&ze" msgstr "" diff --git a/po/id.po b/po/id.po index f367aa396..5bf44c724 100644 --- a/po/id.po +++ b/po/id.po @@ -10,7 +10,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Indonesian (http://www.transifex.com/mc/mc/language/id/)\n" @@ -2899,7 +2899,7 @@ msgstr "" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +msgid "S&ort order..." msgstr "" msgid "&Filter..." @@ -2914,7 +2914,7 @@ msgstr "" msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." +msgid "&SFTP link..." msgstr "" msgid "Paneli&ze" diff --git a/po/it.po b/po/it.po index 9acaaa709..8e41a4c35 100644 --- a/po/it.po +++ b/po/it.po @@ -11,7 +11,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-09-29 09:45+0200\n" "Last-Translator: Marco Ciampa \n" "Language-Team: Italian (http://www.transifex.com/projects/p/mc/language/" @@ -3060,7 +3060,8 @@ msgstr "A&lbero" msgid "&Listing format..." msgstr "Formato &lista..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Ordina per..." msgid "&Filter..." @@ -3075,7 +3076,8 @@ msgstr "Connessione FT&P..." msgid "S&hell link..." msgstr "Connessione S&hell..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "Connessione S&FTP..." msgid "Paneli&ze" @@ -4364,7 +4366,8 @@ msgid "sftp: %s" msgstr "sftp: %s" msgid "sftp: failed to convert remote host IP address into text form" -msgstr "sftp: fallita conversione indirizzo IP host remoto nella forma testuale" +msgstr "" +"sftp: fallita conversione indirizzo IP host remoto nella forma testuale" #, c-format msgid "sftp: making connection to %s" diff --git a/po/ja.po b/po/ja.po index 249f40e65..e3fd03a0b 100644 --- a/po/ja.po +++ b/po/ja.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Japanese (http://www.transifex.com/mc/mc/language/ja/)\n" @@ -2882,7 +2882,8 @@ msgstr "ツリー(&T)" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "整列順(&S)..." msgid "&Filter..." @@ -2897,8 +2898,9 @@ msgstr "FTP リンク(&P)..." msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." -msgstr "" +#, fuzzy +msgid "&SFTP link..." +msgstr "FTP リンク(&P)..." msgid "Paneli&ze" msgstr "" diff --git a/po/ka.po b/po/ka.po index ea40b566b..2a9092c5c 100644 --- a/po/ka.po +++ b/po/ka.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Georgian (http://www.transifex.com/mc/mc/language/ka/)\n" @@ -2865,7 +2865,7 @@ msgstr "&ხე" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +msgid "S&ort order..." msgstr "" msgid "&Filter..." @@ -2880,7 +2880,8 @@ msgstr "" msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "S&FTP ბმა..." msgid "Paneli&ze" diff --git a/po/kk.po b/po/kk.po index 4f3421ce8..0773dc04b 100644 --- a/po/kk.po +++ b/po/kk.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Kazakh (http://www.transifex.com/mc/mc/language/kk/)\n" @@ -2862,7 +2862,7 @@ msgstr "" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +msgid "S&ort order..." msgstr "" msgid "&Filter..." @@ -2877,7 +2877,7 @@ msgstr "" msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." +msgid "&SFTP link..." msgstr "" msgid "Paneli&ze" diff --git a/po/ko.po b/po/ko.po index cc80f7412..6237d6090 100644 --- a/po/ko.po +++ b/po/ko.po @@ -12,7 +12,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Korean (http://www.transifex.com/mc/mc/language/ko/)\n" @@ -3055,7 +3055,8 @@ msgstr "트리구조(&T)" msgid "&Listing format..." msgstr "목록 형식(&L)..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "정렬 순서(&S)..." msgid "&Filter..." @@ -3070,7 +3071,8 @@ msgstr "FTP 링크(&P)..." msgid "S&hell link..." msgstr "쉘 링크(&H)..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "SFTP 링크(&F)..." msgid "Paneli&ze" diff --git a/po/lt.po b/po/lt.po index f0c55f10f..11ffcc2fb 100644 --- a/po/lt.po +++ b/po/lt.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Lithuanian (http://www.transifex.com/mc/mc/language/lt/)\n" @@ -2947,7 +2947,8 @@ msgstr "&Medis" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "Rik. t&varka..." msgid "&Filter..." @@ -2962,8 +2963,9 @@ msgstr "FT&P ryšys..." msgid "S&hell link..." msgstr "Apli&nkos ryšys..." -msgid "S&FTP link..." -msgstr "" +#, fuzzy +msgid "&SFTP link..." +msgstr "FT&P ryšys..." msgid "Paneli&ze" msgstr "" diff --git a/po/lv.po b/po/lv.po index 61cdc53f1..357486907 100644 --- a/po/lv.po +++ b/po/lv.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Latvian (http://www.transifex.com/mc/mc/language/lv/)\n" @@ -2866,7 +2866,8 @@ msgstr "&Koks" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Kārtotā secībā..." msgid "&Filter..." @@ -2881,8 +2882,9 @@ msgstr "FT&P saite..." msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." -msgstr "" +#, fuzzy +msgid "&SFTP link..." +msgstr "FT&P saite..." msgid "Paneli&ze" msgstr "" diff --git a/po/mc.pot b/po/mc.pot index c0def8937..e26777ab9 100644 --- a/po/mc.pot +++ b/po/mc.pot @@ -5,9 +5,9 @@ # msgid "" msgstr "" -"Project-Id-Version: mc 4.8.27-16-gb87cb990e\n" +"Project-Id-Version: mc 4.8.27-57-ga73886ef9\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -602,31 +602,31 @@ msgid "" "Check the TERM environment variable.\n" msgstr "" -#: lib/util.c:349 +#: lib/util.c:348 msgid "B" msgstr "" -#: lib/util.c:354 +#: lib/util.c:353 msgid "kB" msgstr "" -#: lib/util.c:354 +#: lib/util.c:353 msgid "KiB" msgstr "" -#: lib/util.c:359 +#: lib/util.c:358 msgid "MB" msgstr "" -#: lib/util.c:359 +#: lib/util.c:358 msgid "MiB" msgstr "" -#: lib/util.c:364 +#: lib/util.c:363 msgid "GB" msgstr "" -#: lib/util.c:364 +#: lib/util.c:363 msgid "GiB" msgstr "" @@ -748,11 +748,11 @@ msgstr "" #: lib/widget/listbox.c:320 src/diffviewer/ydiff.c:3089 src/editor/edit.c:362 #: src/editor/editcmd.c:186 src/editor/editcmd.c:209 src/editor/editcmd.c:1521 -#: src/editor/editcmd.c:1527 src/filemanager/cmd.c:140 -#: src/filemanager/file.c:968 src/filemanager/file.c:1970 +#: src/editor/editcmd.c:1527 src/filemanager/cmd.c:138 +#: src/filemanager/file.c:972 src/filemanager/file.c:1969 #: src/filemanager/filegui.c:458 src/filemanager/filemanager.c:1062 #: src/filemanager/filemanager.c:1070 src/filemanager/hotlist.c:1159 -#: src/filemanager/hotlist.c:1176 src/filemanager/panel.c:2826 +#: src/filemanager/hotlist.c:1176 src/filemanager/panel.c:2827 #: src/filemanager/tree.c:829 src/subshell/common.c:1621 #: src/vfs/sftpfs/connection.c:518 src/vfs/sftpfs/connection.c:530 #: src/viewer/actions_cmd.c:643 src/viewer/actions_cmd.c:649 @@ -762,11 +762,11 @@ msgstr "" #: lib/widget/listbox.c:320 src/diffviewer/ydiff.c:3089 src/editor/edit.c:362 #: src/editor/editcmd.c:186 src/editor/editcmd.c:1521 src/editor/editcmd.c:1527 -#: src/filemanager/cmd.c:140 src/filemanager/file.c:968 -#: src/filemanager/file.c:1970 src/filemanager/filegui.c:460 +#: src/filemanager/cmd.c:138 src/filemanager/file.c:972 +#: src/filemanager/file.c:1969 src/filemanager/filegui.c:460 #: src/filemanager/filemanager.c:1062 src/filemanager/filemanager.c:1070 #: src/filemanager/hotlist.c:1159 src/filemanager/hotlist.c:1176 -#: src/filemanager/panel.c:2826 src/filemanager/tree.c:829 +#: src/filemanager/panel.c:2827 src/filemanager/tree.c:829 #: src/subshell/common.c:1621 src/vfs/sftpfs/connection.c:518 #: src/vfs/sftpfs/connection.c:530 src/viewer/actions_cmd.c:643 #: src/viewer/actions_cmd.c:649 src/viewer/search.c:448 @@ -775,7 +775,7 @@ msgstr "" #: lib/widget/quick.h:215 src/editor/editsearch.c:103 #: src/editor/editsearch.c:1007 src/editor/editwidget.c:157 -#: src/filemanager/boxes.c:1270 src/filemanager/filegui.c:1358 +#: src/filemanager/boxes.c:1270 src/filemanager/filegui.c:1357 #: src/filemanager/find.c:602 src/filemanager/layout.c:508 src/main.c:411 msgid "&OK" msgstr "" @@ -790,7 +790,7 @@ msgstr "" #: src/filemanager/chattr.c:233 src/filemanager/chattr.c:1108 #: src/filemanager/chmod.c:115 src/filemanager/chmod.c:438 #: src/filemanager/chown.c:87 src/filemanager/chown.c:311 -#: src/filemanager/cmd.c:1148 src/filemanager/filegui.c:1362 +#: src/filemanager/cmd.c:1057 src/filemanager/filegui.c:1361 #: src/filemanager/find.c:602 src/filemanager/hotlist.c:183 #: src/filemanager/hotlist.c:1015 src/filemanager/hotlist.c:1077 #: src/filemanager/layout.c:509 src/filemanager/panelize.c:143 src/learn.c:258 @@ -817,9 +817,9 @@ msgstr "" msgid "%s (%d)" msgstr "" -#: lib/widget/wtools.c:695 src/filemanager/file.c:847 -#: src/filemanager/file.c:921 src/filemanager/file.c:923 -#: src/filemanager/file.c:969 src/filemanager/file.c:3098 +#: lib/widget/wtools.c:695 src/filemanager/file.c:851 +#: src/filemanager/file.c:925 src/filemanager/file.c:927 +#: src/filemanager/file.c:973 src/filemanager/file.c:3096 #: src/filemanager/filegui.c:255 src/filemanager/filegui.c:482 msgid "&Abort" msgstr "" @@ -978,7 +978,7 @@ msgstr "" msgid "[+lineno] file1[:lineno] [file2[:lineno]...]" msgstr "" -#: src/args.c:382 src/filemanager/file.c:168 +#: src/args.c:382 src/filemanager/file.c:170 msgid "file" msgstr "" @@ -1030,7 +1030,7 @@ msgstr "" msgid "Reading failed" msgstr "" -#: src/background.c:219 src/filemanager/file.c:844 src/filemanager/file.c:916 +#: src/background.c:219 src/filemanager/file.c:848 src/filemanager/file.c:920 msgid "Background process error" msgstr "" @@ -1240,7 +1240,7 @@ msgid "\"%s\" is a directory" msgstr "" #: src/diffviewer/ydiff.c:3578 src/diffviewer/ydiff.c:3595 -#: src/filemanager/file.c:1777 src/viewer/mcviewer.c:349 +#: src/filemanager/file.c:1776 src/viewer/mcviewer.c:349 #, c-format msgid "" "Cannot stat \"%s\"\n" @@ -1298,7 +1298,7 @@ msgstr "" #: src/editor/edit.c:362 src/editor/editcmd.c:184 src/editor/editcmd.c:207 #: src/editor/editcmd.c:378 src/editor/editcmd.c:538 src/editor/editcmd.c:958 #: src/editor/editcmd.c:2013 src/editor/editcmd.c:2042 src/editor/etags.c:371 -#: src/execute.c:135 src/filemanager/file.c:2409 src/filemanager/panel.c:4523 +#: src/execute.c:135 src/filemanager/file.c:2408 src/filemanager/panel.c:4524 #: src/help.c:362 src/main.c:408 src/subshell/common.c:1619 #: src/vfs/sftpfs/connection.c:518 src/viewer/actions_cmd.c:443 msgid "Warning" @@ -1363,7 +1363,7 @@ msgid "&Macintosh format (CR)" msgstr "" #: src/editor/editcmd.c:401 src/editor/editcmd.c:1058 src/editor/editcmd.c:1749 -#: src/editor/editcmd.c:1780 src/filemanager/cmd.c:753 +#: src/editor/editcmd.c:1780 src/filemanager/cmd.c:751 msgid "Enter file name:" msgstr "" @@ -1442,8 +1442,8 @@ msgid "Which syntax file you want to edit?" msgstr "" #: src/editor/editcmd.c:1122 src/editor/editcmd.c:1168 -#: src/filemanager/cmd.c:953 src/filemanager/cmd.c:994 -#: src/filemanager/cmd.c:1052 +#: src/filemanager/cmd.c:862 src/filemanager/cmd.c:903 +#: src/filemanager/cmd.c:961 msgid "&User" msgstr "" @@ -1451,15 +1451,15 @@ msgstr "" msgid "&System wide" msgstr "" -#: src/editor/editcmd.c:1166 src/filemanager/cmd.c:992 +#: src/editor/editcmd.c:1166 src/filemanager/cmd.c:901 msgid "Menu edit" msgstr "" -#: src/editor/editcmd.c:1167 src/filemanager/cmd.c:993 +#: src/editor/editcmd.c:1167 src/filemanager/cmd.c:902 msgid "Which menu file do you want to edit?" msgstr "" -#: src/editor/editcmd.c:1168 src/filemanager/cmd.c:994 +#: src/editor/editcmd.c:1168 src/filemanager/cmd.c:903 msgid "&Local" msgstr "" @@ -1712,7 +1712,7 @@ msgstr "" msgid "Mo&ve" msgstr "" -#: src/editor/editmenu.c:113 src/filemanager/file.c:2694 +#: src/editor/editmenu.c:113 src/filemanager/file.c:2692 #: src/filemanager/filemanager.c:251 msgid "&Delete" msgstr "" @@ -2047,14 +2047,14 @@ msgstr "" msgid "&Replace" msgstr "" -#: src/editor/editsearch.c:243 src/filemanager/file.c:968 +#: src/editor/editsearch.c:243 src/filemanager/file.c:972 #: src/filemanager/filegui.c:471 msgid "A&ll" msgstr "" #: src/editor/editsearch.c:244 src/editor/spell.c:765 -#: src/filemanager/file.c:847 src/filemanager/file.c:920 -#: src/filemanager/file.c:923 src/filemanager/file.c:3099 +#: src/filemanager/file.c:851 src/filemanager/file.c:924 +#: src/filemanager/file.c:927 src/filemanager/file.c:3097 #: src/filemanager/filegui.c:252 msgid "&Skip" msgstr "" @@ -2262,8 +2262,8 @@ msgstr "" msgid "Load syntax file" msgstr "" -#: src/editor/syntax.c:1535 src/help.c:1101 src/usermenu.c:969 -#: src/usermenu.c:1009 +#: src/editor/syntax.c:1535 src/help.c:1101 src/usermenu.c:975 +#: src/usermenu.c:1015 #, c-format msgid "" "Cannot open file %s\n" @@ -2366,7 +2366,7 @@ msgstr "" #: src/filemanager/achown.c:859 src/filemanager/achown.c:894 #: src/filemanager/chattr.c:1107 src/filemanager/chmod.c:437 -#: src/filemanager/chown.c:310 src/filemanager/file.c:920 src/viewer/hex.c:431 +#: src/filemanager/chown.c:310 src/filemanager/file.c:924 src/viewer/hex.c:431 msgid "&Retry" msgstr "" @@ -2681,7 +2681,7 @@ msgstr "" msgid "Confirmation|&History cleanup" msgstr "" -#: src/filemanager/boxes.c:934 src/filemanager/cmd.c:139 +#: src/filemanager/boxes.c:934 src/filemanager/cmd.c:137 msgid "Confirmation" msgstr "" @@ -2785,7 +2785,7 @@ msgstr "" msgid "Background jobs" msgstr "" -#: src/filemanager/cd.c:287 src/filemanager/panel.c:3675 +#: src/filemanager/cd.c:287 src/filemanager/panel.c:3676 #: src/filemanager/tree.c:596 #, c-format msgid "" @@ -3044,200 +3044,200 @@ msgstr "" msgid "" msgstr "" -#: src/filemanager/cmd.c:120 +#: src/filemanager/cmd.c:118 msgid "Enter machine name (F1 for details):" msgstr "" -#: src/filemanager/cmd.c:139 +#: src/filemanager/cmd.c:137 msgid "Files tagged, want to cd?" msgstr "" -#: src/filemanager/cmd.c:145 src/filemanager/cmd.c:1131 -#: src/filemanager/panel.c:2804 src/filemanager/panel.c:3383 +#: src/filemanager/cmd.c:143 src/filemanager/cmd.c:1040 +#: src/filemanager/panel.c:2805 src/filemanager/panel.c:3384 msgid "Cannot change directory" msgstr "" -#: src/filemanager/cmd.c:196 +#: src/filemanager/cmd.c:194 msgid "Filter" msgstr "" -#: src/filemanager/cmd.c:197 +#: src/filemanager/cmd.c:195 msgid "Set expression for filtering filenames" msgstr "" -#: src/filemanager/cmd.c:357 +#: src/filemanager/cmd.c:355 #, c-format msgid "Link %s to:" msgstr "" -#: src/filemanager/cmd.c:359 +#: src/filemanager/cmd.c:357 msgid "Link" msgstr "" -#: src/filemanager/cmd.c:368 +#: src/filemanager/cmd.c:366 #, c-format msgid "link: %s" msgstr "" -#: src/filemanager/cmd.c:407 +#: src/filemanager/cmd.c:405 #, c-format msgid "symlink: %s" msgstr "" -#: src/filemanager/cmd.c:467 src/filemanager/panel.c:4771 +#: src/filemanager/cmd.c:465 src/filemanager/panel.c:4772 #, c-format msgid "Cannot chdir to \"%s\"" msgstr "" -#: src/filemanager/cmd.c:630 +#: src/filemanager/cmd.c:628 msgid "View file" msgstr "" -#: src/filemanager/cmd.c:630 +#: src/filemanager/cmd.c:628 msgid "Filename:" msgstr "" -#: src/filemanager/cmd.c:664 +#: src/filemanager/cmd.c:662 msgid "Filtered view" msgstr "" -#: src/filemanager/cmd.c:665 +#: src/filemanager/cmd.c:663 msgid "Filter command and arguments:" msgstr "" -#: src/filemanager/cmd.c:753 +#: src/filemanager/cmd.c:751 msgid "Edit file" msgstr "" -#: src/filemanager/cmd.c:845 +#: src/filemanager/cmd.c:783 msgid "Create a new Directory" msgstr "" -#: src/filemanager/cmd.c:846 +#: src/filemanager/cmd.c:784 msgid "Enter directory name:" msgstr "" -#: src/filemanager/cmd.c:951 +#: src/filemanager/cmd.c:860 msgid "Extension file edit" msgstr "" -#: src/filemanager/cmd.c:952 +#: src/filemanager/cmd.c:861 msgid "Which extension file you want to edit?" msgstr "" -#: src/filemanager/cmd.c:953 src/filemanager/cmd.c:994 -#: src/filemanager/cmd.c:1052 +#: src/filemanager/cmd.c:862 src/filemanager/cmd.c:903 +#: src/filemanager/cmd.c:961 msgid "&System Wide" msgstr "" -#: src/filemanager/cmd.c:1050 +#: src/filemanager/cmd.c:959 msgid "Highlighting groups file edit" msgstr "" -#: src/filemanager/cmd.c:1051 +#: src/filemanager/cmd.c:960 msgid "Which highlighting file you want to edit?" msgstr "" -#: src/filemanager/cmd.c:1146 +#: src/filemanager/cmd.c:1055 msgid "Compare directories" msgstr "" -#: src/filemanager/cmd.c:1147 +#: src/filemanager/cmd.c:1056 msgid "Select compare method:" msgstr "" -#: src/filemanager/cmd.c:1148 +#: src/filemanager/cmd.c:1057 msgid "&Quick" msgstr "" -#: src/filemanager/cmd.c:1148 +#: src/filemanager/cmd.c:1057 msgid "&Size only" msgstr "" -#: src/filemanager/cmd.c:1148 +#: src/filemanager/cmd.c:1057 msgid "&Thorough" msgstr "" -#: src/filemanager/cmd.c:1162 +#: src/filemanager/cmd.c:1071 msgid "" "Both panels should be in the listing mode\n" "to use this command" msgstr "" -#: src/filemanager/cmd.c:1220 +#: src/filemanager/cmd.c:1129 #, c-format msgid "'%s' is not a symbolic link" msgstr "" -#: src/filemanager/cmd.c:1233 +#: src/filemanager/cmd.c:1142 #, c-format msgid "Symlink '%s' points to:" msgstr "" -#: src/filemanager/cmd.c:1235 +#: src/filemanager/cmd.c:1144 msgid "Edit symlink" msgstr "" -#: src/filemanager/cmd.c:1248 +#: src/filemanager/cmd.c:1157 #, c-format msgid "edit symlink, unable to remove %s: %s" msgstr "" -#: src/filemanager/cmd.c:1256 +#: src/filemanager/cmd.c:1165 #, c-format msgid "edit symlink: %s" msgstr "" -#: src/filemanager/cmd.c:1301 +#: src/filemanager/cmd.c:1210 msgid "FTP to machine" msgstr "" -#: src/filemanager/cmd.c:1312 +#: src/filemanager/cmd.c:1221 msgid "SFTP to machine" msgstr "" -#: src/filemanager/cmd.c:1324 +#: src/filemanager/cmd.c:1233 msgid "Shell link to machine" msgstr "" -#: src/filemanager/cmd.c:1336 +#: src/filemanager/cmd.c:1245 msgid "Undelete files on an ext2 file system" msgstr "" -#: src/filemanager/cmd.c:1337 +#: src/filemanager/cmd.c:1246 msgid "" "Enter device (without /dev/) to undelete\n" "files on: (F1 for details)" msgstr "" -#: src/filemanager/cmd.c:1395 src/filemanager/cmd.c:1429 -#: src/filemanager/file.c:757 +#: src/filemanager/cmd.c:1304 src/filemanager/cmd.c:1338 +#: src/filemanager/file.c:760 msgid "Directory scanning" msgstr "" -#: src/filemanager/cmd.c:1475 src/filemanager/cmd.c:1477 +#: src/filemanager/cmd.c:1384 src/filemanager/cmd.c:1386 msgid "Setup" msgstr "" -#: src/filemanager/cmd.c:1475 +#: src/filemanager/cmd.c:1384 #, c-format msgid "Setup saved to %s" msgstr "" -#: src/filemanager/cmd.c:1477 +#: src/filemanager/cmd.c:1386 #, c-format msgid "Unable to save setup to %s" msgstr "" -#: src/filemanager/command.c:115 src/usermenu.c:958 +#: src/filemanager/command.c:115 src/usermenu.c:964 msgid "Cannot execute commands on non-local filesystems" msgstr "" -#: src/filemanager/ext.c:248 src/usermenu.c:476 +#: src/filemanager/ext.c:248 src/usermenu.c:477 msgid "Parameter" msgstr "" -#: src/filemanager/ext.c:462 src/usermenu.c:447 +#: src/filemanager/ext.c:462 src/usermenu.c:448 #, c-format msgid "" "Cannot create temporary command file\n" @@ -3273,7 +3273,7 @@ msgid "" "to copy it from %smc.ext or use that file as an example of how to write it." msgstr "" -#: src/filemanager/file.c:95 src/filemanager/file.c:2693 +#: src/filemanager/file.c:95 src/filemanager/file.c:2691 #: src/filemanager/tree.c:719 msgid "DialogTitle|Copy" msgstr "" @@ -3287,90 +3287,90 @@ msgstr "" msgid "DialogTitle|Delete" msgstr "" -#: src/filemanager/file.c:148 +#: src/filemanager/file.c:150 msgid "FileOperation|Copy" msgstr "" -#: src/filemanager/file.c:149 +#: src/filemanager/file.c:151 msgid "FileOperation|Move" msgstr "" -#: src/filemanager/file.c:150 +#: src/filemanager/file.c:152 msgid "FileOperation|Delete" msgstr "" -#: src/filemanager/file.c:163 -#, no-c-format -msgid "%o %f%n\"%s\"%m" -msgstr "" - #: src/filemanager/file.c:165 #, no-c-format +msgid "%o %f%n\"%s\"%m" +msgstr "" + +#: src/filemanager/file.c:167 +#, no-c-format msgid "%o %d %f%m" msgstr "" -#: src/filemanager/file.c:169 +#: src/filemanager/file.c:171 msgid "files" msgstr "" -#: src/filemanager/file.c:170 +#: src/filemanager/file.c:172 msgid "directory" msgstr "" -#: src/filemanager/file.c:171 +#: src/filemanager/file.c:173 msgid "directories" msgstr "" -#: src/filemanager/file.c:172 +#: src/filemanager/file.c:174 msgid "files/directories" msgstr "" #. TRANSLATORS: keep leading space here to split words in Copy/Move dialog -#: src/filemanager/file.c:174 +#: src/filemanager/file.c:176 msgid " with source mask:" msgstr "" -#: src/filemanager/file.c:401 +#: src/filemanager/file.c:404 #, c-format msgid "" "Cannot stat hardlink source file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:421 +#: src/filemanager/file.c:424 #, c-format msgid "" "Cannot create target hardlink \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:457 +#: src/filemanager/file.c:460 #, c-format msgid "Cannot create target hardlink \"%s\"" msgstr "" -#: src/filemanager/file.c:521 +#: src/filemanager/file.c:524 #, c-format msgid "" "Cannot read source link \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:535 +#: src/filemanager/file.c:538 msgid "" "Cannot make stable symlinks across non-local filesystems:\n" "\n" "Option Stable Symlinks will be disabled" msgstr "" -#: src/filemanager/file.c:604 +#: src/filemanager/file.c:607 #, c-format msgid "" "Cannot create target symlink \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:886 +#: src/filemanager/file.c:890 #, c-format msgid "" "\"%s\"\n" @@ -3379,7 +3379,7 @@ msgid "" "are the same directory" msgstr "" -#: src/filemanager/file.c:888 +#: src/filemanager/file.c:892 #, c-format msgid "" "\"%s\"\n" @@ -3388,18 +3388,18 @@ msgid "" "are the same file" msgstr "" -#: src/filemanager/file.c:920 src/filemanager/file.c:923 +#: src/filemanager/file.c:924 src/filemanager/file.c:927 msgid "Ski&p all" msgstr "" -#: src/filemanager/file.c:960 +#: src/filemanager/file.c:964 #, c-format msgid "" "Directory \"%s\" not empty.\n" "Delete it recursively?" msgstr "" -#: src/filemanager/file.c:961 +#: src/filemanager/file.c:965 #, c-format msgid "" "Background process:\n" @@ -3407,129 +3407,129 @@ msgid "" "Delete it recursively?" msgstr "" -#: src/filemanager/file.c:969 src/filemanager/filegui.c:475 +#: src/filemanager/file.c:973 src/filemanager/filegui.c:475 msgid "Non&e" msgstr "" -#: src/filemanager/file.c:1168 +#: src/filemanager/file.c:1167 #, c-format msgid "" "Cannot remove file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:1226 +#: src/filemanager/file.c:1225 #, c-format msgid "" "Cannot stat file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:1242 +#: src/filemanager/file.c:1241 #, c-format msgid "Cannot overwrite directory \"%s\"" msgstr "" -#: src/filemanager/file.c:1297 +#: src/filemanager/file.c:1296 #, c-format msgid "" "Cannot move file \"%s\" to \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:1403 +#: src/filemanager/file.c:1402 #, c-format msgid "" "Cannot remove directory \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:1641 src/filemanager/file.c:2259 +#: src/filemanager/file.c:1640 src/filemanager/file.c:2258 #, c-format msgid "" "Cannot overwrite directory \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:1643 +#: src/filemanager/file.c:1642 #, c-format msgid "" "Cannot overwrite file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:1664 +#: src/filemanager/file.c:1663 #, c-format msgid "" "Cannot move directory \"%s\" to \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:1766 +#: src/filemanager/file.c:1765 msgid "Cannot operate on \"..\"!" msgstr "" -#: src/filemanager/file.c:2278 +#: src/filemanager/file.c:2277 #, c-format msgid "" "Cannot stat source file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:2347 +#: src/filemanager/file.c:2346 #, c-format msgid "" "Cannot create special file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:2359 src/filemanager/file.c:2704 +#: src/filemanager/file.c:2358 src/filemanager/file.c:2702 #, c-format msgid "" "Cannot chown target file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:2374 src/filemanager/file.c:2720 +#: src/filemanager/file.c:2373 src/filemanager/file.c:2718 #, c-format msgid "" "Cannot chmod target file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:2396 +#: src/filemanager/file.c:2395 #, c-format msgid "" "Cannot open source file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:2409 +#: src/filemanager/file.c:2408 msgid "Reget failed, about to overwrite file" msgstr "" -#: src/filemanager/file.c:2420 +#: src/filemanager/file.c:2419 #, c-format msgid "" "Cannot fstat source file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:2452 +#: src/filemanager/file.c:2451 #, c-format msgid "" "Cannot create target file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:2483 +#: src/filemanager/file.c:2482 #, c-format msgid "" "Cannot fstat target file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:2504 +#: src/filemanager/file.c:2503 #, c-format msgid "" "Cannot preallocate space for target file \"%s\"\n" @@ -3550,54 +3550,54 @@ msgid "" "%s" msgstr "" -#: src/filemanager/file.c:2636 +#: src/filemanager/file.c:2635 msgid "(stalled)" msgstr "" -#: src/filemanager/file.c:2669 +#: src/filemanager/file.c:2667 #, c-format msgid "" "Cannot close source file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:2681 +#: src/filemanager/file.c:2679 #, c-format msgid "" "Cannot close target file \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:2693 +#: src/filemanager/file.c:2691 msgid "Incomplete file was retrieved. Keep it?" msgstr "" -#: src/filemanager/file.c:2694 +#: src/filemanager/file.c:2692 msgid "&Keep" msgstr "" -#: src/filemanager/file.c:2785 +#: src/filemanager/file.c:2783 #, c-format msgid "" "Cannot stat source directory \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:2829 +#: src/filemanager/file.c:2827 #, c-format msgid "" "Source \"%s\" is not a directory\n" "%s" msgstr "" -#: src/filemanager/file.c:2841 +#: src/filemanager/file.c:2839 #, c-format msgid "" "Cannot copy cyclic symbolic link\n" "\"%s\"" msgstr "" -#: src/filemanager/file.c:2880 src/filemanager/file.c:3369 +#: src/filemanager/file.c:2878 src/filemanager/file.c:3369 #: src/filemanager/tree.c:776 #, c-format msgid "" @@ -3605,21 +3605,21 @@ msgid "" "%s" msgstr "" -#: src/filemanager/file.c:2913 +#: src/filemanager/file.c:2911 #, c-format msgid "" "Cannot create target directory \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:2937 +#: src/filemanager/file.c:2935 #, c-format msgid "" "Cannot chown target directory \"%s\"\n" "%s" msgstr "" -#: src/filemanager/file.c:3140 +#: src/filemanager/file.c:3138 #, c-format msgid "Directories: %zu, total size: %s" msgstr "" @@ -3761,36 +3761,36 @@ msgstr "" msgid "Deleting" msgstr "" -#: src/filemanager/filegui.c:1345 src/filemanager/find.c:584 -#: src/filemanager/panel.c:2544 +#: src/filemanager/filegui.c:1344 src/filemanager/find.c:584 +#: src/filemanager/panel.c:2543 msgid "&Using shell patterns" msgstr "" -#: src/filemanager/filegui.c:1347 +#: src/filemanager/filegui.c:1346 msgid "to:" msgstr "" -#: src/filemanager/filegui.c:1351 +#: src/filemanager/filegui.c:1350 msgid "Follow &links" msgstr "" -#: src/filemanager/filegui.c:1352 +#: src/filemanager/filegui.c:1351 msgid "Preserve &attributes" msgstr "" -#: src/filemanager/filegui.c:1354 +#: src/filemanager/filegui.c:1353 msgid "Di&ve into subdir if exists" msgstr "" -#: src/filemanager/filegui.c:1355 +#: src/filemanager/filegui.c:1354 msgid "&Stable symlinks" msgstr "" -#: src/filemanager/filegui.c:1360 +#: src/filemanager/filegui.c:1359 msgid "&Background" msgstr "" -#: src/filemanager/filegui.c:1412 +#: src/filemanager/filegui.c:1411 #, c-format msgid "Invalid source pattern '%s'" msgstr "" @@ -3816,7 +3816,7 @@ msgid "&Listing format..." msgstr "" #: src/filemanager/filemanager.c:202 -msgid "&Sort order..." +msgid "S&ort order..." msgstr "" #: src/filemanager/filemanager.c:203 @@ -3836,7 +3836,7 @@ msgid "S&hell link..." msgstr "" #: src/filemanager/filemanager.c:215 -msgid "S&FTP link..." +msgid "&SFTP link..." msgstr "" #: src/filemanager/filemanager.c:217 @@ -4043,7 +4043,7 @@ msgstr[0] "" msgstr[1] "" #: src/filemanager/filemanager.c:1062 src/filemanager/filemanager.c:1068 -#: src/filemanager/panel.c:2825 +#: src/filemanager/panel.c:2826 msgid "The Midnight Commander" msgstr "" @@ -4599,67 +4599,67 @@ msgstr "" msgid "Group" msgstr "" -#: src/filemanager/panel.c:500 +#: src/filemanager/panel.c:499 msgid "[dev]" msgstr "" -#: src/filemanager/panel.c:513 src/filemanager/panel.c:1032 +#: src/filemanager/panel.c:512 src/filemanager/panel.c:1031 msgid "UP--DIR" msgstr "" -#: src/filemanager/panel.c:532 +#: src/filemanager/panel.c:531 msgid "SYMLINK" msgstr "" -#: src/filemanager/panel.c:535 +#: src/filemanager/panel.c:534 msgid "SUB-DIR" msgstr "" -#: src/filemanager/panel.c:1024 +#: src/filemanager/panel.c:1023 msgid "" msgstr "" -#: src/filemanager/panel.c:1089 +#: src/filemanager/panel.c:1088 #, c-format msgid "%s in %d file" msgid_plural "%s in %d files" msgstr[0] "" msgstr[1] "" -#: src/filemanager/panel.c:1292 +#: src/filemanager/panel.c:1291 msgid "Panelize" msgstr "" -#: src/filemanager/panel.c:1810 +#: src/filemanager/panel.c:1809 msgid "Unknown tag on display format:" msgstr "" -#: src/filemanager/panel.c:2543 +#: src/filemanager/panel.c:2542 msgid "&Files only" msgstr "" -#: src/filemanager/panel.c:2546 +#: src/filemanager/panel.c:2545 msgid "&Case sensitive" msgstr "" -#: src/filemanager/panel.c:2602 +#: src/filemanager/panel.c:2601 msgid "Select" msgstr "" -#: src/filemanager/panel.c:2610 +#: src/filemanager/panel.c:2609 msgid "Unselect" msgstr "" -#: src/filemanager/panel.c:2825 +#: src/filemanager/panel.c:2826 msgid "Do you really want to execute?" msgstr "" -#: src/filemanager/panel.c:3291 src/filemanager/panel.c:4422 -#: src/filemanager/panel.c:4470 src/viewer/actions_cmd.c:313 +#: src/filemanager/panel.c:3292 src/filemanager/panel.c:4423 +#: src/filemanager/panel.c:4471 src/viewer/actions_cmd.c:313 msgid "Cannot read directory contents" msgstr "" -#: src/filemanager/panel.c:4524 +#: src/filemanager/panel.c:4525 msgid "User supplied format looks invalid, reverting to default." msgstr "" @@ -5041,57 +5041,57 @@ msgstr "" msgid "Cache directory:" msgstr "" -#: src/usermenu.c:320 +#: src/usermenu.c:321 msgid "Debug" msgstr "" -#: src/usermenu.c:337 +#: src/usermenu.c:338 msgid "ERROR:" msgstr "" -#: src/usermenu.c:341 +#: src/usermenu.c:342 msgid "True:" msgstr "" -#: src/usermenu.c:343 +#: src/usermenu.c:344 msgid "False:" msgstr "" -#: src/usermenu.c:576 +#: src/usermenu.c:577 msgid "Error calling program" msgstr "" -#: src/usermenu.c:604 +#: src/usermenu.c:605 msgid "Warning -- ignoring file" msgstr "" -#: src/usermenu.c:605 +#: src/usermenu.c:606 #, c-format msgid "" "File %s is not owned by root or you or is world writable.\n" "Using it may compromise your security" msgstr "" -#: src/usermenu.c:717 -msgid "Format error on file Extensions File" -msgstr "" - #: src/usermenu.c:718 -#, c-format -msgid "The %%var macro has no default" +msgid "Format error on file Extensions File" msgstr "" #: src/usermenu.c:719 #, c-format +msgid "The %%var macro has no default" +msgstr "" + +#: src/usermenu.c:720 +#, c-format msgid "The %%var macro has no variable" msgstr "" -#: src/usermenu.c:1115 +#: src/usermenu.c:1121 #, c-format msgid "No suitable entries found in %s" msgstr "" -#: src/usermenu.c:1129 +#: src/usermenu.c:1135 msgid "User menu" msgstr "" @@ -5403,7 +5403,7 @@ msgstr "" msgid "sftp: Unable to get current user name." msgstr "" -#: src/vfs/sftpfs/connection.c:114 src/vfs/sftpfs/vfs_subclass.c:116 +#: src/vfs/sftpfs/connection.c:114 src/vfs/sftpfs/sftpfs.c:746 msgid "sftp: Invalid host name." msgstr "" @@ -5514,12 +5514,12 @@ msgstr "" msgid "sftp: socket error: %s" msgstr "" -#: src/vfs/sftpfs/vfs_class.c:207 +#: src/vfs/sftpfs/sftpfs.c:218 #, c-format msgid "sftp: (Ctrl-G break) Listing... %s" msgstr "" -#: src/vfs/sftpfs/vfs_class.c:209 +#: src/vfs/sftpfs/sftpfs.c:220 msgid "sftp: Listing done." msgstr "" diff --git a/po/mn.po b/po/mn.po index 45cbf7749..599e1ed2a 100644 --- a/po/mn.po +++ b/po/mn.po @@ -9,7 +9,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Mongolian (http://www.transifex.com/mc/mc/language/mn/)\n" @@ -2865,7 +2865,8 @@ msgstr "&Мод" msgid "&Listing format..." msgstr "&Жагшаалтын формат" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "Эрэмбэлэх &дараалал..." msgid "&Filter..." @@ -2880,8 +2881,9 @@ msgstr "&FTP-холбоос..." msgid "S&hell link..." msgstr "S&hell-холбоос..." -msgid "S&FTP link..." -msgstr "" +#, fuzzy +msgid "&SFTP link..." +msgstr "&FTP-холбоос..." msgid "Paneli&ze" msgstr "&Панелиз" diff --git a/po/nb.po b/po/nb.po index d218d3a92..b047e153c 100644 --- a/po/nb.po +++ b/po/nb.po @@ -10,7 +10,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-29 12:31+0000\n" "Last-Translator: heskjestad \n" "Language-Team: Norwegian Bokmål (http://www.transifex.com/mc/mc/language/" @@ -3065,7 +3065,8 @@ msgstr "&Tre" msgid "&Listing format..." msgstr "&Utlistingsformat ..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "Sorterings&rekkefølge ..." msgid "&Filter..." @@ -3080,7 +3081,8 @@ msgstr "Koble til FT&P ..." msgid "S&hell link..." msgstr "Koble til &skall ..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "K&oble til SFTP ..." msgid "Paneli&ze" diff --git a/po/nl.po b/po/nl.po index 80563024f..43def77ac 100644 --- a/po/nl.po +++ b/po/nl.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Dutch (http://www.transifex.com/mc/mc/language/nl/)\n" @@ -3059,7 +3059,8 @@ msgstr "&Boom" msgid "&Listing format..." msgstr "&Lijstformaat..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Sorteervolgorde... " msgid "&Filter..." @@ -3074,7 +3075,8 @@ msgstr "FT&P-Verbinding... " msgid "S&hell link..." msgstr "S&hellverbinding... " -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "S&FTP-link..." msgid "Paneli&ze" diff --git a/po/pl.po b/po/pl.po index 6cac9b173..4ffd0a671 100644 --- a/po/pl.po +++ b/po/pl.po @@ -10,7 +10,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-27 11:29+0000\n" "Last-Translator: Piotr Drąg \n" "Language-Team: Polish (http://www.transifex.com/mc/mc/language/pl/)\n" @@ -3068,7 +3068,8 @@ msgstr "&Drzewo" msgid "&Listing format..." msgstr "&Format wyświetlania…" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "Porządek s&ortowania…" msgid "&Filter..." @@ -3083,7 +3084,8 @@ msgstr "Połączenie FT&P…" msgid "S&hell link..." msgstr "Połączenie po po&włoce…" -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "Połączenie S&FTP…" msgid "Paneli&ze" diff --git a/po/pt.po b/po/pt.po index ff0c19793..3cf65db62 100644 --- a/po/pt.po +++ b/po/pt.po @@ -12,7 +12,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 23:56+0000\n" "Last-Translator: Gilberto Jorge \n" "Language-Team: Portuguese (http://www.transifex.com/mc/mc/language/pt/)\n" @@ -3065,7 +3065,8 @@ msgstr "&Árvore" msgid "&Listing format..." msgstr "Formato da &listagem..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Ordenação..." msgid "&Filter..." @@ -3080,7 +3081,8 @@ msgstr "Ligação FT&P..." msgid "S&hell link..." msgstr "Ligação s&hell..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "Ligação S&FTP..." msgid "Paneli&ze" diff --git a/po/pt_BR.po b/po/pt_BR.po index 7c5e1f966..bc5d7bdc0 100644 --- a/po/pt_BR.po +++ b/po/pt_BR.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Portuguese (Brazil) (http://www.transifex.com/mc/mc/language/" @@ -2980,7 +2980,8 @@ msgstr "&Árvore" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Ordem..." msgid "&Filter..." @@ -2995,8 +2996,9 @@ msgstr "Ligação FT&P..." msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." -msgstr "" +#, fuzzy +msgid "&SFTP link..." +msgstr "Ligação FT&P..." msgid "Paneli&ze" msgstr "" diff --git a/po/ro.po b/po/ro.po index 72aab06ec..1b04f4a09 100644 --- a/po/ro.po +++ b/po/ro.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Romanian (http://www.transifex.com/mc/mc/language/ro/)\n" @@ -3066,7 +3066,8 @@ msgstr "Arbore" msgid "&Listing format..." msgstr "formatul de &listare " -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Ordinea sortării..." msgid "&Filter..." @@ -3081,7 +3082,8 @@ msgstr "Conectare FT&P..." msgid "S&hell link..." msgstr "Conectare s&hell..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "Conectare S&FTP..." msgid "Paneli&ze" diff --git a/po/ru.po b/po/ru.po index 26525a16b..bf7ecfa7e 100644 --- a/po/ru.po +++ b/po/ru.po @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Russian (http://www.transifex.com/mc/mc/language/ru/)\n" @@ -3072,7 +3072,8 @@ msgstr "Дерев&о" msgid "&Listing format..." msgstr "Фор&мат списка..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "Порядок &сортировки..." msgid "&Filter..." @@ -3087,7 +3088,8 @@ msgstr "&FTP-соединение..." msgid "S&hell link..." msgstr "S&hell-соединение..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "&SFTP-соединение..." msgid "Paneli&ze" diff --git a/po/sk.po b/po/sk.po index 12afdda5d..2d4261269 100644 --- a/po/sk.po +++ b/po/sk.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Slovak (http://www.transifex.com/mc/mc/language/sk/)\n" @@ -3049,7 +3049,8 @@ msgstr "&Strom" msgid "&Listing format..." msgstr "&Formát výpisu..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Poradie výpisu..." msgid "&Filter..." @@ -3064,7 +3065,8 @@ msgstr "&Pripojenie FTP..." msgid "S&hell link..." msgstr "Pripojenie s&hell..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "Pripojenie S&FTP..." msgid "Paneli&ze" diff --git a/po/sl.po b/po/sl.po index abf0a7023..c82335a55 100644 --- a/po/sl.po +++ b/po/sl.po @@ -10,7 +10,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Slovenian (http://www.transifex.com/mc/mc/language/sl/)\n" @@ -2874,7 +2874,8 @@ msgstr "&Drevo" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Vrstni red..." msgid "&Filter..." @@ -2889,8 +2890,9 @@ msgstr "FT&P povezava..." msgid "S&hell link..." msgstr "&Lupinska povezava..." -msgid "S&FTP link..." -msgstr "" +#, fuzzy +msgid "&SFTP link..." +msgstr "FT&P povezava..." msgid "Paneli&ze" msgstr "" diff --git a/po/sr.po b/po/sr.po index 3077dbfd8..169ff5f2b 100644 --- a/po/sr.po +++ b/po/sr.po @@ -9,7 +9,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Serbian (http://www.transifex.com/mc/mc/language/sr/)\n" @@ -3027,7 +3027,8 @@ msgstr "&Стабло" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "Редослед &ређања..." msgid "&Filter..." @@ -3042,7 +3043,8 @@ msgstr "&ФТП веза..." msgid "S&hell link..." msgstr "Веза &љуске..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "&СФТП веза..." msgid "Paneli&ze" diff --git a/po/sv.po b/po/sv.po index e6343ee30..a1ca4ee91 100644 --- a/po/sv.po +++ b/po/sv.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Swedish (http://www.transifex.com/mc/mc/language/sv/)\n" @@ -3053,7 +3053,8 @@ msgstr "&Träd" msgid "&Listing format..." msgstr "&Listformat..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Sorteringsordning..." msgid "&Filter..." @@ -3068,7 +3069,8 @@ msgstr "FT&P-länk..." msgid "S&hell link..." msgstr "S&kallänk..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "SFTP-l&änk..." msgid "Paneli&ze" diff --git a/po/szl.po b/po/szl.po index 8e38d3d9d..a96901816 100644 --- a/po/szl.po +++ b/po/szl.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Silesian (http://www.transifex.com/mc/mc/language/szl/)\n" @@ -2862,7 +2862,7 @@ msgstr "" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +msgid "S&ort order..." msgstr "" msgid "&Filter..." @@ -2877,7 +2877,7 @@ msgstr "" msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." +msgid "&SFTP link..." msgstr "" msgid "Paneli&ze" diff --git a/po/ta.po b/po/ta.po index 64a6be732..5afc21312 100644 --- a/po/ta.po +++ b/po/ta.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Tamil (http://www.transifex.com/mc/mc/language/ta/)\n" @@ -2862,7 +2862,7 @@ msgstr "" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +msgid "S&ort order..." msgstr "" msgid "&Filter..." @@ -2877,7 +2877,7 @@ msgstr "" msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." +msgid "&SFTP link..." msgstr "" msgid "Paneli&ze" diff --git a/po/te.po b/po/te.po index ef4eb0b6f..221aa5b6d 100644 --- a/po/te.po +++ b/po/te.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Telugu (http://www.transifex.com/mc/mc/language/te/)\n" @@ -2861,7 +2861,7 @@ msgstr "" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +msgid "S&ort order..." msgstr "" msgid "&Filter..." @@ -2876,7 +2876,7 @@ msgstr "" msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." +msgid "&SFTP link..." msgstr "" msgid "Paneli&ze" diff --git a/po/tr.po b/po/tr.po index 9c78b83e1..e59691483 100644 --- a/po/tr.po +++ b/po/tr.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Turkish (http://www.transifex.com/mc/mc/language/tr/)\n" @@ -3043,7 +3043,8 @@ msgstr "&Ağaç" msgid "&Listing format..." msgstr "&Listeleme biçimi..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "&Sıralama türü..." msgid "&Filter..." @@ -3058,7 +3059,8 @@ msgstr "FT&P bağı..." msgid "S&hell link..." msgstr "&SSH bağı..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "FT&P bağı..." msgid "Paneli&ze" diff --git a/po/uk.po b/po/uk.po index d173ff793..b651dc6b0 100644 --- a/po/uk.po +++ b/po/uk.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Ukrainian (http://www.transifex.com/mc/mc/language/uk/)\n" @@ -3064,7 +3064,8 @@ msgstr "Д&eрево" msgid "&Listing format..." msgstr "&Формат списку" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "Порядок &сортування…" msgid "&Filter..." @@ -3079,7 +3080,8 @@ msgstr "&FTP-з’єднання…" msgid "S&hell link..." msgstr "&Shell-з’єднання…" -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "S&FTP-з’єднання…" msgid "Paneli&ze" diff --git a/po/vi.po b/po/vi.po index 4fcde004b..f76a3d2ae 100644 --- a/po/vi.po +++ b/po/vi.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Vietnamese (http://www.transifex.com/mc/mc/language/vi/)\n" @@ -2864,7 +2864,8 @@ msgstr "&Cây thư mục" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "t&Hứ tự sắp xếp..." msgid "&Filter..." @@ -2879,8 +2880,9 @@ msgstr "kết nối &FTP..." msgid "S&hell link..." msgstr "kết nối &Shell..." -msgid "S&FTP link..." -msgstr "" +#, fuzzy +msgid "&SFTP link..." +msgstr "kết nối &FTP..." msgid "Paneli&ze" msgstr "" diff --git a/po/wa.po b/po/wa.po index 78403c32c..bfd4e72d7 100644 --- a/po/wa.po +++ b/po/wa.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Walloon (http://www.transifex.com/mc/mc/language/wa/)\n" @@ -2862,7 +2862,8 @@ msgstr "Å&be" msgid "&Listing format..." msgstr "" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "Ôrde po &Relire..." msgid "&Filter..." @@ -2877,8 +2878,9 @@ msgstr "Loyén &FTP..." msgid "S&hell link..." msgstr "" -msgid "S&FTP link..." -msgstr "" +#, fuzzy +msgid "&SFTP link..." +msgstr "Loyén &FTP..." msgid "Paneli&ze" msgstr "" diff --git a/po/zh_CN.po b/po/zh_CN.po index b74b9cd4c..ffbdc8656 100644 --- a/po/zh_CN.po +++ b/po/zh_CN.po @@ -17,7 +17,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Chinese (China) (http://www.transifex.com/mc/mc/language/" @@ -3044,7 +3044,8 @@ msgstr "树(&T)" msgid "&Listing format..." msgstr "列表格式(&L)…" -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "排序(&S)..." msgid "&Filter..." @@ -3059,7 +3060,8 @@ msgstr "FTP 链接(&P)..." msgid "S&hell link..." msgstr "S&hell 链接..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "SFTP 链接(&S)..." msgid "Paneli&ze" diff --git a/po/zh_TW.po b/po/zh_TW.po index a8a008064..8078cde80 100644 --- a/po/zh_TW.po +++ b/po/zh_TW.po @@ -9,7 +9,7 @@ msgid "" msgstr "" "Project-Id-Version: Midnight Commander\n" "Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n" -"POT-Creation-Date: 2021-09-26 10:06+0300\n" +"POT-Creation-Date: 2021-11-21 15:18+0300\n" "PO-Revision-Date: 2021-07-26 20:16+0000\n" "Last-Translator: Transifex Bot <>\n" "Language-Team: Chinese (Taiwan) (http://www.transifex.com/mc/mc/language/" @@ -2897,7 +2897,8 @@ msgstr "樹狀" msgid "&Listing format..." msgstr "列表格式..." -msgid "&Sort order..." +#, fuzzy +msgid "S&ort order..." msgstr "排列順序..." msgid "&Filter..." @@ -2912,7 +2913,8 @@ msgstr "連結 FTP..." msgid "S&hell link..." msgstr "連結 Shell..." -msgid "S&FTP link..." +#, fuzzy +msgid "&SFTP link..." msgstr "連結 SFTP..." msgid "Paneli&ze"