Ticket #2116 (new defect) — at Version 1

Opened 15 years ago

Last modified 15 years ago

Incorrect parsing in command line of MC

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

Description (last modified by andrew_b) (diff)

MC - 4.7.0.2
compiled as i686 without subshell
Target OS: FreeBSD (tried on 6.x, 7.x, 8.0)
Run in SSH terminal session via PuTTy.
===========================================
Defect:

Attempt to execute command:

date "+%Y-%m-%d T %H:%M:%S"

in the command line of MidnightCommander return result:

# date "+%Y-%m-/root/.mc/cedit T %H:%M:qqq"
2010-03-/root/.mc/cedit T 08:03:qqq

I believe it was evaluated were as a menu script, since %d %S was evaluated as internal MC substitution.

Change History

comment:1 Changed 15 years ago by andrew_b

  • Version changed from version not selected to 4.7.1
  • Description modified (diff)

Two solutions can be implemented:

  • use %% instead of % to escape MC substitutions. In this case user have to write
    date "+%%Y-%%m-/root/.mc/cedit T %%H:%%M:qqq"
    
  • use some special symbol (@ for example) as a start symbol of command to disable all MC substitutions in that command:
    @date "+%Y-%m-/root/.mc/cedit T %H:%M:qqq"
    
Note: See TracTickets for help on using tickets.