Ticket #2117 (new defect)

Opened 9 years ago

Last modified 7 years ago

View file with extension ended as a digit messed up output

Reported by: AlexJ Owned by:
Priority: minor Milestone: Future Releases
Component: mc-core Version: 4.7.0.2
Keywords: Cc:
Blocked By: Blocking:
Branch state: no branch Votes for changeset:

Description

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 preview a file that has extension for example xxx.1
messed up output.

Viewer attempt to show that files as a man page and as result
formatting of content is incorrect

Screenshots attached.

Attachments

open-conf-file.png (8.0 KB) - added by AlexJ 9 years ago.
MC error on attempt to view file with extesion .1
view_output.png (3.3 KB) - added by AlexJ 9 years ago.
Content displayed as wrapped
0001-call-file-with-z-switch-to-enable-getting-type-of-co.patch (4.4 KB) - added by ossi 9 years ago.
patch to fix detection of some file types

Change History

Changed 9 years ago by AlexJ

MC error on attempt to view file with extesion .1

Changed 9 years ago by AlexJ

Content displayed as wrapped

comment:1 Changed 9 years ago by andrew_b

  • Version changed from version not selected to 4.7.0.2

Changed 9 years ago by ossi

patch to fix detection of some file types

comment:2 Changed 9 years ago by ossi

this topic has come up on the ml several years ago already. as a result i have the attached patch applied since, like, forever.
there is one concern about the portability of the -z option of file. if it is not guaranteed (i.e., we still care for systems which don't have it), one would have to add a configure check and mc would have to pipe the data through gzip itself for systems where it is necessary.
the patch probably breaks some of the more recently added patterns, as i did only basic conflict resolution over the years. consider it a proof of concept only.

comment:3 Changed 8 years ago by andrew_b

  • Branch state set to no branch
  • Milestone changed from 4.7 to Future Releases

comment:4 Changed 7 years ago by slavazanko

  • Blocked By 2118 added

comment:5 Changed 7 years ago by slavazanko

  • Blocked By 2118 removed

(In #2118) merged to master:

git log --pretty=oneline e944301..5c6ae10
Note: See TracTickets for help on using tickets.