head 1.10; access; symbols OPENPKG_E1_MP_HEAD:1.6 OPENPKG_E1_MP:1.6 OPENPKG_E1_MP_2_STABLE:1.6 OPENPKG_E1_FP:1.6 OPENPKG_2_STABLE_MP:1.6 OPENPKG_2_STABLE_20061018:1.6 OPENPKG_2_STABLE_20060622:1.6 OPENPKG_2_STABLE:1.6.0.2 OPENPKG_2_STABLE_BP:1.6 OPENPKG_2_5_RELEASE:1.5 OPENPKG_2_5_SOLID:1.5.0.4 OPENPKG_2_5_SOLID_BP:1.5 OPENPKG_2_4_RELEASE:1.5 OPENPKG_2_4_SOLID:1.5.0.2 OPENPKG_2_4_SOLID_BP:1.5 OPENPKG_2_3_RELEASE:1.4 OPENPKG_2_3_SOLID:1.4.0.6 OPENPKG_2_3_SOLID_BP:1.4 OPENPKG_2_2_RELEASE:1.4 OPENPKG_2_2_SOLID:1.4.0.4 OPENPKG_2_2_SOLID_BP:1.4 OPENPKG_2_1_RELEASE:1.4 OPENPKG_2_1_SOLID:1.4.0.2 OPENPKG_2_1_SOLID_BP:1.4 OPENPKG_2_0_RELEASE:1.2 OPENPKG_2_0_SOLID:1.2.0.2 OPENPKG_2_0_SOLID_BP:1.2 OPENPKG_1_3_RELEASE:1.1.2.1 OPENPKG_1_3_SOLID:1.1.2.1.0.2 OPENPKG_1_3_SOLID_BP:1.1.2.1 OPENPKG_1_2_RELEASE:1.1 OPENPKG_1_2_SOLID:1.1.0.4 OPENPKG_1_2_SOLID_BP:1.1 OPENPKG_1_STABLE:1.1.0.2 OPENPKG_1_STABLE_BP:1.1; locks; strict; comment @# @; 1.10 date 2009.09.19.06.52.58; author rse; state Exp; branches; next 1.9; commitid utVVAIsHVxyF0g4u; 1.9 date 2009.09.13.19.24.36; author rse; state Exp; branches; next 1.8; commitid 5HhXGc8oswLtmy3u; 1.8 date 2008.11.18.19.42.58; author rse; state Exp; branches; next 1.7; commitid Er3SmLgZCT5F48rt; 1.7 date 2008.11.08.08.47.33; author rse; state Exp; branches; next 1.6; commitid 2AInCxg5AsLJLMpt; 1.6 date 2005.12.03.18.50.35; author rse; state Exp; branches; next 1.5; commitid IwhHepWMdJM0xccr; 1.5 date 2005.06.13.12.47.12; author steve; state Exp; branches 1.5.4.1; next 1.4; 1.4 date 2004.04.15.19.02.44; author rse; state dead; branches; next 1.3; 1.3 date 2004.04.02.12.34.02; author tho; state Exp; branches; next 1.2; 1.2 date 2003.02.28.19.02.16; author rse; state dead; branches; next 1.1; 1.1 date 2002.12.29.19.37.23; author rse; state Exp; branches 1.1.2.1 1.1.4.1; next ; 1.5.4.1 date 2005.11.04.18.06.40; author rse; state Exp; branches; next ; commitid XDen11xquUiJdt8r; 1.1.2.1 date 2003.07.24.20.44.21; author rse; state dead; branches 1.1.2.1.2.1; next ; 1.1.2.1.2.1 date 2003.12.16.19.21.15; author rse; state Exp; branches; next ; 1.1.4.1 date 2003.12.16.19.30.32; author rse; state Exp; branches; next ; desc @@ 1.10 log @upgrading package: lftp 4.0.0 -> 4.0.1 @ text @Index: src/lftp_tinfo.cc --- src/lftp_tinfo.cc.orig 2008-11-27 06:56:39 +0100 +++ src/lftp_tinfo.cc 2009-09-13 21:09:13 +0200 @@@@ -23,20 +23,20 @@@@ #include extern "C" { -#if defined(HAVE_CURSES_H) -# include -# if defined(HAVE_TERM_H) -# include -# elif defined(HAVE_NCURSES_TERM_H) -# include -# endif -#elif defined(HAVE_NCURSES_CURSES_H) +#if defined(HAVE_NCURSES_CURSES_H) # include # if defined(HAVE_NCURSES_TERM_H) # include # elif defined(HAVE_TERM_H) # include # endif +#elif defined(HAVE_CURSES_H) +# include +# if defined(HAVE_TERM_H) +# include +# elif defined(HAVE_NCURSES_TERM_H) +# include +# endif #elif defined(HAVE_TERMCAP_H) # include #endif @ 1.9 log @upgrading package: lftp 3.7.15 -> 4.0.0 @ text @a0 12 Index: src/Torrent.cc --- src/Torrent.cc.orig 2009-08-21 14:09:56 +0200 +++ src/Torrent.cc 2009-09-13 21:09:30 +0200 @@@@ -23,6 +23,8 @@@@ #include #include #include +#include +#include #include #include #include @ 1.8 log @upgrading package: lftp 3.7.5 -> 3.7.6 @ text @d1 12 d14 2 a15 2 --- src/lftp_tinfo.cc.orig 2006-02-06 12:00:41 +0100 +++ src/lftp_tinfo.cc 2008-11-18 19:58:43 +0100 @ 1.7 log @upgrading package: lftp 3.7.4 -> 3.7.5 @ text @a0 11 Index: src/commands.cc --- src/commands.cc.orig 2008-11-06 11:56:35 +0100 +++ src/commands.cc 2008-11-08 09:34:24 +0100 @@@@ -31,6 +31,7 @@@@ #include #include #include +#include #include #include #ifdef HAVE_DLFCN_H d3 1 a3 1 +++ src/lftp_tinfo.cc 2008-11-08 09:31:17 +0100 @ 1.6 log @upgrading package: lftp 3.3.4 -> 3.3.5 @ text @d1 11 d13 2 a14 2 --- src/lftp_tinfo.cc.orig 2005-12-02 07:25:05 +0100 +++ src/lftp_tinfo.cc 2005-12-03 19:39:27 +0100 @ 1.5 log @fixed ncurses/curses preference in build process @ text @d2 2 a3 2 --- src/lftp_tinfo.cc.orig 2002-12-18 09:52:20 +0100 +++ src/lftp_tinfo.cc 2005-06-13 12:05:39 +0200 d17 1 a17 1 #include d30 2 a32 2 } @ 1.5.4.1 log @apply vendor patch from 3.3.2: fixed a coredump caused by double-free @ text @a32 139 Index: src/ProcWait.cc --- src/ProcWait.cc 2004-01-14 09:23:46 +0100 +++ src/ProcWait.cc 2005-10-17 13:39:32 +0200 @@@@ -159,6 +159,6 @@@@ void ProcWait::DeleteAll() { Signal(false); - while(chain) - Delete(chain); + for(ProcWait *scan=chain; scan; scan=scan->next) + scan->deleting=true; } Index: src/SMTask.cc --- src/SMTask.cc 2005-06-22 10:04:21 +0200 +++ src/SMTask.cc 2005-10-17 12:47:42 +0200 @@@@ -114,21 +114,18 @@@@ if(*scan==this) { *scan=next; - break; + return; } scan=&((*scan)->next); } + assert(!"SMTask dtor called with unregistered task"); } void SMTask::Delete(SMTask *task) { if(!task) return; - if(task->deleting) - return; task->deleting=true; - if(!task->running) - delete task; } void SMTask::Enter(SMTask *task) @@@@ -166,6 +163,28 @@@@ && (max_time==0 || nowrunning && scan->deleting) + { + delete replace_value(scan,scan->next); + repeat_gc=true; + count++; + continue; + } + scan=scan->next; + } + } while(repeat_gc); + return count; +} + void SMTask::Schedule() { SMTask *scan; @@@@ -189,32 +208,20 @@@@ scan=scan->next; continue; } + if(repeat) scan->block.SetTimeout(0); // little optimization - int res=STALL; - - Enter(scan); // mark it current and running. - SMTask *entered=current; - if(!current->deleting) - res=current->Do(); // let it run unless it is dying. - assert(current==entered); - scan=scan->next; // move to a next task. - SMTask *to_delete=0; - if(current->deleting) - to_delete=current; - if(res!=MOVED && current->block.GetTimeout()==0) - res=MOVED; -#if 0 - if(res==MOVED) - printf("MOVED:%p\n",current); -#endif - Leave(current); // unmark it running and change current. + Enter(scan); // mark it current and running. + int res=scan->Do(); // let it run. + Leave(scan); // unmark it running and change current. - delete to_delete; - if(res==MOVED || to_delete) + if(res==MOVED || scan->block.GetTimeout()==0) repeat=true; + scan=scan->next; // move to a next task. } + if(CollectGarbage()) + repeat=true; if(repeat) { sched_total.SetTimeout(0); @@@@ -274,6 +281,7 @@@@ void SMTask::Cleanup() { + CollectGarbage(); delete init_task; } Index: src/SMTask.h --- src/SMTask.h 2005-08-04 12:08:11 +0200 +++ src/SMTask.h 2005-10-17 12:23:48 +0200 @@@@ -67,6 +67,7 @@@@ static void UpdateNow() { now.SetToCurrentTime(); } static void Schedule(); + static int CollectGarbage(); static void Block() { sched_total.Block(); } void Suspend(); Index: src/lftp.cc --- src/lftp.cc 2005-05-18 15:25:17 +0200 +++ src/lftp.cc 2005-10-17 12:47:43 +0200 @@@@ -112,6 +112,7 @@@@ { tty=isatty(0); ctty=(tcgetpgrp(0)!=(pid_t)-1); + add_newline=false; to_free=0; eof_count=0; for_history=0; @ 1.4 log @upgrading package: lftp 3.0.1 -> 3.0.2 @ text @d1 32 a32 11 --- src/FtpListInfo.cc.orig 2004-03-25 01:00:04.000000000 +0100 +++ src/FtpListInfo.cc 2004-04-02 14:27:32.000000000 +0200 @@@@ -788,7 +788,7 @@@@ } if(!strncasecmp(tok,"Size=",5)) { - size=atoll(tok+5); + size=strtoll(tok+5, (char **)NULL, 10); continue; } if(!strncasecmp(tok,"Perm=",5)) @ 1.3 log @upgrading package: lftp 2.6.12 -> 3.0.0 @ text @@ 1.2 log @upgrading package: lftp 2.6.4 -> 2.6.5 @ text @d1 11 a11 30 --- lib/trio.c.orig 2002-07-10 11:54:30.000000000 +0200 +++ lib/trio.c 2002-12-29 20:24:40.000000000 +0100 @@@@ -74,6 +74,7 @@@@ #include #include #if !defined(TRIO_COMPILER_SUPPORTS_C99) +# undef isblank # define isblank(x) (((x)==32) || ((x)==9)) #endif #include --- include/trio.h.orig 2002-07-10 11:36:33.000000000 +0200 +++ include/trio.h 2002-12-29 20:23:44.000000000 +0100 @@@@ -188,6 +188,7 @@@@ # define fscanf trio_fscanf #endif #ifndef HAVE_VFSCANF +# undef vfscanf # define vfscanf trio_vfscanf #endif #ifndef HAVE_SSCANF --- src/NetAccess.cc.orig 2002-12-25 14:44:31.000000000 +0100 +++ src/NetAccess.cc 2002-12-29 20:22:24.000000000 +0100 @@@@ -25,6 +25,7 @@@@ #include #include #include +#include #include #include #include "NetAccess.h" @ 1.1 log @finally upgrade after patching to get running @ text @@ 1.1.4.1 log @include security bugfix @ text @a30 33 Index: src/Http.cc --- src/Http.cc.orig 2003-05-28 14:39:23.000000000 +0200 +++ src/Http.cc 2003-12-16 20:09:13.000000000 +0100 @@@@ -1077,7 +1077,7 @@@@ const char *eol=find_eol(buf,len,&eol_size); if(eol) { - if(eol==buf) + if((eol==buf) && status) { DebugPrint("<--- ","",4); recv_buf->Skip(eol_size); Index: src/HttpDir.cc --- src/HttpDir.cc.orig 2003-04-15 13:26:32.000000000 +0200 +++ src/HttpDir.cc 2003-12-16 20:05:16.000000000 +0100 @@@@ -354,7 +354,7 @@@@ debug("Netscape-Proxy 2.53 listing matched"); return true; } - n=sscanf(str,"%3s %3s %d %2d:%2d:%2d %4d %s", + n=sscanf(str,"%3s %3s %d %2d:%2d:%2d %4d %30s", week_day,info.month_name,&info.day, &info.hour,&info.minute,&info.second,&info.year,info.size_str); if(n==7 || (n==8 && !is_ascii_digit(info.size_str[0]))) @@@@ -372,7 +372,7 @@@@ info.clear(); char week_day[4]; - int n=sscanf(str,"%3s %3s %d %2d:%2d:%2d %4d %s", + int n=sscanf(str,"%3s %3s %d %2d:%2d:%2d %4d %30s", week_day,info.month_name,&info.day, &info.hour,&info.minute,&info.second,&info.year,info.size_str); if(n==8) // maybe squid's EPLF listing. @ 1.1.2.1 log @mass Merge-From-CURRENT (MFC) in preparation for OpenPKG 1.3 [class BASE only] @ text @@ 1.1.2.1.2.1 log @modifying package: lftp-2.6.6 1.3.0 -> 1.3.1 @ text @d1 30 a30 42 Index: src/Http.cc --- src/Http.cc.orig 2003-05-28 14:39:23.000000000 +0200 +++ src/Http.cc 2003-12-16 20:09:13.000000000 +0100 @@@@ -1077,7 +1077,7 @@@@ const char *eol=find_eol(buf,len,&eol_size); if(eol) { - if(eol==buf) + if((eol==buf) && status) { DebugPrint("<--- ","",4); recv_buf->Skip(eol_size); Index: src/HttpDir.cc --- src/HttpDir.cc.orig 2003-04-15 13:26:32.000000000 +0200 +++ src/HttpDir.cc 2003-12-16 20:05:16.000000000 +0100 @@@@ -195,7 +195,7 @@@@ if(real_eol>buf && real_eol[-1]=='\r') { real_eol--; - *eol_size++; + (*eol_size)++; } return real_eol; } @@@@ -354,7 +354,7 @@@@ debug("Netscape-Proxy 2.53 listing matched"); return true; } - n=sscanf(str,"%3s %3s %d %2d:%2d:%2d %4d %s", + n=sscanf(str,"%3s %3s %d %2d:%2d:%2d %4d %30s", week_day,info.month_name,&info.day, &info.hour,&info.minute,&info.second,&info.year,info.size_str); if(n==7 || (n==8 && !is_ascii_digit(info.size_str[0]))) @@@@ -372,7 +372,7 @@@@ info.clear(); char week_day[4]; - int n=sscanf(str,"%3s %3s %d %2d:%2d:%2d %4d %s", + int n=sscanf(str,"%3s %3s %d %2d:%2d:%2d %4d %30s", week_day,info.month_name,&info.day, &info.hour,&info.minute,&info.second,&info.year,info.size_str); if(n==8) // maybe squid's EPLF listing. @