Mageia Bugzilla – Attachment 9791 Details for
Bug 21996
Update request: ncftp 3.2.6
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
New Account
|
Forgot Password
[patch]
svn diff patch against mgarepo
ncftp-3.2.6-update-with-patch.patch (text/plain), 5.58 KB, created by
Stig-Ørjan Smelror
on 2017-11-14 19:57:01 CET
(
hide
)
Description:
svn diff patch against mgarepo
Filename:
MIME Type:
Creator:
Stig-Ørjan Smelror
Created:
2017-11-14 19:57:01 CET
Size:
5.58 KB
patch
obsolete
>Index: SOURCES/ncftp-3.1.1-EPLF.diff >=================================================================== >--- SOURCES/ncftp-3.1.1-EPLF.diff (revisjon 1177376) >+++ SOURCES/ncftp-3.1.1-EPLF.diff (nonexistent) >@@ -1,66 +0,0 @@ >---- libncftp/io_listmem.c 2006-03-13 19:41:50.000000000 +0100 >-+++ libncftp/io_listmem.c.oden 2008-12-22 11:55:31.000000000 +0100 >-@@ -31,6 +31,52 @@ >- # endif >- #endif >- >-+ >-+ >-+ >-+void parseEPLF(char *line) { >-+ char newline[512]; >-+ char *name=0; >-+ time_t mtime=0,now=time(0); >-+ char type=0; /* 0=file, 1=dir */ >-+ unsigned long size=0; >-+ char *ptr=line; >-+ struct tm *t; >-+ char date[20]; >-+ char *months[12]={"Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"}; >-+ while (*ptr) >-+ switch (*ptr) { >-+ case '\t': >-+ { >-+ char *tmp=strchr(ptr,'\n'); >-+ if (tmp) *tmp=0; >-+ } >-+ t=localtime(&mtime); >-+ if ((mtime<=now) && (mtime>=now-(60*60*24*7*26))) { >-+ sprintf(date,"%s %-2d %02d:%02d",months[t->tm_mon],t->tm_mday,t->tm_hour,t->tm_min); >-+ } else { >-+ sprintf(date,"%s %-2d %5d",months[t->tm_mon],t->tm_mday,t->tm_year+1900); >-+ } >-+ snprintf(newline,511,"%s 1 mirror mirror %8d %s %s", >-+ type?"drwxr-xr-x":"-rw-r--r--",size,date,ptr+1); >-+ newline[511]=0; >-+ strcpy(line,newline); >-+ return; >-+ case 's': >-+ while (*++ptr && (*ptr != ',')) >-+ size = size * 10 + (*ptr - '0'); >-+ break; >-+ case 'm': >-+ while (*++ptr && (*ptr != ',')) >-+ mtime = mtime * 10 + (*ptr - '0'); >-+ break; >-+ case '/': >-+ type=1; >-+ default: >-+ while (*ptr) if (*ptr++ == ',') break; >-+ } >-+} >-+ >- int >- FTPListToMemory2(const FTPCIPtr cip, const char *const pattern, const FTPLineListPtr llines, const char *const lsflags, const int blankLines, int *const tryMLSD) >- { >-@@ -161,6 +207,10 @@ FTPListToMemory2(const FTPCIPtr cip, con >- if ((line[0] == '.') && ((islsenddelim(line[1])) || ((line[1] == '.') && (islsenddelim(line[2]))))) >- continue; /* Skip . and .. */ >- >-+ if (line[0] == '+') { /* EPLF */ >-+ parseEPLF(line); >-+ } >-+ >- (void) AddLine(llines, line); >- } >- >Index: SOURCES/ncftp-3.2.6-EPLF.patch >=================================================================== >--- SOURCES/ncftp-3.2.6-EPLF.patch (nonexistent) >+++ SOURCES/ncftp-3.2.6-EPLF.patch (arbeidskopi) >@@ -0,0 +1,65 @@ >+--- libncftp/io_listmem.c.orig 2017-11-09 06:23:08.528442125 +0100 >++++ libncftp/io_listmem.c 2017-11-09 06:28:09.897439442 +0100 >+@@ -14,6 +14,49 @@ >+ # define NO_SIGNALS 1 >+ #endif >+ >++void parseEPLF(char *line) { >++ char newline[512]; >++ char *name=0; >++ time_t mtime=0,now=time(0); >++ char type=0; /* 0=file, 1=dir */ >++ unsigned long size=0; >++ char *ptr=line; >++ struct tm *t; >++ char date[20]; >++ char *months[12]={"Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"}; >++ while (*ptr) >++ switch (*ptr) { >++ case '\t': >++ { >++ char *tmp=strchr(ptr,'\n'); >++ if (tmp) *tmp=0; >++ } >++ t=localtime(&mtime); >++ if ((mtime<=now) && (mtime>=now-(60*60*24*7*26))) { >++ sprintf(date,"%s %-2d %02d:%02d",months[t->tm_mon],t->tm_mday,t->tm_hour,t->tm_min); >++ } else { >++ sprintf(date,"%s %-2d %5d",months[t->tm_mon],t->tm_mday,t->tm_year+1900); >++ } >++ snprintf(newline,511,"%s 1 mirror mirror %8d %s %s", >++ type?"drwxr-xr-x":"-rw-r--r--",size,date,ptr+1); >++ newline[511]=0; >++ strcpy(line,newline); >++ return; >++ case 's': >++ while (*++ptr && (*ptr != ',')) >++ size = size * 10 + (*ptr - '0'); >++ break; >++ case 'm': >++ while (*++ptr && (*ptr != ',')) >++ mtime = mtime * 10 + (*ptr - '0'); >++ break; >++ case '/': >++ type=1; >++ default: >++ while (*ptr) if (*ptr++ == ',') break; >++ } >++} >++ >+ int >+ FTPListToMemory2(const FTPCIPtr cip, const char *const pattern, const FTPLineListPtr llines, const char *const lsflags, const int blankLines, int *const tryMLSD) >+ { >+@@ -214,6 +257,12 @@ >+ if ((line[0] == '.') && ((islsenddelim(line[1])) || ((line[1] == '.') && (islsenddelim(line[2]))))) >+ continue; /* Skip . and .. */ >+ >++ if (line[0] == '+') { /* EPLF */ >++ parseEPLF(line); >++ } >++ >++ >++ >+ (void) AddLine(llines, line); >+ } >+ >Index: SOURCES/sha1.lst >=================================================================== >--- SOURCES/sha1.lst (revisjon 1177376) >+++ SOURCES/sha1.lst (arbeidskopi) >@@ -1 +1 @@ >-bae15ab31d16c5cec029ce5737c1288c13fd90bb ncftp-3.2.5-src.tar.bz2 >+b431eee7738a2441309ce11fc632e1b696ee1053 ncftp-3.2.6-src.tar.xz >Index: SPECS/ncftp.spec >=================================================================== >--- SPECS/ncftp.spec (revisjon 1177376) >+++ SPECS/ncftp.spec (arbeidskopi) >@@ -2,17 +2,17 @@ > > Summary: An improved FTP client > Name: ncftp >-Version: 3.2.5 >-Release: %mkrel 6 >-Group: Networking/File transfer >+Version: 3.2.6 >+Release: %mkrel 1 >+Group: Networking/File transfer > URL: http://www.ncftp.com/ > BuildRequires: pkgconfig(ncurses) > License: Artistic >-Source0: ftp://ftp.ncftp.com/ncftp/ncftp-%{version}-src.tar.bz2 >+Source0: ftp://ncftp.com/ncftp/ncftp-%{version}-src.tar.xz > Patch0: ncftp-confirm.patch >-Patch3: ncftp-3.2.5-resume.patch >+Patch3: ncftp-3.2.5-resume.patch > Patch5: ncftp-3.1.9-suspend.patch >-Patch7: ncftp-3.1.1-EPLF.diff >+Patch7: ncftp-3.2.6-EPLF.patch > Patch8: ncftp-3.2.3-fix-help-cmd.patch > > %description >@@ -32,12 +32,12 @@ > %build > %configure \ > --enable-signals >-%make >+%make_build > > %install > mkdir -p %{buildroot}{%{_bindir},%{_mandir}/man1} > >-%makeinstall_std >+%make_install > > # yves - 3.1.1-1mdk - fix doc perm > find doc -type f -exec chmod 0644 {} \;
Index: SOURCES/ncftp-3.1.1-EPLF.diff =================================================================== --- SOURCES/ncftp-3.1.1-EPLF.diff (revisjon 1177376) +++ SOURCES/ncftp-3.1.1-EPLF.diff (nonexistent) @@ -1,66 +0,0 @@ ---- libncftp/io_listmem.c 2006-03-13 19:41:50.000000000 +0100 -+++ libncftp/io_listmem.c.oden 2008-12-22 11:55:31.000000000 +0100 -@@ -31,6 +31,52 @@ - # endif - #endif - -+ -+ -+ -+void parseEPLF(char *line) { -+ char newline[512]; -+ char *name=0; -+ time_t mtime=0,now=time(0); -+ char type=0; /* 0=file, 1=dir */ -+ unsigned long size=0; -+ char *ptr=line; -+ struct tm *t; -+ char date[20]; -+ char *months[12]={"Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"}; -+ while (*ptr) -+ switch (*ptr) { -+ case '\t': -+ { -+ char *tmp=strchr(ptr,'\n'); -+ if (tmp) *tmp=0; -+ } -+ t=localtime(&mtime); -+ if ((mtime<=now) && (mtime>=now-(60*60*24*7*26))) { -+ sprintf(date,"%s %-2d %02d:%02d",months[t->tm_mon],t->tm_mday,t->tm_hour,t->tm_min); -+ } else { -+ sprintf(date,"%s %-2d %5d",months[t->tm_mon],t->tm_mday,t->tm_year+1900); -+ } -+ snprintf(newline,511,"%s 1 mirror mirror %8d %s %s", -+ type?"drwxr-xr-x":"-rw-r--r--",size,date,ptr+1); -+ newline[511]=0; -+ strcpy(line,newline); -+ return; -+ case 's': -+ while (*++ptr && (*ptr != ',')) -+ size = size * 10 + (*ptr - '0'); -+ break; -+ case 'm': -+ while (*++ptr && (*ptr != ',')) -+ mtime = mtime * 10 + (*ptr - '0'); -+ break; -+ case '/': -+ type=1; -+ default: -+ while (*ptr) if (*ptr++ == ',') break; -+ } -+} -+ - int - FTPListToMemory2(const FTPCIPtr cip, const char *const pattern, const FTPLineListPtr llines, const char *const lsflags, const int blankLines, int *const tryMLSD) - { -@@ -161,6 +207,10 @@ FTPListToMemory2(const FTPCIPtr cip, con - if ((line[0] == '.') && ((islsenddelim(line[1])) || ((line[1] == '.') && (islsenddelim(line[2]))))) - continue; /* Skip . and .. */ - -+ if (line[0] == '+') { /* EPLF */ -+ parseEPLF(line); -+ } -+ - (void) AddLine(llines, line); - } - Index: SOURCES/ncftp-3.2.6-EPLF.patch =================================================================== --- SOURCES/ncftp-3.2.6-EPLF.patch (nonexistent) +++ SOURCES/ncftp-3.2.6-EPLF.patch (arbeidskopi) @@ -0,0 +1,65 @@ +--- libncftp/io_listmem.c.orig 2017-11-09 06:23:08.528442125 +0100 ++++ libncftp/io_listmem.c 2017-11-09 06:28:09.897439442 +0100 +@@ -14,6 +14,49 @@ + # define NO_SIGNALS 1 + #endif + ++void parseEPLF(char *line) { ++ char newline[512]; ++ char *name=0; ++ time_t mtime=0,now=time(0); ++ char type=0; /* 0=file, 1=dir */ ++ unsigned long size=0; ++ char *ptr=line; ++ struct tm *t; ++ char date[20]; ++ char *months[12]={"Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"}; ++ while (*ptr) ++ switch (*ptr) { ++ case '\t': ++ { ++ char *tmp=strchr(ptr,'\n'); ++ if (tmp) *tmp=0; ++ } ++ t=localtime(&mtime); ++ if ((mtime<=now) && (mtime>=now-(60*60*24*7*26))) { ++ sprintf(date,"%s %-2d %02d:%02d",months[t->tm_mon],t->tm_mday,t->tm_hour,t->tm_min); ++ } else { ++ sprintf(date,"%s %-2d %5d",months[t->tm_mon],t->tm_mday,t->tm_year+1900); ++ } ++ snprintf(newline,511,"%s 1 mirror mirror %8d %s %s", ++ type?"drwxr-xr-x":"-rw-r--r--",size,date,ptr+1); ++ newline[511]=0; ++ strcpy(line,newline); ++ return; ++ case 's': ++ while (*++ptr && (*ptr != ',')) ++ size = size * 10 + (*ptr - '0'); ++ break; ++ case 'm': ++ while (*++ptr && (*ptr != ',')) ++ mtime = mtime * 10 + (*ptr - '0'); ++ break; ++ case '/': ++ type=1; ++ default: ++ while (*ptr) if (*ptr++ == ',') break; ++ } ++} ++ + int + FTPListToMemory2(const FTPCIPtr cip, const char *const pattern, const FTPLineListPtr llines, const char *const lsflags, const int blankLines, int *const tryMLSD) + { +@@ -214,6 +257,12 @@ + if ((line[0] == '.') && ((islsenddelim(line[1])) || ((line[1] == '.') && (islsenddelim(line[2]))))) + continue; /* Skip . and .. */ + ++ if (line[0] == '+') { /* EPLF */ ++ parseEPLF(line); ++ } ++ ++ ++ + (void) AddLine(llines, line); + } + Index: SOURCES/sha1.lst =================================================================== --- SOURCES/sha1.lst (revisjon 1177376) +++ SOURCES/sha1.lst (arbeidskopi) @@ -1 +1 @@ -bae15ab31d16c5cec029ce5737c1288c13fd90bb ncftp-3.2.5-src.tar.bz2 +b431eee7738a2441309ce11fc632e1b696ee1053 ncftp-3.2.6-src.tar.xz Index: SPECS/ncftp.spec =================================================================== --- SPECS/ncftp.spec (revisjon 1177376) +++ SPECS/ncftp.spec (arbeidskopi) @@ -2,17 +2,17 @@ Summary: An improved FTP client Name: ncftp -Version: 3.2.5 -Release: %mkrel 6 -Group: Networking/File transfer +Version: 3.2.6 +Release: %mkrel 1 +Group: Networking/File transfer URL: http://www.ncftp.com/ BuildRequires: pkgconfig(ncurses) License: Artistic -Source0: ftp://ftp.ncftp.com/ncftp/ncftp-%{version}-src.tar.bz2 +Source0: ftp://ncftp.com/ncftp/ncftp-%{version}-src.tar.xz Patch0: ncftp-confirm.patch -Patch3: ncftp-3.2.5-resume.patch +Patch3: ncftp-3.2.5-resume.patch Patch5: ncftp-3.1.9-suspend.patch -Patch7: ncftp-3.1.1-EPLF.diff +Patch7: ncftp-3.2.6-EPLF.patch Patch8: ncftp-3.2.3-fix-help-cmd.patch %description @@ -32,12 +32,12 @@ %build %configure \ --enable-signals -%make +%make_build %install mkdir -p %{buildroot}{%{_bindir},%{_mandir}/man1} -%makeinstall_std +%make_install # yves - 3.1.1-1mdk - fix doc perm find doc -type f -exec chmod 0644 {} \;
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 21996
:
9779
|
9780
| 9791