From a01bfbd8d1a69978fa3249dd80b15ddfd8213dca Mon Sep 17 00:00:00 2001 From: "Vojtech Vitek (V-Teq)" Date: Wed, 13 Apr 2011 16:00:15 +0200 Subject: [PATCH] Don't convert files with UTF-16/UTF-32 string in filename --- less.spec | 6 +++++- lesspipe.sh | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/less.spec b/less.spec index 1789d7f..7ffeb3b 100644 --- a/less.spec +++ b/less.spec @@ -1,7 +1,7 @@ Summary: A text file browser similar to more, but better Name: less Version: 436 -Release: 12%{?dist} +Release: 13%{?dist} License: GPLv3+ Group: Applications/Text Source: http://www.greenwoodsoftware.com/less/%{name}-%{version}.tar.gz @@ -72,6 +72,10 @@ ls -la $RPM_BUILD_ROOT/etc/profile.d rm -rf $RPM_BUILD_ROOT %changelog +* Wed Apr 13 2011 Vojtech Vitek (V-Teq) - 436-13 +- Don't convert files with UTF-16/UTF-32 string in filename + Resolve: #638312 + * Tue Feb 15 2011 Vojtech Vitek (V-Teq) - 436-12 - Enable LESSOPEN exit statuses as default also in less.sh Resolves: #666084, #676057 diff --git a/lesspipe.sh b/lesspipe.sh index c543c0d..819ce62 100755 --- a/lesspipe.sh +++ b/lesspipe.sh @@ -60,7 +60,7 @@ case "$1" in fi ;; *) if [ -x /usr/bin/file -a -x /usr/bin/iconv -a -x /usr/bin/cut ]; then - case `file "$1"` in + case `file -b "$1"` in *UTF-16*) conv='UTF-16' ;; *UTF-32*) conv='UTF-32' ;; esac