non-printable character filter patch (#504144)

epel8
Rafał Psota 16 years ago
parent a76835f527
commit 8413399ae9

@ -0,0 +1,11 @@
--- RichString.c.orig 2008-03-09 03:23:49.000000000 +0100
+++ RichString.c 2008-11-18 12:30:21.000000000 +0100
@@ -89,7 +89,7 @@
inline void RichString_appendn(RichString* this, int attrs, char* data_c, int len) {
int last = MIN(RICHSTRING_MAXLEN - 1, len + this->len);
for (int i = this->len, j = 0; i < last; i++, j++)
- this->chstr[i] = data_c[j] | attrs;
+ this->chstr[i] = ((data_c[j] > 31) ? data_c[j] : '?' ) | attrs;
this->chstr[last] = 0;
this->len = last;
}

@ -1,6 +1,6 @@
Name: htop Name: htop
Version: 0.8.1 Version: 0.8.1
Release: 1%{?dist} Release: 2%{?dist}
Summary: Interactive process viewer Summary: Interactive process viewer
Summary(pl): Interaktywna przeglądarka procesów Summary(pl): Interaktywna przeglądarka procesów
@ -8,6 +8,7 @@ Group: Applications/System
License: GPL+ License: GPL+
URL: http://htop.sourceforge.net/ URL: http://htop.sourceforge.net/
Source0: http://download.sourceforge.net/htop/%{name}-%{version}.tar.gz Source0: http://download.sourceforge.net/htop/%{name}-%{version}.tar.gz
Patch0: %{name}-0.8.1-nonprint.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: desktop-file-utils BuildRequires: desktop-file-utils
@ -24,6 +25,7 @@ do top(1).
%prep %prep
%setup -q %setup -q
%patch0 -p0
sed -i s#"INSTALL_DATA = @INSTALL_DATA@"#"INSTALL_DATA = @INSTALL_DATA@ -p"# Makefile.in sed -i s#"INSTALL_DATA = @INSTALL_DATA@"#"INSTALL_DATA = @INSTALL_DATA@ -p"# Makefile.in
sed -i -e '2,3d' -e '9d' htop.desktop sed -i -e '2,3d' -e '9d' htop.desktop
@ -40,7 +42,7 @@ desktop-file-install \
--dir $RPM_BUILD_ROOT%{_datadir}/applications \ --dir $RPM_BUILD_ROOT%{_datadir}/applications \
--vendor fedora \ --vendor fedora \
--delete-original \ --delete-original \
--remove-category=Application \ --remove-category=Application\
$RPM_BUILD_ROOT%{_datadir}/applications/htop.desktop $RPM_BUILD_ROOT%{_datadir}/applications/htop.desktop
#remove empty direcories #remove empty direcories
@ -61,6 +63,8 @@ rm -rf $RPM_BUILD_ROOT
%changelog %changelog
* Tue Nov 18 2008 Rafał Psota <rafalzaq@gmail.com> - 0.8.1-2
- non-printable character filter patch (#504144)
* Tue Oct 14 2008 Rafał Psota <rafalzaq@gmail.com> - 0.8.1-1 * Tue Oct 14 2008 Rafał Psota <rafalzaq@gmail.com> - 0.8.1-1
- update to 0.8.1 - update to 0.8.1
* Thu Jul 31 2008 Rafał Psota <rafalzaq@gmail.com> - 0.8-1 * Thu Jul 31 2008 Rafał Psota <rafalzaq@gmail.com> - 0.8-1

Loading…
Cancel
Save