Re-introduce gcc44 patch

This commit is contained in:
Nicolas Chauvet 2009-05-21 00:25:36 +00:00
commit c172e271f1
2 changed files with 29 additions and 2 deletions

22
afflib-3.3.4-gcc44.patch Normal file
View file

@ -0,0 +1,22 @@
diff -up afflib-3.3.4/tools/afverify.cpp.gcc44 afflib-3.3.4/tools/afverify.cpp
--- afflib-3.3.4/tools/afverify.cpp.gcc44 2008-07-21 06:25:29.000000000 +0200
+++ afflib-3.3.4/tools/afverify.cpp 2009-03-02 12:48:59.000000000 +0100
@@ -240,12 +240,16 @@ string get_xml_field(const char *buf,con
int verify_bom_signature(AFFILE *af,const char *buf)
{
const char *cce = "</" AF_XML_AFFBOM ">\n";
- char *chain_end = strstr(buf,cce);
+ char *buf_tmp;
+ char *cce_tmp;
+ strcpy(buf_tmp, buf);
+ strcpy(cce_tmp, cce);
+ char *chain_end = strstr(buf_tmp,cce_tmp);
if(!chain_end){
warn("end of chain XML can't be found\n");
return -1; // can't find it
}
- char *sig_start = chain_end + strlen(cce);
+ char *sig_start = chain_end + strlen(cce_tmp);
BIO *seg = BIO_new_mem_buf((void *)buf,strlen(buf));
BIO_seek(seg,0);

View file

@ -1,12 +1,13 @@
Name: afflib
Version: 3.3.6
Release: 1%{?dist}
Release: 2%{?dist}
Summary: Library to support the Advanced Forensic Format
Group: System Environment/Libraries
License: BSD with advertising
URL: http://www.afflib.org
Source0: http://www.afflib.org/downloads/afflib-%{version}.tar.gz
Patch0: afflib-3.3.4-gcc44.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: libtool
@ -21,6 +22,7 @@ BuildRequires: libewf-devel >= 20080305
BuildRequires: ncurses-devel
BuildRequires: libtermcap-devel
BuildRequires: openssl-devel
BuildRequires: python-devel
# GPLv2 FOSS incompatible with BSD with advertising
##BuildRequires: readline-devel
#BuildRequires: libedit-devel - good replacement for readline - not supported for now
@ -55,6 +57,7 @@ developing applications that use %{name}.
%prep
%setup -q
%patch0 -p1 -b .gcc44
# prevent internal lzma to be built - testing
#rm -rf lzma443
@ -115,8 +118,10 @@ rm -rf $RPM_BUILD_ROOT
%changelog
* Thu May 21 2009 kwizart < kwizart at gmail.com > - 3.3.6-1
* Thu May 21 2009 kwizart < kwizart at gmail.com > - 3.3.6-2
- Update to 3.3.6
- Add BR python-devel
- Re-introduce gcc44 patch
* Tue May 12 2009 kwizart < kwizart at gmail.com > - 3.3.5-1
- Update to 3.3.5