- Applied patch from 2.5.9 to allow spaces in filenames (bug #431887).

This commit is contained in:
Tim Waugh 2008-02-08 13:39:40 +00:00
parent f04fe5457a
commit a1ecfbae1c
2 changed files with 24 additions and 3 deletions

16
patch-allow-spaces.patch Normal file
View File

@ -0,0 +1,16 @@
--- patch-2.5.4/util.c 1999-08-30 07:20:08.000000000 +0100
+++ patch-2.5.9/util.c 2003-05-20 15:04:53.000000000 +0100
@@ -939,7 +939,13 @@ fetchname (char *at, int strip_leading,
}
else if (ISSPACE ((unsigned char) *t))
{
+ /* Allow file names with internal spaces,
+ but only if a tab separates the file name from the date. */
char const *u = t;
+ while (*u != '\t' && ISSPACE ((unsigned char) u[1]))
+ u++;
+ if (*u != '\t' && strchr (u + 1, '\t'))
+ continue;
if (set_time | set_utc)
stamp = str2time (&u, initial_time,

View File

@ -1,7 +1,7 @@
Summary: The GNU patch command, for modifying/upgrading files Summary: The GNU patch command, for modifying/upgrading files
Name: patch Name: patch
Version: 2.5.4 Version: 2.5.4
Release: 31%{?dist} Release: 32%{?dist}
License: GPLv2+ License: GPLv2+
URL: http://www.gnu.org/software/patch/patch.html URL: http://www.gnu.org/software/patch/patch.html
Group: Development/Tools Group: Development/Tools
@ -13,7 +13,8 @@ Patch4: patch-2.5.4-ifdef.patch
Patch5: patch-2.5.4-program_name.patch Patch5: patch-2.5.4-program_name.patch
Patch6: patch-stripcr.patch Patch6: patch-stripcr.patch
Patch7: patch-parse.patch Patch7: patch-parse.patch
Patch8: patch-selinux.patch Patch8: patch-allow-spaces.patch
Patch9: patch-selinux.patch
Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%description %description
@ -35,7 +36,8 @@ applications.
%patch5 -p1 -b .program_name %patch5 -p1 -b .program_name
%patch6 -p1 -b .stripcr %patch6 -p1 -b .stripcr
%patch7 -p1 -b .parse %patch7 -p1 -b .parse
#%patch8 -p1 -b .selinux %patch8 -p1 -b .allow-spaces
#%patch9 -p1 -b .selinux
%build %build
CFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE" CFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE"
@ -62,6 +64,9 @@ rm -rf $RPM_BUILD_ROOT
%{_mandir}/*/* %{_mandir}/*/*
%changelog %changelog
* Fri Feb 8 2008 Tim Waugh <twaugh@redhat.com> 2.5.4-32
- Applied patch from 2.5.9 to allow spaces in filenames (bug #431887).
* Mon Dec 3 2007 Tim Waugh <twaugh@redhat.com> 2.5.4-31 * Mon Dec 3 2007 Tim Waugh <twaugh@redhat.com> 2.5.4-31
- Convert spec file to UTF-8 (bug #226233). - Convert spec file to UTF-8 (bug #226233).
- Use _bindir macro in %%files (bug #226233). - Use _bindir macro in %%files (bug #226233).