Ticket #3564 (closed defect: invalid)

Opened 8 years ago

Last modified 8 years ago

mc is slow to start

Reported by: imre84 Owned by:
Priority: major Milestone:
Component: mc-core Version: master
Keywords: Cc:
Blocked By: Blocking:
Branch state: no branch Votes for changeset:

Description

$ LC_MESSAGES=C mc -V
GNU Midnight Commander 4.8.14
Built with GLib 2.42.2
Using the ncurses library
With builtin Editor
With subshell support as default
With support for background operations
With mouse support on xterm and Linux console
With support for X11 events
With internationalization support
With multiple codepages support
Virtual File Systems: cpiofs, tarfs, sfs, extfs, ext2undelfs, ftpfs, fish
Data types: char: 8; int: 32; long: 64; void *: 64; size_t: 64; off_t: 64;

$ LC_MESSAGES=C mc -F
Root directory: /home/imi

[System data]

Config directory: /etc/mc/
Data directory: /usr/share/mc/
File extension handlers: /usr/libexec/mc/ext.d/
VFS plugins and scripts: /usr/libexec/mc/

extfs.d: /usr/libexec/mc/extfs.d/
fish: /usr/libexec/mc/fish/

[User data]

Config directory: /home/imi/.config/mc/
Data directory: /home/imi/.local/share/mc/

skins: /home/imi/.local/share/mc/skins/
extfs.d: /home/imi/.local/share/mc/extfs.d/
fish: /home/imi/.local/share/mc/fish/
mcedit macros: /home/imi/.local/share/mc/mc.macros
mcedit external macros: /home/imi/.local/share/mc/mcedit/macros.d/macro.*

Cache directory: /home/imi/.cache/mc/

$ mc --configure-options

'--prefix=/usr' '--build=x86_64-pc-linux-gnu' '--host=x86_64-pc-linux-gnu' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--datadir=/usr/share' '--sysconfdir=/etc' '--localstatedir=/var/lib' '--libdir=/usr/lib64' '--disable-silent-rules' '--disable-dependency-tracking' '--enable-nls' '--enable-vfs' '--enable-vfs-undelfs' '--enable-charset' '--with-x' '--disable-vfs-smb' '--disable-vfs-sftp' '--enable-aspell' '--with-gpm-mouse' '--with-screen=ncurses' '--with-internal-edit' '--disable-mclib' '--disable-tests' '--with-homedir=XDG' 'build_alias=x86_64-pc-linux-gnu' 'host_alias=x86_64-pc-linux-gnu' 'CFLAGS=-O2 -march=x86-64 -pipe' 'LDFLAGS=-Wl,-O1 -Wl,--as-needed' 'PKG_CONFIG_PATH=/usr/lib64/pkgconfig'

mc used to start quickly :) ... until five minutes ago :( ... but I know what changes I made in that five minutes :)

here's the 3 lines I appended to my /etc/bash/bashrc file:
export HISTCONTROL=ignoredups:erasedups
shopt -s histappend
export PROMPT_COMMAND="history -n; history -w; history -c; history -r; $PROMPT_COMMAND"

as a test I just commented out those to test if really those three lines cause the problem, once they commented out mc starts quickly again (in a newly started shell). when I put those back in, mc starts slowly again.

the final values of the relevant environment variables:

$ echo "$HISTCONTROL"
ignoredups:erasedups
$ echo "$PROMPT_COMMAND"
history -n; history -w; history -c; history -r;
$ shopt
autocd off
cdable_vars off
cdspell off
checkhash off
checkjobs off
checkwinsize on
cmdhist on
compat31 off
compat32 off
compat40 off
compat41 off
compat42 off
complete_fullquote on
direxpand off
dirspell off
dotglob off
execfail off
expand_aliases on
extdebug off
extglob on
extquote on
failglob off
force_fignore on
globstar off
globasciiranges off
gnu_errfmt off
histappend on
histreedit off
histverify off
hostcomplete off
huponexit off
interactive_comments on
lastpipe off
lithist off
login_shell off
mailwarn off
no_empty_cmd_completion on
nocaseglob off
nocasematch off
nullglob off
progcomp on
promptvars on
restricted_shell off
shift_verbose off
sourcepath on
xpg_echo off

I like what those three lines do, so I hope that this information is enough for you to find the bug and fix it :)

If not, I would be happy to provide any more info. Just let me know :)

Thank you in advance.

Change History

comment:1 in reply to: ↑ description ; follow-up: ↓ 2 Changed 8 years ago by mooffie

Replying to imre84:

here's the 3 lines I appended to my /etc/bash/bashrc file:
export HISTCONTROL=ignoredups:erasedups
shopt -s histappend
export PROMPT_COMMAND="history -n; history -w; history -c; history -r; $PROMPT_COMMAND"

You fell victim to this bug:

ticket:3534

It was fixed in MC 4.15.

comment:2 in reply to: ↑ 1 Changed 8 years ago by mooffie

Replying to mooffie:

It was fixed in MC 4.15.

I mean in 4.8.15.

comment:3 Changed 8 years ago by imre84

Indeed, removing the last semicolon from the end of variable PROMPT_COMMAND sped mc up again. Thank you for your reply.

comment:4 Changed 8 years ago by andrew_b

  • Status changed from new to closed
  • Resolution set to invalid
  • Milestone Future Releases deleted
Note: See TracTickets for help on using tickets.