[lftp/f14] updated to latest upstream version lftp-4.3.3 fixes #666580 - Inaccurate timestamps fixes #720945 -

Jiri Skala jskala at fedoraproject.org
Wed Nov 16 12:45:42 UTC 2011


commit 50176106071a41d3d1c3a3cf7829e40ef56ca94f
Author: Jiri Skala <jskala at redhat.com>
Date:   Wed Nov 16 13:45:37 2011 +0100

    updated to latest upstream version lftp-4.3.3
    fixes #666580 - Inaccurate timestamps
    fixes #720945 - Process /usr/bin/lftp was killed by signal 11

 .gitignore                |    1 +
 lftp-4.0.9-date_fmt.patch |   16 ++++++++--------
 lftp-4.0.9-ssl3.patch     |   17 -----------------
 lftp-4.3.3-tmprec.patch   |   25 +++++++++++++++++++++++++
 lftp.spec                 |   13 +++++++++----
 sources                   |    2 +-
 6 files changed, 44 insertions(+), 30 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 4ee077a..fb177af 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,2 +1,3 @@
 lftp-4.0.9.tar.lzma
 /lftp-4.1.3.tar.xz
+/lftp-4.3.3.tar.xz
diff --git a/lftp-4.0.9-date_fmt.patch b/lftp-4.0.9-date_fmt.patch
index 38060c3..50fe672 100644
--- a/lftp-4.0.9-date_fmt.patch
+++ b/lftp-4.0.9-date_fmt.patch
@@ -1,6 +1,6 @@
-diff -up lftp-4.0.9/src/Http.cc.date_fmt lftp-4.0.9/src/Http.cc
---- lftp-4.0.9/src/Http.cc.date_fmt	2009-07-17 14:52:26.000000000 +0200
-+++ lftp-4.0.9/src/Http.cc	2010-06-30 08:07:00.818994525 +0200
+diff -up lftp-4.2.1/src/Http.cc.date_fmt lftp-4.2.1/src/Http.cc
+--- lftp-4.2.1/src/Http.cc.date_fmt	2011-03-25 15:35:42.000000000 +0100
++++ lftp-4.2.1/src/Http.cc	2011-03-30 14:40:54.170096624 +0200
 @@ -29,6 +29,7 @@
  #include <errno.h>
  #include <stdarg.h>
@@ -9,22 +9,22 @@ diff -up lftp-4.0.9/src/Http.cc.date_fmt lftp-4.0.9/src/Http.cc
  #include <fnmatch.h>
  #include <locale.h>
  #include <assert.h>
-@@ -562,16 +563,10 @@ void Http::SendRequest(const char *conne
+@@ -565,15 +566,10 @@ void Http::SendRequest(const char *conne
  		     (long long)((limit==FILE_END || limit>entity_size ? entity_size : limit)-1),
  		     (long long)entity_size);
        }
 -      if(entity_date!=NO_DATE)
 +      if(entity_date!=NO_DATE && entity_date>0L && entity_date<INT_MAX)
        {
- 	 char d[256];
 -	 static const char weekday_names[][4]={
 -	    "Sun","Mon","Tue","Wed","Thu","Fri","Sat"
 -	 };
--	 struct tm *t=gmtime(&entity_date);
--	 sprintf(d,"%s, %2d %s %04d %02d:%02d:%02d GMT",
+-	 const struct tm *t=gmtime(&entity_date);
+-	 const char *d=xstring::format("%s, %2d %s %04d %02d:%02d:%02d GMT",
 -	    weekday_names[t->tm_wday],t->tm_mday,month_names[t->tm_mon],
 -	    t->tm_year+1900,t->tm_hour,t->tm_min,t->tm_sec);
-+	 strftime(d, sizeof(d), "%a, %d %b %H:%M:%S %Y GMT", gmtime(&entity_date));
++         char d[256];
++         strftime(d, sizeof(d), "%a, %d %b %H:%M:%S %Y GMT", gmtime(&entity_date));
  	 Send("Last-Modified: %s\r\n",d);
        }
        break;
diff --git a/lftp-4.3.3-tmprec.patch b/lftp-4.3.3-tmprec.patch
new file mode 100644
index 0000000..88b4475
--- /dev/null
+++ b/lftp-4.3.3-tmprec.patch
@@ -0,0 +1,25 @@
+diff -up lftp-4.3.3/src/commands.cc.tmprec lftp-4.3.3/src/commands.cc
+--- lftp-4.3.3/src/commands.cc.tmprec	2011-11-16 12:50:49.885538761 +0100
++++ lftp-4.3.3/src/commands.cc	2011-11-16 12:59:34.008576204 +0100
+@@ -1542,20 +1542,7 @@ const char *FileSetOutput::parse_argv(co
+ 	 time_fmt.set("%Y-%m-%d \n%m-%d %H:%M");
+       else
+ 	 time_fmt.set(time_style);
+-      need_exact_time=false;
+-      if(time_fmt) {
+-	 static const char exact_fmts[][3]={"%H","%M","%S","%N",""};
+-	 int sep=strcspn(time_fmt,"\n|");
+-	 for(int i=0; exact_fmts[i][0]; i++) {
+-	    const char *f=strstr(time_fmt,exact_fmts[i]);
+-	    if(!f)
+-	       continue;
+-	    if(i>1 || sep>f-time_fmt) {
+-	       need_exact_time=true;
+-	       break;
+-	    }
+-	 }
+-      }
++      need_exact_time = time_fmt && strpbrk(time_fmt, "TrSs");
+    }
+ 
+    // remove parsed options.
diff --git a/lftp.spec b/lftp.spec
index 2462e51..0bbc150 100644
--- a/lftp.spec
+++ b/lftp.spec
@@ -1,7 +1,7 @@
 Summary:	A sophisticated file transfer program
 Name:		lftp
-Version:	4.1.3
-Release:	3%{?dist}
+Version:	4.3.3
+Release:	1%{?dist}
 License:	GPLv3+
 Group:		Applications/Internet
 Source0:	ftp://ftp.yar.ru/lftp/lftp-%{version}.tar.xz
@@ -10,7 +10,7 @@ BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires:	ncurses-devel, gnutls-devel, pkgconfig, readline-devel, gettext
 
 Patch1:  lftp-4.0.9-date_fmt.patch
-Patch2:  lftp-4.0.9-ssl3.patch
+Patch2:  lftp-4.3.3-tmprec.patch
 
 %description
 LFTP is a sophisticated ftp/http file transfer program. Like bash, it has job
@@ -31,7 +31,7 @@ Utility scripts for use with lftp.
 %setup -q
 
 %patch1 -p1 -b .date_fmt
-%patch2 -p1 -b .ssl3
+%patch2 -p1 -b .tmprec
 
 #sed -i.rpath -e '/lftp_cv_openssl/s|-R.*lib||' configure
 sed -i.norpath -e \
@@ -94,6 +94,11 @@ rm -rf $RPM_BUILD_ROOT
 
 
 %changelog
+* Thu Nov 10 2011 Jiri Skala <jskala at redhat.com> - 4.3.3-1
+- updated to latest upstream version lftp-4.3.3
+- fixes #666580 - Inaccurate timestamps
+- fixes #720945 - Process /usr/bin/lftp was killed by signal 11
+
 * Tue Jan 18 2011 Jiri Skala <jskala at redhat.com> - 4.1.3-1
 - updated to latest upstream version lftp-4.1.3
 - changed tarball compression
diff --git a/sources b/sources
index cbe2515..fa3cd8f 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-ff8b7baac71b90debebe588c5ffbff21  lftp-4.1.3.tar.xz
+7ff6217036e551020247ce74495f78c5  lftp-4.3.3.tar.xz


More information about the scm-commits mailing list