ChangeLog 379 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771977297739774977597769777977897799780978197829783978497859786978797889789979097919792979397949795979697979798979998009801980298039804980598069807980898099810981198129813981498159816981798189819982098219822982398249825982698279828982998309831983298339834983598369837983898399840984198429843984498459846984798489849985098519852985398549855985698579858985998609861986298639864986598669867986898699870987198729873987498759876987798789879988098819882988398849885988698879888988998909891989298939894989598969897989898999900990199029903990499059906990799089909991099119912991399149915991699179918991999209921992299239924992599269927992899299930993199329933993499359936993799389939994099419942994399449945994699479948994999509951995299539954995599569957995899599960996199629963996499659966996799689969997099719972997399749975997699779978997999809981998299839984998599869987998899899990999199929993999499959996999799989999100001000110002100031000410005100061000710008100091001010011100121001310014100151001610017100181001910020100211002210023100241002510026100271002810029100301003110032100331003410035100361003710038100391004010041100421004310044100451004610047100481004910050100511005210053100541005510056100571005810059100601006110062100631006410065100661006710068100691007010071100721007310074100751007610077100781007910080100811008210083100841008510086100871008810089100901009110092100931009410095100961009710098100991010010101101021010310104101051010610107101081010910110101111011210113101141011510116101171011810119101201012110122101231012410125101261012710128101291013010131101321013310134101351013610137101381013910140101411014210143101441014510146101471014810149101501015110152101531015410155101561015710158101591016010161101621016310164101651016610167101681016910170101711017210173101741017510176101771017810179101801018110182101831018410185101861018710188101891019010191101921019310194101951019610197101981019910200102011020210203102041020510206102071020810209102101021110212102131021410215102161021710218102191022010221102221022310224102251022610227102281022910230102311023210233102341023510236102371023810239102401024110242102431024410245102461024710248102491025010251102521025310254102551025610257102581025910260102611026210263102641026510266102671026810269102701027110272102731027410275102761027710278102791028010281102821028310284102851028610287102881028910290102911029210293102941029510296102971029810299103001030110302103031030410305103061030710308103091031010311103121031310314103151031610317103181031910320103211032210323103241032510326103271032810329103301033110332103331033410335103361033710338103391034010341103421034310344103451034610347103481034910350103511035210353103541035510356103571035810359103601036110362103631036410365103661036710368103691037010371103721037310374103751037610377103781037910380103811038210383103841038510386103871038810389103901039110392103931039410395103961039710398103991040010401104021040310404104051040610407104081040910410104111041210413104141041510416104171041810419104201042110422104231042410425104261042710428104291043010431104321043310434104351043610437104381043910440104411044210443104441044510446104471044810449104501045110452104531045410455104561045710458104591046010461104621046310464104651046610467104681046910470104711047210473104741047510476104771047810479104801048110482104831048410485104861048710488104891049010491104921049310494104951049610497104981049910500105011050210503105041050510506105071050810509105101051110512105131051410515105161051710518105191052010521105221052310524105251052610527105281052910530105311053210533105341053510536105371053810539105401054110542105431054410545105461054710548105491055010551105521055310554105551055610557105581055910560105611056210563105641056510566105671056810569105701057110572105731057410575105761057710578105791058010581105821058310584105851058610587105881058910590105911059210593105941059510596105971059810599106001060110602106031060410605106061060710608106091061010611106121061310614106151061610617106181061910620106211062210623106241062510626106271062810629106301063110632106331063410635106361063710638106391064010641106421064310644106451064610647106481064910650106511065210653106541065510656106571065810659106601066110662106631066410665106661066710668106691067010671106721067310674106751067610677106781067910680106811068210683106841068510686106871068810689106901069110692106931069410695106961069710698106991070010701107021070310704107051070610707107081070910710107111071210713107141071510716107171071810719107201072110722107231072410725107261072710728107291073010731107321073310734107351073610737107381073910740107411074210743107441074510746107471074810749107501075110752107531075410755107561075710758107591076010761107621076310764107651076610767107681076910770107711077210773107741077510776107771077810779107801078110782107831078410785107861078710788107891079010791107921079310794107951079610797107981079910800108011080210803108041080510806108071080810809108101081110812108131081410815108161081710818108191082010821108221082310824108251082610827108281082910830108311083210833108341083510836108371083810839108401084110842108431084410845108461084710848108491085010851108521085310854108551085610857108581085910860108611086210863108641086510866108671086810869108701087110872108731087410875108761087710878108791088010881108821088310884108851088610887108881088910890108911089210893108941089510896108971089810899109001090110902109031090410905109061090710908109091091010911109121091310914109151091610917109181091910920109211092210923109241092510926109271092810929109301093110932109331093410935109361093710938109391094010941109421094310944109451094610947109481094910950109511095210953109541095510956109571095810959109601096110962109631096410965109661096710968109691097010971109721097310974109751097610977109781097910980109811098210983109841098510986109871098810989109901099110992109931099410995109961099710998109991100011001110021100311004110051100611007110081100911010110111101211013110141101511016110171101811019110201102111022110231102411025110261102711028110291103011031110321103311034110351103611037110381103911040110411104211043110441104511046110471104811049110501105111052110531105411055110561105711058110591106011061110621106311064110651106611067110681106911070110711107211073110741107511076110771107811079110801108111082110831108411085110861108711088110891109011091110921109311094110951109611097110981109911100111011110211103111041110511106111071110811109111101111111112111131111411115111161111711118111191112011121111221112311124111251112611127111281112911130111311113211133111341113511136111371113811139111401114111142111431114411145111461114711148111491115011151111521115311154111551115611157111581115911160111611116211163111641116511166111671116811169111701117111172111731117411175111761117711178111791118011181111821118311184111851118611187111881118911190111911119211193111941119511196111971119811199112001120111202112031120411205112061120711208112091121011211112121121311214112151121611217112181121911220112211122211223112241122511226112271122811229112301123111232112331123411235112361123711238112391124011241112421124311244112451124611247112481124911250112511125211253112541125511256112571125811259112601126111262112631126411265112661126711268112691127011271112721127311274112751127611277112781127911280112811128211283112841128511286112871128811289112901129111292112931129411295112961129711298112991130011301113021130311304113051130611307113081130911310113111131211313113141131511316113171131811319113201132111322113231132411325113261132711328113291133011331113321133311334113351133611337113381133911340113411134211343113441134511346113471134811349113501135111352113531135411355113561135711358113591136011361113621136311364113651136611367113681136911370113711137211373113741137511376113771137811379113801138111382113831138411385113861138711388113891139011391113921139311394113951139611397113981139911400114011140211403114041140511406114071140811409114101141111412114131141411415114161141711418114191142011421114221142311424114251142611427114281142911430114311143211433114341143511436114371143811439114401144111442114431144411445114461144711448114491145011451114521145311454114551145611457114581145911460114611146211463114641146511466114671146811469114701147111472114731147411475114761147711478114791148011481114821148311484114851148611487114881148911490114911149211493114941149511496114971149811499115001150111502115031150411505115061150711508115091151011511115121151311514115151151611517115181151911520115211152211523115241152511526115271152811529115301153111532115331153411535115361153711538115391154011541115421154311544115451154611547115481154911550
  1. 2008-06-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2. Use digits to find first byte of file size, which makes the intention
  3. of the code clearer.
  4. * src/FtpConnection.cc
  5. Don't call validateTotalLength() when size is 0.
  6. * src/FtpNegotiationCommand.cc
  7. 2008-06-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  8. Updated po files.
  9. * po/aria2c.pot
  10. * po/*.gmo
  11. * po/*.po
  12. 2008-06-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  13. Clarified usage text for --split option.
  14. * src/usage_text.h
  15. 2008-06-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  16. Bump up version number to 0.15.0dev. "dev" means "development"
  17. version, which means I started the development of the next release!
  18. * src/configure.ac
  19. 2008-06-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  20. If FTP server returns negative response with REST raw command and
  21. requested range is not 0, throw exception. If requested range is 0,
  22. continue download a file from 0 byte.
  23. * src/FtpNegotiationCommand.cc
  24. * src/FtpNegotiationCommand.h
  25. 2008-06-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  26. Supported FTP server which don't recognize SIZE raw command.
  27. If SIZE raw command is failed, aria2 will try to get file size
  28. from the response of RETR raw command. If both attempts are failed,
  29. then resuming and segmented downloading are disabled.
  30. * src/FtpConnection.cc
  31. * src/FtpConnection.h
  32. * src/FtpNegotiationCommand.cc
  33. * src/FtpNegotiationCommand.h
  34. 2008-06-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  35. * Release 0.14.0+1
  36. 2008-06-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  37. Bump up version number to 0.14.0+1
  38. * src/configure.ac
  39. 2008-06-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  40. Fixed the code that refers static member variable from non-static
  41. context.
  42. * src/DefaultPeerStorage.cc
  43. 2008-06-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  44. * Release 0.14.0
  45. 2008-06-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  46. Added build test script
  47. * build_test.sh
  48. 2008-06-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  49. Updated ja.po
  50. * src/ja.po
  51. 2008-06-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  52. Bump up version number to 0.14.0
  53. * src/configure.ac
  54. 2008-06-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  55. Updated ja.po and fr.po. Great thanks for french translators and
  56. Sebastien WILLEMIJNS.
  57. * po/fr.po
  58. * po/ja.po
  59. 2008-06-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  60. Added configure option to enable/disable epoll support.
  61. * configure.ac
  62. 2008-06-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  63. Updated man page.
  64. * doc/aria2c.1.txt
  65. * doc/aria2c.1
  66. * doc/aria2c.1.html
  67. 2008-06-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  68. Added missing default value '5' to the usage of --split option.
  69. * src/HelpItemFactory.cc
  70. 2008-06-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  71. Filled up pieces based on the number of missing blocks, rather than
  72. simplay the number of piece * block length.
  73. * src/BtRequestFactory.h
  74. * src/DefaultBtInteractive.cc
  75. * src/DefaultBtInteractive.h
  76. * src/DefaultBtRequestFactory.cc
  77. * src/DefaultBtRequestFactory.h
  78. * src/Piece.cc
  79. * src/Piece.h
  80. * test/BitfieldManTest.cc
  81. * test/DefaultBtRequestFactoryTest.cc
  82. * test/MockBtRequestFactory.h
  83. 2008-06-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  84. Made _epEvents a member variable.
  85. * src/DownloadEngine.cc
  86. * src/DownloadEngine.h
  87. 2008-06-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  88. Cancel download if http redirect is bounded more than 20 times.
  89. * src/AbstractCommand.cc
  90. * src/HttpSkipResponseCommand.cc
  91. * src/Request.cc
  92. * src/Request.h
  93. * test/RequestTest.cc
  94. 2008-06-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  95. Fixed unhandled exception(removed keyword `new').
  96. * src/SocketCore.cc (initEPOLL)
  97. 2008-06-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  98. Removed visit(const MetaEntry*)
  99. * src/MetaEntryVisitor.h:
  100. Added visit(const Data*),visit(const Dictionary*),visit(const List*)
  101. and made them virtual.
  102. * src/BencodeVisitor.h
  103. * src/BencodeVisitor.cc
  104. 2008-06-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  105. Updated po files.
  106. * po/aria2c.pot
  107. * po/*.po
  108. * po/*.gmo
  109. 2008-06-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  110. Moved the call setWriteCheckSocket inside the previous clause to reduce
  111. the number of socket to watch out.
  112. * src/PeerInteractionCommand.cc
  113. 2008-06-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  114. When there is not enough space in disk when writing a chunk of data,
  115. aria2 now prints the message to the console to warn user and aborts
  116. its download. Not all downloads are canceled because some downloads
  117. may use another disk or partition. BUG#1640332
  118. * src/AbstractDiskWriter.cc
  119. * src/PeerAbstractCommand.cc
  120. * src/PeerAbstractCommand.h: Added onFailure() function for override.
  121. * src/PeerInteractionCommand.cc: In onFailure(), call RequestGroup::
  122. setHaltRequested(true) to cancel download.
  123. * src/PeerInteractionCommand.h
  124. 2008-06-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  125. Applied Ross's aria2-0.13.2+1-mingw-5.patch, which changes the type of
  126. socket from int to sock_t as sockets are unsigned in Windows.
  127. For AsyncNameResolver, DownloadEngine, I did additional modification
  128. for the portion of the code changed according to epoll support.
  129. I defined sock_t in a2netcompat.h to use sock_t without including
  130. SocketCore.h.
  131. * src/AsyncNameResolver.cc
  132. * src/AsyncNameResolver.h
  133. * src/DownloadEngine.cc
  134. * src/DownloadEngine.h
  135. * src/SocketCore.cc
  136. * src/SocketCore.h
  137. * src/a2netcompat.h
  138. 2008-06-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  139. Applied Ross's aria2-0.13.2+1-mingw-4.patch. With this change, all
  140. changes in the patch were applied.
  141. * test/DHTConnectionImplTest.cc: Fixed unit test error in MinGW.
  142. * test/DefaultPieceStorageTest.cc: Fixed unit test error in MinGW.
  143. * test/PeerMessageUtilTest.cc: Fixed unit test error in MinGW.
  144. 2008-06-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  145. Applied Ross's aria2-0.13.2+1-mingw-4.patch. In this change,
  146. a2io.h and common.h were modified.
  147. * src/a2io.h: Changed seek/stat/tell calls to use 64 bit versions in
  148. MinGW.
  149. * src/common.h: Changed off_t to 64 bit in MinGW.
  150. 2008-06-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  151. Applied Ross's aria2-0.13.2+1-mingw-4.patch. In this commit,
  152. only a2netcompat.h is modified.
  153. * src/a2netcompat.h: Removed unused getaddrinfo related #define
  154. directives.
  155. 2008-06-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  156. Applied Ross's aria2-0.13.2+1-mingw-4.patch. In this commit,
  157. only gai_strerror.h is modified.
  158. * src/gai_strerror.h: Fixed gai_strerror() function to report all
  159. winsock errors in MinGW.
  160. 2008-06-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  161. Applied Ross's aria2-0.13.2+1-mingw-4.patch. In this commit, only the
  162. follow sources are applied.
  163. * src/Platform.h: I removed HAVE_WINSOCK2_H directive from Platform.h.
  164. * src/Platform.cc: Moved common setup/teardown code to Platform class.
  165. I moved #endif // HAVE_WINSOCK2_H to the front of #include "DlAbortEx.h"
  166. I included locale.h from Platform.cc.
  167. * src/main.cc: Moved common setup/teardown code to Platform class.
  168. * test/AllTest.cc: Use Platform class.
  169. Set locale to C in AllTest.cc to prevent the messages to be localized.
  170. 2008-06-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  171. Applied Ross's aria2-0.13.2+1-mingw-3.patch.
  172. * test/HttpHeaderTest.cc: Casted to off_t where it should.
  173. * test/HttpRequestTest.cc: Casted to off_t where it should.
  174. 2008-06-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  175. Applied Ross's aria2-0.13.2+1-mingw.patch and
  176. aria2-0.13.2+1-mingw-2.patch.
  177. * src/ConsoleStatCalc.cc: Added HAVE_TERMIOUS_H directive for the
  178. systems which don't have termious.h. I moved the directive inside of
  179. if(isTTY) { ... clause so that line is wiped out without termious.h.
  180. I also removed HAVE_ASCTIME_R clause because asctime_r is provided
  181. anyway.
  182. * src/asctime_r.h
  183. * src/asctime_r.c: Added for the systems don't have asctime_r function.
  184. I added 2nd argument to the prototype declaration.
  185. * src/StringFormat.cc: Get rid of vasprintf.
  186. * src/getaddrinfo.h: Fixed constants.
  187. * configure.ac: Added the check for asctime_r function.
  188. * src/Makefile.am: Added conditional based on HAVE_ASCTIME_R
  189. 2008-06-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  190. Added writable test for Socket when the sending message is in progress.
  191. Usually the sending message is piece message. Without wriable check,
  192. upload latency is dropped to more than 1sec.
  193. * src/PeerInteractionCommand.cc
  194. 2008-06-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  195. Create only requested files and files which shares a piece with
  196. requested file in multi-torrent downloads. Directory structures are
  197. also created in the same rule.
  198. MultiDiskAdaptor::fileExists() now uses FileEntry instead of
  199. DiskWriterEntry as in the previous implementation.
  200. * src/MultiDiskWriter.cc
  201. * src/MultiFileAllocationIterator.cc
  202. * src/MultiFileAllocationIterator.h
  203. * test/MultiFileAllocationIteratorTest.cc
  204. 2008-06-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  205. Commented out -lprofiler
  206. * src/Makefile.am
  207. 2008-06-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  208. Bump up version number to 0.14.0b.
  209. * src/configure.ac
  210. 2008-06-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  211. Actively establish connection to peers in seeding, when peer cache
  212. is not full and max upload speed limit is not reached.
  213. * src/ActivePeerConnectionCommand.cc
  214. * src/ActivePeerConnectionCommand.h
  215. 2008-06-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  216. Always remove a peer from cache in DefaultPeerStorage::returnPeer(),
  217. to make room more fleshy, recently found peers.
  218. Peer::_badConditionStartTime is not used anymore. Consider to remove
  219. it.
  220. * src/DefaultPeerStorage.cc
  221. * test/DefaultPeerStorageTest.cc
  222. 2008-06-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  223. Returns cached data only when the previous receiveHandshake() is called
  224. with peek = true.
  225. * src/PeerConnection.cc (receiveHandshake)
  226. * src/PeerConnection.h (receiveHandshake)
  227. 2008-06-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  228. Changed default value of -s option from 1 to 5.
  229. Also max value of -s option is changed from 5 to 16.
  230. * src/HelpItemFactory.cc
  231. * src/OptionHandlerFactory.cc
  232. * src/option_processing.cc
  233. * src/usage_text.h
  234. 2008-06-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  235. Changed -s options behavior. Now it means the number of connections
  236. made simultaneously in each http/ftp download.
  237. If 1 URL is specified, the behavior is the same with old implementation.
  238. If -s N is given and more than N URLs are specified, first N URLs are
  239. used and remaining URLs are used for backup. If less than N URLs are
  240. specified, some of URLs are used more than once so that totally N
  241. connections are made simultaneously.
  242. * src/main.cc
  243. 2008-06-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  244. Included missing iosfwd or ostream header.
  245. * src/RequestGroupMan.cc
  246. * src/TaggedItem.cc
  247. * src/TaggedItem.h
  248. * src/Util.cc
  249. 2008-06-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  250. * src/HttpHeaderProcessor.cc: Rewritten using std::string as a buffer.
  251. * src/HttpHeaderProcessor.h: Rewritten using std::string as a buffer.
  252. * src/HttpConnection.cc: Included missing sstream.
  253. 2008-06-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  254. Added --bt-max-open-files option.
  255. * src/DefaultPieceStorage.cc
  256. * src/HelpItemFactory.cc
  257. * src/MultiDiskAdaptor.cc
  258. * src/MultiDiskAdaptor.h
  259. * src/OptionHandlerFactory.cc
  260. * src/option_processing.cc
  261. * src/prefs.cc
  262. * src/prefs.h
  263. * src/usage_text.h
  264. 2008-06-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  265. Fixed the bug that aria2 aborts when a path to a directory is given
  266. in command-line.
  267. * src/ProtocolDetector.cc
  268. 2008-06-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  269. Limited the number files opened in each BitTorrent download. The default
  270. value is 100. The option to change this value will be added.
  271. * src/MultiDiskAdaptor.cc
  272. * src/MultiDiskAdaptor.h
  273. * src/MultiFileAllocationIterator.cc
  274. 2008-06-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  275. Fixed the bug that HTTP downloads don't start with old libraries.
  276. * src/HttpHeaderProcessor.cc
  277. 2008-06-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  278. Use empty() instead of size() > 0.
  279. * src/HttpConnection.cc
  280. 2008-06-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  281. Drop connection if the incoming peer ID is the same with localhost's
  282. one. The previous implementation drops connection when incoming peer's
  283. IP address is the same with localhost's one.
  284. * src/PeerListenCommand.cc
  285. * src/DefaultBtInteractive.cc
  286. 2008-06-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  287. Returns cached data without checking whether socket is readable
  288. if the cache is available.
  289. * src/PeerConnection.cc (receiveHandshake)
  290. 2008-06-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  291. Included stdint.h
  292. * src/common.h
  293. 2008-06-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  294. Removed duplicate HAVE_GETTIMEOFDAY
  295. * src/Makefile.am
  296. * src/Makefile.in
  297. 2008-06-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  298. Use interval as a minInterval when minInterval is not supplied.
  299. * src/DefaultBtAnnounce.cc
  300. 2008-06-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  301. Made DEFAULT_ANNOUNCE_INTERVAL 120, so that if first tracker request
  302. attempt is failed, then 2nd attempt get kicked out more quickly.
  303. And it is now static const member of DefaultBtAnnounce.
  304. * src/DefaultBtAnnounce.h
  305. 2008-06-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  306. Renamed BtRuntime::lessThanMinPeers() and BtRuntime::lessThanEqMinPeers.
  307. Made MAX_PEERS and MIN_PEERS static const members of BtRuntime.
  308. * src/ActivePeerConnectionCommand.cc
  309. * src/BtConstants.h
  310. * src/BtRuntime.h
  311. * src/DHTGetPeersCommand.cc
  312. * src/DefaultBtAnnounce.cc
  313. * src/DefaultPeerStorage.cc: Calculate maxPeerListSize based on
  314. BtRuntime::MAX_PEERS.
  315. * src/DefaultPeerStorage.h
  316. * src/InitiatorMSEHandshakeCommand.cc
  317. * src/PeerInitiateConnectionCommand.cc
  318. * src/PeerInteractionCommand.cc
  319. * src/PeerReceiveHandshakeCommand.cc
  320. * src/TrackerWatcherCommand.cc
  321. 2008-06-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  322. Always Connect to _numNewConnection
  323. * src/ActivePeerConnectionCommand.cc
  324. 2008-06-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  325. Made `begin' unsigned int.
  326. * src/GrowSegment.h
  327. * src/Piece.cc
  328. * src/Piece.h
  329. * src/PiecedSegment.cc
  330. * src/PiecedSegment.h
  331. * src/Segment.h
  332. 2008-06-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  333. Calculate piece hash when data is arrived if the data is arrived in
  334. order. This removes additional read operation for hash calculation.
  335. If the data is arrived in out of order, the hash is calucated when the
  336. piece is completed. This is the same behavior as the old implementation.
  337. * src/BtPieceMessage.cc
  338. * src/DefaultBtProgressInfoFile.cc
  339. * src/DefaultPieceStorage.cc
  340. * src/DownloadCommand.cc
  341. * src/DownloadCommand.h
  342. * src/DownloadEngine.cc
  343. * src/GrowSegment.cc
  344. * src/GrowSegment.h
  345. * src/Piece.cc
  346. * src/Piece.h
  347. * src/PiecedSegment.cc
  348. * src/PiecedSegment.h
  349. * src/Segment.h
  350. * test/PieceTest.cc
  351. 2008-06-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  352. Try to keep the ordering of outgoing piece message.
  353. * src/DefaultBtMessageDispatcher.cc
  354. (DefaultBtMessageDispatcher::sendMessages)
  355. 2008-06-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  356. Fixed busy loop when error/hup epoll events occur.
  357. * src/AbstractCommand.cc
  358. * src/PeerAbstractCommand.cc
  359. 2008-06-04 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  360. Added --bt-request-peer-speed-limit option, which was a constant
  361. SLOW_SPEED_THRESHOLD.
  362. * src/ActivePeerConnectionCommand.cc
  363. * src/ActivePeerConnectionCommand.h
  364. * src/BtConstants.h
  365. * src/HelpItemFactory.cc
  366. * src/OptionHandlerFactory.cc
  367. * src/PeerReceiveHandshakeCommand.cc
  368. * src/option_processing.cc
  369. * src/prefs.cc
  370. * src/prefs.h
  371. * src/usage_text.h
  372. 2008-06-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  373. Removed repeated call of getTopDirPath(). Instead, call it once and
  374. cache the result.
  375. * src/MultiDiskAdaptor.cc
  376. * src/MultiDiskAdaptor.h
  377. (mkdir, openFile, initAndOpenFile, openExistingFile)
  378. 2008-06-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  379. Fixed compile error on debian etch.
  380. The libc6 shipped with debian etch doesn't define ULLONG_MAX properly
  381. even if _GNU_SOURCE is defined. So define ULLONG_MAX in case when
  382. it is undefined.
  383. * src/Util.cc (ULLONG_MAX)
  384. 2008-05-31 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  385. Added epoll support. Use epoll if it is available. If not, use select.
  386. When async dns is enabled in compile time, epoll support is enabled
  387. only when aria2 is built with c-ares. This condition statement is
  388. defined in a2io.h.
  389. Currently aria2 supports both c-ares and ares, but ares is maintained
  390. for quite a while and debian already has c-ares package, ares support
  391. will be dropped in the future version.
  392. * configure.ac
  393. * src/AbstractCommand.cc
  394. * src/AsyncNameResolver.cc
  395. * src/AsyncNameResolver.h
  396. * src/Command.cc
  397. * src/Command.h
  398. * src/DownloadEngine.cc
  399. * src/DownloadEngine.h
  400. * src/PeerAbstractCommand.cc
  401. * src/SocketCore.cc
  402. * src/SocketCore.h
  403. * src/a2io.h
  404. 2008-05-31 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  405. * test/MetalinkEntryTest.cc: Added missing `defined' keyword to #if
  406. directive.
  407. 2008-05-31 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  408. Do not do write operation to /dev/null file.
  409. * src/LogFactory.cc
  410. * src/SimpleLogger.cc
  411. Replaced vasprintf with vsnprintf
  412. * src/SimpleLogger.cc (SimpleLogger::writeLog)
  413. 2008-05-31 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  414. * src/BtRequestMessage.cc
  415. (BtRequestMessage::onQueue): Given piece to RequestSlot. This is a fix
  416. for segmentation fault caused by previous commit.
  417. 2008-05-31 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  418. Reduced the usage of gettimeofday().
  419. * src/DefaultBtMessageDispatcher.cc
  420. (DefaultBtMessageDispatcher::checkRequestSlotAndDoNecessaryThing)
  421. (class FindStaleRequestSlot, class ProcessStaleRequestSlot)
  422. * src/RequestSlot.cc
  423. * src/RequestSlot.h
  424. (RequestSlot::isTimeout)
  425. Made RequestSlot have a reference to Piece object to avoid find
  426. Piece repeatedly.
  427. * src/DefaultBtMessageDispatcher.cc
  428. (class FindStaleRequestSlot, class ProcessStaleRequestSlot)
  429. * src/RequestSlot.cc
  430. * src/RequestSlot.h
  431. (RequestSlot::getPiece)
  432. * test/DefaultBtMessageDispatcherTest.cc
  433. 2008-05-31 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  434. * src/TimeA2.cc
  435. * src/TimeA2.h
  436. (Time::difference): New function.
  437. (Time::elapsed): Done optimization.
  438. 2008-05-31 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  439. * src/HelpItemFactory.cc: Added missing `defined' keyword to #if
  440. directive.
  441. 2008-05-31 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  442. * src/option_processing.cc: Added missing `defined' keyword to #if
  443. directive.
  444. 2008-05-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  445. Bump up version number to 0.13.2+1
  446. * src/configure.ac
  447. 2008-05-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  448. Refactored broken outstanding piece handling.
  449. * src/DefaultPieceStorage.cc
  450. * src/DefaultPieceStorage.h
  451. * src/Piece.cc
  452. * src/Piece.h
  453. 2008-05-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  454. Fixed compile error on Mac OS X 10.3.9. This error was caused by the
  455. name collision of static variable and predefined macro.
  456. * src/BtContext.cc
  457. * src/BtContext.h
  458. * src/CookieBoxFactory.cc
  459. * src/CookieBoxFactory.h
  460. * src/CookieParser.cc
  461. * src/CookieParser.h
  462. * src/DefaultBtContext.cc
  463. 2008-05-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  464. * src/RequestGroup.cc
  465. (RequestGroup::createInitialCommand): Use empty() instead of size().
  466. 2008-05-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  467. * Release 0.13.2
  468. 2008-05-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  469. Updated fr.po(thanks to Sebastien) and ja.po. ThanksDone make update-po
  470. * po/fr.po
  471. * po/ja.po
  472. * po/aria2c.pot
  473. * po/*.po
  474. * po/*.gmo
  475. 2008-05-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  476. Bump up version number to 0.13.2
  477. * src/configure.ac
  478. 2008-05-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  479. Refactord.
  480. * src/RequestGroupMan.cc
  481. (removeStoppedGroup)
  482. (fillRequestGroupFromReserver)
  483. 2008-05-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  484. Fixed compile error on Ubuntu.
  485. * src/BtPieceMessage.cc
  486. * src/MessageDigestHelper.cc
  487. * src/Util.cc
  488. 2008-05-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  489. Fixed compile error when configured with --disable-bittorrent
  490. * test/DownloadHandlerFactoryTest.cc
  491. 2008-05-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  492. Done make update-po
  493. * po/aria2c.pot
  494. * po/*.po
  495. * po/*.gmo
  496. 2008-05-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  497. Bump up version number to 0.13.2rc.
  498. * src/configure.ac
  499. 2008-05-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  500. Made option name bold. Updated SYNOPSIS to make it more readable.
  501. * doc/aria2c.1.txt
  502. * doc/aria2c.1
  503. * doc/aria2c.1.html
  504. * src/version_usage.cc
  505. 2008-05-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  506. Refactored. Use std::string instead of size and char*.
  507. * Data.cc
  508. * Data.h
  509. * test/Data.cc
  510. 2008-05-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  511. Added trimSelf(). Rewritten trim() to use trimSelf().
  512. * Util.cc
  513. * Util.h
  514. 2008-05-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  515. * src/ChunkChecksum.h (getChecksum): Return const reference.
  516. 2008-05-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  517. Fixed compile error when configured with --disable-metalink.
  518. Also moved test/DownloadHandlerFactoryTest.cc to SRC in Makefile.am.
  519. * test/FeatureConfigTest.cc
  520. * test/DownloadHandlerFactoryTest.cc
  521. 2008-05-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  522. Fixed compile error when configured with --without-gnutls
  523. --without-openssl
  524. * src/main.cc
  525. * test/DefaultBtProgressInfoFileTest.cc
  526. * test/SegmentManTest.cc
  527. 2008-05-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  528. Fixed compile error with OpenSSL.
  529. * src/IteratableChunkChecksumValidator.cc
  530. * src/LibsslDHKeyExchange.h
  531. * src/MessageDigestHelper.cc
  532. 2008-05-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  533. Revert the default value of --max-concurrent-downloads to 5.
  534. Revert the default value of --metalink-servers to 5.
  535. Man pages was also updated.
  536. * src/option_processing.cc
  537. * doc/aria2c.1.txt
  538. * doc/aria2c.1.html
  539. * doc/aria2c.1
  540. 2008-05-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  541. Returns const reference:
  542. DownloadContext::getPieceHash, DownloadContext::getName,
  543. DownloadContext::getPieceHashAlgo, DownloadContext::getDir,
  544. BtContext::getInfoHashAsString,
  545. * src/BtContext.h
  546. * src/DefaultBtContext.cc
  547. * src/DefaultBtContext.h
  548. * src/DownloadContext.h
  549. * src/SingleFileDownloadContext.h
  550. * test/MockBtContext.h
  551. 2008-05-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  552. * src/RequestGroup.h (getDir): Removed.
  553. 2008-05-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  554. Returns const reference. The internal urlencode function was optimized
  555. a little bit.
  556. * src/Request.cc
  557. * src/Request.h
  558. * src/HttpRequest.cc
  559. * src/HttpRequest.h
  560. 2008-05-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  561. Defined option name and possible values as std::string to reduce
  562. temporary string object creation in runtime.
  563. * src/HelpItemFactory.cc
  564. * src/LogFactory.cc
  565. * src/Option.cc
  566. * src/OptionHandlerFactory.cc
  567. * src/option_processing.cc
  568. * src/prefs.cc
  569. * src/prefs.h
  570. 2008-05-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  571. Return const reference.
  572. * src/DownloadHandlerConstants.cc
  573. * src/DownloadHandlerConstants.h
  574. (getMetalinkExtensions)
  575. (getMetalinkContentTypes)
  576. (getBtExtensions)
  577. (getBtContentTypes)
  578. 2008-05-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  579. * src/HttpHeader.cc (get): Rewritten.
  580. 2008-05-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  581. Make HttpHeader::getFirst(...) return const reference.
  582. * src/HttpHeader.cc
  583. * src/HttpHeader.h
  584. 2008-05-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  585. Use Option::getAsBool(...) instead of Option::get(...) and compare
  586. it with V_TRUE.
  587. * src/DefaultPieceStorage.cc
  588. * src/DownloadCommand.cc
  589. * src/FtpNegotiationCommand.cc
  590. * src/HttpRequest.cc
  591. * src/InitiateConnectionCommand.cc
  592. * src/RequestGroup.cc
  593. 2008-05-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  594. Made Option::get(...) return const reference of std::string.
  595. * src/Option.cc
  596. * src/Option.h
  597. 2008-05-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  598. Replaced std:copy with insert.
  599. * src/DefaultBtMessageDispatcher.cc
  600. * src/DefaultPieceStorage.cc
  601. * src/DownloadEngineFactory.cc
  602. * src/RequestGroup.cc
  603. 2008-05-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  604. Included SocketCore.h to fix compiler warning.
  605. * src/InitiateConnectionCommand.cc
  606. 2008-05-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  607. Put piece selection strategy algorithm to RarestPieceSelector class,
  608. Added a switch to choose whether randomized selection so that unit
  609. tests emit same results in, possibly, win32.
  610. * src/DefaultPieceStorage.cc
  611. * src/DefaultPieceStorage.h
  612. * src/RarestPieceSelector.cc
  613. * src/RarestPieceSelector.h
  614. * test/DefaultPieceStorageTest.cc
  615. * test/RarestPieceSelectorTest.cc
  616. 2008-05-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  617. Don't pool connection if HTTP proxy is enabled.
  618. * src/FtpFinishDownloadCommand.cc
  619. * src/FtpNegotiationCommand.cc
  620. * src/HttpSkipResponseCommand.cc
  621. 2008-05-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  622. Don't add closed socket to DownloadEngine::addSocketForReadCheck()
  623. * src/AbstractCommand.cc
  624. * src/AbstractCommand.h
  625. * src/ActivePeerConnectionCommand.cc
  626. * src/FtpInitiateConnectionCommand.cc
  627. * src/HttpInitiateConnectionCommand.cc
  628. * src/InitiateConnectionCommandFactory.cc
  629. * src/PeerAbstractCommand.cc
  630. * src/PeerAbstractCommand.h
  631. * src/PeerInitiateConnectionCommand.cc
  632. * src/TrackerWatcherCommand.cc
  633. 2008-05-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  634. Sort RequestSlot in ascending order and manipulate them using
  635. lower_bound.
  636. * src/DefaultBtMessageDispatcher.cc
  637. * src/DefaultBtMessageDispatcher.h
  638. (getMessageQueue): Added const qualifier.
  639. (getRequestSlots): Added const qualifier.
  640. (sendMessages): Use empty() instead of size().
  641. (doCancelSendingPieceAction): Use HandleEvent object.
  642. (doAbortOutstandingRequestAction): Rewritten.
  643. (doChokedAction): Rewritten.
  644. (checkRequestSlotAndDoNecessaryThing): Rewritten.
  645. (isOutstandingRequest): Rewritten.
  646. (getOutstandingRequest): Rewritten.
  647. (removeOutstandingRequest): Rewritten.
  648. (addOutstandingRequest): Rewritten.
  649. * src/RequestSlot.cc
  650. * src/RequestSlot.h
  651. (operator=): Rewritten.
  652. (operator!=): New function.
  653. (operator<): New function.
  654. 2008-05-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  655. * src/DefaultBtRequestFactory.cc
  656. (doChokedAction): Rewritten.
  657. (removeCompletedPiece): Rewritten.
  658. (removeTargetPiece): Rewritten.
  659. (createRequestMessages): Added the debug log.
  660. (createRequestMessagesOnEndGame: Added the debug log.
  661. 2008-05-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  662. Added the debug log message.
  663. * src/BtPieceMessage.cc (doReceivedAction)
  664. 2008-05-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  665. Sorted DHTPeerAnnounceEntry in a ascending order of info hash and
  666. used lower_bound to process them rather than linear search.
  667. * src/DHTPeerAnnounceStorage.cc
  668. 2008-05-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  669. Call subtractPieceStats from ~PeerInteractionCommand only when the
  670. peer has at least one completed piece.
  671. * src/Peer.cc
  672. * src/Peer.h
  673. * src/PeerInteractionCommand.cc
  674. * src/PeerSessionResource.cc
  675. * src/PeerSessionResource.h
  676. 2008-05-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  677. Removed unnecessary sorting
  678. * src/DefaultPieceStorage (DefaultPieceStorage)
  679. 2008-05-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  680. Rewritten the portion of the code that mangaes allowed fast indexes.
  681. * src/PeerSessionResource.cc
  682. * src/PeerSessionResource.h
  683. 2008-05-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  684. Removed the invalid string including '\r' from ru.po and
  685. did make update-po.
  686. 2008-05-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  687. Added --log-level and --summary-interval to man page.
  688. * doc/aria2c.1.txt
  689. * doc/aria2c.1.html
  690. * doc/aria2c.1
  691. 2008-05-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  692. Added --log-level option to specify log level. Log messages under
  693. the specified level are not output. Default value is `debug'.
  694. * src/HelpItemFactory.cc
  695. * src/LogFactory.cc
  696. * src/LogFactory.h
  697. * src/Logger.h
  698. * src/OptionHandlerFactory.cc
  699. * src/SimpleLogger.cc
  700. * src/SimpleLogger.h
  701. * src/main.cc
  702. * src/option_processing.cc
  703. * src/prefs.h
  704. * src/usage_text.h
  705. 2008-05-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  706. Print download progress summary of all parallel downloads in specified
  707. interval, default 60 secs. While aria2 could download several files
  708. in parallel (see -j option), it displayed just first download progress,
  709. and the other downloads are hidden from the users. This new feature
  710. prints all downloads currently in-progress to the console so that you
  711. can check the status of all downloads. The interval can be adjusted
  712. by --summary-interval option.
  713. The progress readout is now cut so that all fits in the one line of
  714. console.
  715. * src/ConsoleStatCalc.cc
  716. * src/ConsoleStatCalc.h
  717. * src/HelpItemFactory.cc
  718. * src/OptionHandlerFactory.cc
  719. * src/RequestGroupMan.cc
  720. * src/RequestGroupMan.h
  721. * src/main.cc
  722. * src/option_processing.cc
  723. * src/prefs.h
  724. * src/usage_text.h
  725. 2008-05-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  726. Call updateFdSet() to initialize rfdset, wfdset fdmax.
  727. * src/DownloadEngine.cc (DownloadEngine)
  728. 2008-05-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  729. Use free() to deallocate memory for _buffer if HAVE_POSIX_MEMALIGN is
  730. defined.
  731. * src/SingleFileAllocationIterator.cc (~SingleFileAllocationIterator)
  732. 2008-05-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  733. Use erase+lower_bound+insert instead of sort.
  734. * src/DefaultPieceStorage.cc (addPieceStats)
  735. 2008-05-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  736. Use A2STR::SHARP_C and A2STR::EQUAL_C.
  737. * src/A2STR.cc
  738. * src/A2STR.h
  739. * src/OptionParser.cc (parse)
  740. 2008-05-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  741. Defined fake filename `[tracker.announce]' as static const std::string.
  742. * src/TrackerWatcherCommand.cc (createRequestGroup)
  743. 2008-05-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  744. Defined default filename `index.html' as static const std::string
  745. * src/SingleFileDownloadContext.cc
  746. * src/SingleFileDownloadContext.h
  747. 2008-05-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  748. Defined "[MEMORY]" as static const std::string.
  749. * src/MemoryBufferPreDownloadHandler.cc (execute)
  750. 2008-05-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  751. Defined control file's version number as static const std::string.
  752. * src/DefaultBtProgressInfoFile.cc
  753. * src/DefaultBtProgressInfoFile.h
  754. 2008-05-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  755. Use Request::METHOD_GET
  756. * src/RequestGroup.cc (createNextCommandWithAdj)
  757. 2008-05-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  758. Defined "OK", "ERR", "INPR" as static const std::string
  759. * src/RequestGroupMan.cc (showDownloadResults)
  760. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  761. Defined default client used in extended handshake as static const
  762. std::string
  763. * src/DefaultBtInteractive.cc (addHandshakeExtendedMessageToQueue)
  764. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  765. Defined AUTH_HEADER, PROXY_AUTH_HEADER as static const std::string
  766. * src/HttpConnection.cc (eraseConfidentialInfo)
  767. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  768. Defined default ftp user and password as static const std::string
  769. * src/AuthConfigFactory.cc
  770. * src/AuthConfigFactory.h
  771. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  772. Defined strings used in netrc as static const std::string
  773. * src/Netrc.cc
  774. * src/Netrc.h
  775. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  776. Defined HTTP status as static const std::string
  777. * src/AbstractProxyResponseCommand.cc
  778. * src/HttpHeader.cc
  779. * src/HttpHeader.h
  780. * src/HttpResponse.cc
  781. * src/HttpResponseCommand.cc
  782. * src/HttpSkipResponseCommand.cc
  783. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  784. Defined "\r\n", "A", "I" as static const std::string
  785. * src/A2STR.cc
  786. * src/A2STR.h
  787. * src/FtpConnection.cc
  788. * src/FtpConnection.h
  789. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  790. Added COLON_C(".") and used it in Request::parseUrl()
  791. * src/A2STR.cc
  792. * src/A2STR.h
  793. * src/Request.cc (parseUrl)
  794. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  795. Changed the type of padName from `const std::string&' to `const char*'.
  796. * src/MSEHandshake.cc (verifyPadLength)
  797. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  798. Defined "sha1" as static const std::string.
  799. * src/MetalinkParserController.cc
  800. * src/MetalinkParserController.h
  801. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  802. Defined message digest algorithm name as static const std::string
  803. * src/DHTTokenTracker.cc
  804. * src/DHTUtil.cc
  805. * src/DefaultBtContext.cc
  806. * src/MSEHandshake.cc
  807. * src/MessageDigestHelper.cc
  808. * src/Peer.cc
  809. * src/messageDigest.cc
  810. * src/messageDigest.h
  811. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  812. Made string literals used in SAX parser static const std::string.
  813. * src/FileMetalinkParserState.cc
  814. * src/FileMetalinkParserState.h
  815. * src/FilesMetalinkParserState.cc
  816. * src/FilesMetalinkParserState.h
  817. * src/InitialMetalinkParserState.cc
  818. * src/InitialMetalinkParserState.h
  819. * src/MetalinkMetalinkParserState.cc
  820. * src/MetalinkMetalinkParserState.h
  821. * src/PiecesMetalinkParserState.cc
  822. * src/PiecesMetalinkParserState.h
  823. * src/ResourcesMetalinkParserState.cc
  824. * src/ResourcesMetalinkParserState.h
  825. * src/VerificationMetalinkParserState.cc
  826. * src/VerificationMetalinkParserState.h
  827. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  828. Use A2STR::SLASH_C, A2STR::DOT_C instead of "/", "." respectively.
  829. * src/A2STR.cc
  830. * src/A2STR.h
  831. * src/File.cc
  832. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  833. Defined static const std::string IP("ip"), PORT("port") and use them
  834. instead of string literals.
  835. * src/DefaultPeerListProcessor.cc
  836. * src/DefaultPeerListProcessor.h
  837. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  838. Made string literals for torrent file processing static const
  839. std::string.
  840. * src/BtContext.cc
  841. * src/BtContext.h
  842. * src/DefaultBtContext.cc
  843. * src/DefaultBtContext.h
  844. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  845. Made string literal for tracker response static const std::string
  846. * src/BtAnnounce.cc
  847. * src/BtAnnounce.h
  848. * src/DefaultBtAnnounce.cc
  849. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  850. Use DHTMessage::T instead of "t".
  851. * src/DHTMessageTracker.cc (messageArrived)
  852. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  853. Made keyName static const. Made trimmed charset static const
  854. std::string.
  855. * src/Util.cc (getContentDispositionFilename)
  856. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  857. Made USER_AGENT const. Made "/" static const std::string.
  858. * src/A2STR.cc
  859. * src/A2STR.h
  860. * src/HttpRequest.cc
  861. * src/HttpRequest.h
  862. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  863. Made string listeral to static const std::string:
  864. "Content-Range", "Content-Length"
  865. * src/HttpHeader.cc
  866. * src/HttpHeader.h
  867. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  868. Made string listeral to static const std::string.
  869. * src/HttpConnection.cc
  870. * src/HttpHeader.cc
  871. * src/HttpHeader.h
  872. * src/HttpResponse.cc
  873. 2008-05-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  874. Made string listeral to static const std::string.
  875. * src/A2STR.cc
  876. * src/A2STR.h
  877. * src/SimpleLogger.cc
  878. * src/SimpleLogger.h
  879. 2008-05-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  880. Made string literal to static const std::string.
  881. Rewritten CookieParser::setField.
  882. * src/A2STR.cc
  883. * src/A2STR.h
  884. * src/CookieBoxFactory.cc
  885. * src/CookieBoxFactory.h
  886. * src/CookieParser.cc
  887. * src/CookieParser.h
  888. 2008-05-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  889. Made string literal to static const std::string
  890. * src/DHTAbstractMessage.cc
  891. * src/DHTAnnouncePeerMessage.cc
  892. * src/DHTAnnouncePeerMessage.h
  893. * src/DHTAnnouncePeerReplyMessage.cc
  894. * src/DHTAnnouncePeerReplyMessage.h
  895. * src/DHTFindNodeMessage.cc
  896. * src/DHTFindNodeMessage.h
  897. * src/DHTFindNodeReplyMessage.cc
  898. * src/DHTFindNodeReplyMessage.h
  899. * src/DHTGetPeersMessage.cc
  900. * src/DHTGetPeersMessage.h
  901. * src/DHTGetPeersReplyMessage.cc
  902. * src/DHTGetPeersReplyMessage.h
  903. * src/DHTMessage.cc
  904. * src/DHTMessage.h
  905. * src/DHTMessageFactoryImpl.cc
  906. * src/DHTMessageReceiver.cc
  907. * src/DHTPingMessage.cc
  908. * src/DHTPingMessage.h
  909. * src/DHTPingReplyMessage.cc
  910. * src/DHTPingReplyMessage.h
  911. * src/DHTQueryMessage.cc
  912. * src/DHTQueryMessage.h
  913. * src/DHTResponseMessage.cc
  914. * src/DHTResponseMessage.h
  915. * src/DHTUnknownMessage.cc
  916. * src/DHTUnknownMessage.h
  917. 2008-05-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  918. Made string literal to static const std::string
  919. * src/BtChokeMessage.cc (toString)
  920. * src/BtHaveAllMessage.cc (toString)
  921. * src/BtHaveNoneMessage.cc (toString)
  922. * src/BtInterestedMessage.cc (toString)
  923. * src/BtNotInterestedMessage.cc (toString)
  924. * src/BtUnchokeMessage.cc (toString)
  925. 2008-05-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  926. Replaced "" with static const variable A2STR::NIL.
  927. Replaced string comparison against "" with std::string::empty().
  928. Added PROTO_* to Request class and use them as a protocol string
  929. constant.
  930. Made "started", "stopped", "completed" static const variable in
  931. AnnounceList class.
  932. 2008-05-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  933. Updated translations. Great thanks to translators.
  934. * po/ca.po
  935. * po/de.po
  936. * po/fr.po
  937. * po/it.po
  938. * po/ja.po
  939. * po/ru.po
  940. * po/zh_CN.po
  941. 2008-05-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  942. Updated man page; categorized options and fixed typo.
  943. * doc/aria2c.1.txt
  944. * doc/aria2c.1.html
  945. * doc/aria2c.1
  946. 2008-05-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  947. Removed const ref
  948. * src/MetalinkEntry.cc (AddProtocolPreference)
  949. * src/RequestGroup.cc (FindServerHostByHostname)
  950. 2008-05-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  951. Rewritten Accept-Features handling.
  952. * src/HttpRequestCommand.cc (createHttpRequest)
  953. * src/a2functional.h
  954. 2008-05-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  955. Changed method signature:
  956. DHTAbstractNodeLookupTask::toEntries
  957. * src/DHTAbstractNodeLookupTask.cc
  958. * src/DHTAbstractNodeLookupTask.h
  959. 2008-05-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  960. Changed method signature:
  961. BtContext::computeFastSet, DefaultBtContext::extractUrlList
  962. * src/BtContext.h
  963. * src/DefaultBtContext.cc
  964. * src/DefaultBtContext.h
  965. * src/DefaultBtInteractive.cc
  966. * test/DefaultBtContextTest.cc
  967. * test/MockBtContext.h
  968. 2008-05-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  969. Changed method signature:
  970. MultiFileAllocationIterator::makeDiskWriterEntries
  971. * src/MultiFileAllocationIterator.cc
  972. * src/MultiFileAllocationIterator.h
  973. 2008-05-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  974. Changed method sinature:
  975. MetalinkEntry::toFileEntry,
  976. MetalinkHelper::query, MetalinkHelper::parseAndQuery,
  977. Metalinker::queryEntry
  978. * src/Metalink2RequestGroup.cc
  979. * src/MetalinkEntry.cc
  980. * src/MetalinkEntry.h
  981. * src/MetalinkHelper.cc
  982. * src/MetalinkHelper.h
  983. * src/Metalinker.cc
  984. * src/Metalinker.h
  985. * src/main.cc
  986. * test/MetalinkHelperTest.cc
  987. * test/MetalinkerTest.cc
  988. 2008-05-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  989. Changed method sinature:
  990. RequestGroup::getURIs
  991. * src/RequestGroup.cc
  992. * src/RequestGroup.h
  993. * test/Metalink2RequestGroupTest.cc
  994. 2008-05-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  995. Changed method signature:
  996. PeerListProcessor::extractPeer
  997. * src/CompactPeerListProcessor.cc
  998. * src/CompactPeerListProcessor.h
  999. * src/DefaultBtAnnounce.cc
  1000. * src/DefaultPeerListProcessor.cc
  1001. * src/DefaultPeerListProcessor.h
  1002. * src/DelegatingPeerListProcessor.cc
  1003. * src/DelegatingPeerListProcessor.h
  1004. * src/PeerListProcessor.h
  1005. * src/UTPexExtensionMessage.cc
  1006. * test/DefaultPeerListProcessorTest.cc
  1007. 2008-05-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1008. Changed method signature:
  1009. BtRequestFactory::createRequestMessages,
  1010. BtRequestFactory::createRequestMessagesOnEndGame
  1011. * src/BtRequestFactory.h
  1012. * src/DefaultBtInteractive.cc
  1013. * src/DefaultBtRequestFactory.cc
  1014. * src/DefaultBtRequestFactory.h
  1015. * test/DefaultBtRequestFactoryTest.cc
  1016. * test/MockBtRequestFactory.h
  1017. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1018. Changed method signature:
  1019. PieceStorage::getInFlightPieces
  1020. * src/DefaultBtProgressInfoFile.cc
  1021. * src/DefaultPieceStorage.cc
  1022. * src/DefaultPieceStorage.h
  1023. * src/PieceStorage.h
  1024. * src/UnknownLengthPieceStorage.cc
  1025. * src/UnknownLengthPieceStorage.h
  1026. * test/DefaultBtProgressInfoFileTest.cc
  1027. * test/MockPieceStorage.h
  1028. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1029. Changed method signature:
  1030. PostDownloadHandler::getNextRequestGroups
  1031. Metalink2RequestGroup::generate
  1032. RequestGroup::postDownloadProcessing
  1033. * src/BtPostDownloadHandler.cc
  1034. * src/BtPostDownloadHandler.h
  1035. * src/Metalink2RequestGroup.cc
  1036. * src/Metalink2RequestGroup.h
  1037. * src/MetalinkPostDownloadHandler.cc
  1038. * src/MetalinkPostDownloadHandler.h
  1039. * src/PostDownloadHandler.h
  1040. * src/RequestGroup.cc
  1041. * src/RequestGroup.h
  1042. * src/RequestGroupMan.cc
  1043. * src/main.cc
  1044. * test/BtPostDownloadHandlerTest.cc
  1045. * test/Metalink2RequestGroupTest.cc
  1046. * test/MetalinkPostDownloadHandlerTest.cc
  1047. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1048. Rewritten AccRequestGroup
  1049. * src/main.cc
  1050. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1051. Rewritten.
  1052. * src/TaggedItem.cc (toTagString)
  1053. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1054. Rewritten Accept-Features handling.
  1055. * src/HttpRequestCommand.cc (createHttpRequest)
  1056. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1057. Rewritten accept types handling.
  1058. * HttpRequest.cc (createRequest)
  1059. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1060. Rewritten
  1061. * src/FeatureConfig.cc (featureSummary)
  1062. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1063. Changed method signature:
  1064. PeerStorage::getActivePeers
  1065. * src/DHTPeerAnnounceEntry.cc
  1066. * src/DefaultPeerStorage.cc
  1067. * src/DefaultPeerStorage.h
  1068. * src/PeerStorage.h
  1069. * test/DefaultPeerStorageTest.cc
  1070. * test/MockPeerStorage.h
  1071. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1072. Changed method signature:
  1073. DHTPeerAnnounceStorage::getPeers,
  1074. DHTPeerAnnounceEntry::getPeers
  1075. * src/DHTGetPeersMessage.cc
  1076. * src/DHTPeerAnnounceEntry.cc
  1077. * src/DHTPeerAnnounceEntry.h
  1078. * src/DHTPeerAnnounceStorage.cc
  1079. * src/DHTPeerAnnounceStorage.h
  1080. * test/DHTAnnouncePeerMessageTest.cc
  1081. * test/DHTPeerAnnounceEntryTest.cc
  1082. * test/DHTPeerAnnounceStorageTest.cc
  1083. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1084. Changed method signature:
  1085. NameResolver::resolve
  1086. * src/DHTEntryPointNameResolveCommand.cc
  1087. * src/InitiateConnectionCommand.cc
  1088. * src/NameResolver.cc
  1089. * src/NameResolver.h
  1090. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1091. Changed method signature:
  1092. PieceStorage::getAdvertisedPieceIndexes
  1093. * src/DefaultBtInteractive.cc
  1094. * src/DefaultPieceStorage.cc
  1095. * src/DefaultPieceStorage.h
  1096. * src/PieceStorage.h
  1097. * src/UnknownLengthPieceStorage.h
  1098. * test/MockPieceStorage.h
  1099. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1100. Changed method signature:
  1101. SegmentMan::getInFlightSegment
  1102. * src/AbstractCommand.cc
  1103. * src/SegmentMan.cc
  1104. * src/SegmentMan.h
  1105. * test/SegmentManTest.cc
  1106. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1107. Changed method signature:
  1108. DHTAbstractNodeLookupTask::getNodesFromMessage
  1109. * src/DHTAbstractNodeLookupTask.cc
  1110. * src/DHTAbstractNodeLookupTask.h
  1111. * src/DHTNodeLookupTask.cc
  1112. * src/DHTNodeLookupTask.h
  1113. * src/DHTPeerLookupTask.cc
  1114. * src/DHTPeerLookupTask.h
  1115. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1116. Pass std::deque<Command*> by reference to avoid unnecessary coping.
  1117. * src/AbstractCommand.cc
  1118. * src/BtCheckIntegrityEntry.cc
  1119. * src/BtCheckIntegrityEntry.h
  1120. * src/BtFileAllocationEntry.cc
  1121. * src/BtFileAllocationEntry.h
  1122. * src/BtSetup.cc
  1123. * src/BtSetup.h
  1124. * src/CheckIntegrityCommand.cc
  1125. * src/CheckIntegrityEntry.h
  1126. * src/ChecksumCheckIntegrityEntry.cc
  1127. * src/ChecksumCheckIntegrityEntry.h
  1128. * src/DHTSetup.cc
  1129. * src/DHTSetup.h
  1130. * src/DownloadEngine.cc
  1131. * src/FileAllocationCommand.cc
  1132. * src/FileAllocationEntry.h
  1133. * src/RequestGroup.cc
  1134. * src/RequestGroup.h
  1135. * src/RequestGroupMan.cc
  1136. * src/RequestGroupMan.h
  1137. * src/StreamCheckIntegrityEntry.cc
  1138. * src/StreamCheckIntegrityEntry.h
  1139. * src/StreamFileAllocationEntry.cc
  1140. * src/StreamFileAllocationEntry.h
  1141. * src/TrackerWatcherCommand.cc
  1142. * src/a2functional.h
  1143. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1144. Changed method signature:
  1145. BNode::findClosestKNodes, BNode:: enumerateBucket,
  1146. DHTBucket::getGoodNodes,
  1147. DHTRoutingTable::getClosestKNodes, DHTRoutingTable::getBuckets
  1148. * src/BNode.cc
  1149. * src/BNode.h
  1150. * src/DHTAbstractNodeLookupTask.cc
  1151. * src/DHTAutoSaveCommand.cc
  1152. * src/DHTBucket.cc
  1153. * src/DHTBucket.h
  1154. * src/DHTBucketRefreshTask.cc
  1155. * src/DHTFindNodeMessage.cc
  1156. * src/DHTGetPeersMessage.cc
  1157. * src/DHTRoutingTable.cc
  1158. * src/DHTRoutingTable.h
  1159. * test/BNodeTest.cc
  1160. * test/DHTBucketTest.cc
  1161. * test/DHTRoutingTableTest.cc
  1162. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1163. In piece selection functions, Pass std::deque<...> by reference rather
  1164. than returning it.
  1165. * src/BitfieldMan.cc
  1166. * src/BitfieldMan.h
  1167. * src/DefaultBtRequestFactory.cc
  1168. * src/DefaultPieceStorage.cc
  1169. * src/Piece.cc
  1170. * src/Piece.h
  1171. * test/BitfieldManTest.cc
  1172. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1173. Implemented rarest piece first piece selection strategy.
  1174. * src/AbstractBtMessage.cc
  1175. * src/AbstractBtMessage.h
  1176. * src/BitfieldMan.cc
  1177. * src/BitfieldMan.h
  1178. * src/BtBitfieldMessage.cc
  1179. * src/BtHaveAllMessage.cc
  1180. * src/BtHaveMessage.cc
  1181. * src/DefaultPieceStorage.cc
  1182. * src/DefaultPieceStorage.h
  1183. * src/PeerInteractionCommand.cc
  1184. * src/PieceStorage.h
  1185. * src/UnknownLengthPieceStorage.h
  1186. 2008-05-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1187. Rewritten readData and writeData.
  1188. * src/MultiDiskAdaptor.cc
  1189. * src/MultiDiskAdaptor.h
  1190. 2008-05-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1191. Move \n out of the message "Usage: ...".
  1192. * src/version_usage.cc
  1193. 2008-05-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1194. Bump up version number to 0.13.2b.
  1195. * configure.ac
  1196. 2008-05-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1197. Added const qualifier to argument Exception& e.
  1198. * src/Logger.h
  1199. * src/SimpleLogger.cc
  1200. * src/SimpleLogger.h
  1201. 2008-05-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1202. Pool connection when CWD, SIZE command fails.
  1203. * src/FtpNegotiationCommand.cc
  1204. * src/FtpNegotiationCommand.h
  1205. 2008-05-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1206. Renamed HttpNullDownloadCommand as HttpSkipResponseCommand
  1207. * src/HttpResponseCommand.cc
  1208. * src/HttpSkipResponseCommand.cc
  1209. * src/HttpSkipResponseCommand.h
  1210. 2008-05-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1211. Pool connection when a server returns 4xx, 5xx responses.
  1212. * src/HttpNullDownloadCommand.cc
  1213. * src/HttpNullDownloadCommand.h
  1214. * src/HttpResponse.cc
  1215. * src/HttpResponse.h
  1216. * src/HttpResponseCommand.cc
  1217. * src/HttpResponseCommand.h
  1218. * test/HttpResponseTest.cc
  1219. 2008-05-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1220. Print usage when no URL is specifed or bad command-line option is
  1221. specified.
  1222. * src/HelpItemFactory.cc
  1223. * src/help_tags.h
  1224. * src/option_processing.cc
  1225. 2008-05-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1226. Removed duplicate log message.
  1227. * src/AbstractCommand.cc (asyncResolveHostname)
  1228. 2008-05-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1229. Updated man page: --async-dns and --ftp-reuse-connection were added.
  1230. Changed -j option's default value from 5 to 1.
  1231. Added new examples using protocol auto detection feature.
  1232. Removed -T, -M usage where it can be omitted.
  1233. * doc/aria2c.1.txt
  1234. * doc/aria2c.1.html
  1235. * doc/aria2c.1.txt
  1236. 2008-05-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1237. Updated command-line usage text, so that it tells users that they
  1238. can specify any number of torrent files and metalink files in
  1239. command-line.
  1240. * src/version_usage.cc
  1241. 2008-05-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1242. Changed the default value of -j option to 1.
  1243. * src/HelpItemFactory.cc
  1244. * src/option_processing.cc
  1245. * src/usage_text.h
  1246. 2008-05-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1247. Added the ability to reuse connection in FTP and it is enabled by
  1248. default. It can be disabled by --ftp-reuse-connection=false option.
  1249. * src/Command.cc
  1250. * src/DownloadCommand.cc
  1251. * src/FtpDownloadCommand.cc
  1252. * src/FtpDownloadCommand.h
  1253. * src/FtpFinishDownloadCommand.cc
  1254. * src/FtpFinishDownloadCommand.h
  1255. * src/FtpInitiateConnectionCommand.cc
  1256. * src/FtpNegotiationCommand.cc
  1257. * src/FtpNegotiationCommand.h
  1258. * src/HelpItemFactory.cc
  1259. * src/Makefile.am
  1260. * src/Makefile.in
  1261. * src/OptionHandlerFactory.cc
  1262. * src/option_processing.cc
  1263. * src/prefs.h
  1264. * src/usage_text.h
  1265. 2008-05-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1266. Call Command::transitStatus() before calling Command::execute(),
  1267. so that the status change made in execute() is not cleared.
  1268. * src/DownloadEngine.cc
  1269. 2008-05-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1270. Removed forward declaration of SocketCore class.
  1271. * src/HttpDownloadCommand.h
  1272. 2008-05-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1273. Set Request::setKeepAliveHint() and Request::setPipeliningHint()
  1274. in InitiateConnectionCommandFactory. They should be set only when
  1275. the protocol is HTTP or HTTPS.
  1276. * src/InitiateConnectionCommandFactory.cc
  1277. * src/RequestGroup.cc
  1278. 2008-05-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1279. Fixed infinite loop in checksum checking.
  1280. * src/IteratableChecksumValidator.cc
  1281. 2008-05-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1282. Set _supportsPersistentConnection to true by default.
  1283. * src/Request.cc
  1284. * src/RequestGroup.cc
  1285. * test/HttpRequestTest.cc
  1286. * test/RequestTest.cc
  1287. 2008-05-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1288. Added timeout to socket pool. The default timeout is 15 seconds,
  1289. which is the same value Apache uses.
  1290. * src/DownloadEngine.cc
  1291. * src/DownloadEngine.h
  1292. 2008-05-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1293. Fixed misuse of multimap::find()
  1294. * src/HttpHeader.cc
  1295. * test/HttpHeaderTest.cc
  1296. 2008-05-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1297. Rewritten name resolver. Now async DNS can be disabled by --async-dns
  1298. option.
  1299. The asynchronous DNS is not capable of IPv6 yet.
  1300. By disabling asynchronous DNS, aria2 is IPv6 enabled application, at
  1301. least for HTTP download.
  1302. * src/AbstractCommand.cc
  1303. * src/AbstractCommand.h
  1304. * src/AsyncNameResolver.cc
  1305. * src/AsyncNameResolver.h
  1306. * src/DHTEntryPointNameResolveCommand.cc
  1307. * src/DHTEntryPointNameResolveCommand.h
  1308. * src/DownloadEngine.cc
  1309. * src/DownloadEngine.h
  1310. * src/FtpInitiateConnectionCommand.cc
  1311. * src/FtpInitiateConnectionCommand.h
  1312. * src/HelpItemFactory.cc
  1313. * src/HttpInitiateConnectionCommand.cc
  1314. * src/HttpInitiateConnectionCommand.h
  1315. * src/InitiateConnectionCommand.cc
  1316. * src/InitiateConnectionCommand.h
  1317. * src/Makefile.am
  1318. * src/Makefile.in
  1319. * src/NameResolver.cc
  1320. * src/NameResolver.h
  1321. * src/OptionHandlerFactory.cc
  1322. * src/SocketCore.cc
  1323. * src/SocketCore.h
  1324. * src/Util.cc
  1325. * src/Util.h
  1326. * src/option_processing.cc
  1327. * src/prefs.h
  1328. * src/usage_text.h
  1329. 2008-05-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1330. Updated man page: --quiet, --header were added.
  1331. --metalink-servers and --enable-http-keep-alive option were updated.
  1332. * doc/aria2c.1
  1333. * doc/aria2c.1.html
  1334. * doc/aria2c.1.txt
  1335. 2008-05-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1336. Enable HTTP keep-alive by default.
  1337. * src/HelpItemFactory.cc
  1338. * src/option_processing.cc
  1339. * src/usage_text.h
  1340. 2008-05-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1341. Disable http keep-alive if the remote server is not HTTP/1.1.
  1342. * src/HttpConnection.cc
  1343. 2008-05-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1344. Receive content body of 302 response so that the connection can be
  1345. reused later when http keep-alive is enabled.
  1346. * src/HttpNullDownloadCommand.cc
  1347. * src/HttpNullDownloadCommand.h
  1348. * src/HttpResponseCommand.cc
  1349. * src/HttpResponseCommand.h
  1350. 2008-05-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1351. const SharedHandle<Request> -> const SharedHandle<Request>&
  1352. * src/FtpDowndloadCommand.cc
  1353. * src/FtpDowndloadCommand.h
  1354. * src/HttpDownloadCommand.cc
  1355. * src/HttpDownloadCommand.h
  1356. 2008-05-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1357. Fixed the bug that the control file(.aria2 file) is not renamed
  1358. according to tryAutoFileRenaming().
  1359. tryAutoFileRenaming() was rewritten so that if both renamed file and
  1360. its control file exist, use them and continue download.
  1361. The old implementation didn't take into account of control file's
  1362. existence, so basically you couldn't continue download of renamed file.
  1363. * src/BtProgressInfoFile.h
  1364. * src/DefaultBtProgressInfoFile.cc
  1365. * src/DefaultBtProgressInfoFile.h
  1366. * src/NullProgressInfoFile.h
  1367. * src/RequestGroup.cc
  1368. * test/DefaultBtProgressInfoFileTest.cc
  1369. * test/MockBtProgressInfoFile.h
  1370. 2008-05-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1371. Change the default value of --metalink-servers option from `5' to `1'.
  1372. * src/HelpItemFactory.cc
  1373. * src/option_processing.cc
  1374. * src/usage_text.h
  1375. 2008-05-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1376. Reimplemented transparent metalink using Accept request header.
  1377. * src/HttpRequest.cc
  1378. * src/HttpRequest.h
  1379. * src/HttpRequestCommand.cc
  1380. * src/Metalink2RequestGroup.cc
  1381. * src/RequestGroup.cc
  1382. * src/RequestGroup.h
  1383. * test/HttpRequestTest.cc
  1384. 2008-04-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1385. Bump up version number to 0.13.2a
  1386. * configure.ac
  1387. 2008-04-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1388. Updated configure.ac using the result of autoscan.
  1389. * configure.ac
  1390. 2008-04-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1391. Fixed compilation error without gcrypt/openssl.
  1392. * src/DownloadCommand.cc
  1393. * src/DownloadCommand.h
  1394. 2008-04-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1395. Reorganized version information so that it can be displayed in a
  1396. standard terminal screen without scrolling.
  1397. Removed http, ftp from Configuration section, because they are always
  1398. enabled.
  1399. * src/FeatureConfig.cc
  1400. * src/FeatureConfig.h
  1401. * src/main.cc
  1402. * src/messageDigest.cc
  1403. * src/messageDigest.h
  1404. * src/version_usage.cc
  1405. * test/FeatureConfigTest.cc
  1406. 2008-04-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1407. Masked user ID in log.
  1408. * src/FtpConnection.cc (sendUser)
  1409. 2008-04-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1410. Removed query part from filename in HTTP download. The query part means
  1411. the substring after "?" in URL. Firefox seems do the same thing.
  1412. A query part is sometimes very long and not suitable to filename,
  1413. so I think it is better to remove it from filename.
  1414. * src/HttpRequest.cc
  1415. * src/HttpRequest.h
  1416. * src/Request.cc
  1417. * src/Request.h
  1418. * test/HttpRequestTest.cc
  1419. * test/RequestTest.cc
  1420. 2008-04-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1421. Rewritten Exception class. Throw exception object, not its pointer and
  1422. catch by reference, so that remove problematic delete operator for
  1423. catched exception.
  1424. * src/Exception.cc
  1425. * src/Exception.h
  1426. * test/ExceptionTest.cc
  1427. * src/*: All files throwing/catching exception.
  1428. * test/*: All files throwing/catching exception.
  1429. 2008-04-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1430. Now auto protocol detection is enabled without -Z option.
  1431. But there is a important difference between with/without -Z optoin.
  1432. For example, if you type:
  1433. aria2c http://host/file file1.torrent file2.metalink http://mirror/file
  1434. then, aria2 interprets there are 3 request groups:
  1435. (1) http://host/file, http://mirror/file <-- multi-source download
  1436. (2) file1.torrent
  1437. (3) file2.metalink
  1438. On the other hand, if you invoke above command with -Z option, it is
  1439. interpreted as 4 request groups:
  1440. (1) http://host/file
  1441. (2) file1.torrent
  1442. (3) file2.metalink
  1443. (4) http://mirror/file
  1444. I think usually user don't mix multi-source URLs and torrent files, so
  1445. there is no big problem here.
  1446. * src/main.cc
  1447. 2008-04-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1448. Fixed the bug that causes segmentaion fault when reading XML containing
  1449. unescapsed character like '&'.
  1450. Also a modification was made which avoids adding unnecessary
  1451. characters stack and appending unused string.
  1452. * src/ExpatMetalinkProcessor.cc
  1453. * src/FileMetalinkParserState.h
  1454. * src/FilesMetalinkParserState.h
  1455. * src/FinMetalinkParserState.h
  1456. * src/HashMetalinkParserState.h
  1457. * src/InitialMetalinkParserState.h
  1458. * src/LanguageMetalinkParserState.h
  1459. * src/MetalinkMetalinkParserState.h
  1460. * src/MetalinkParserState.h
  1461. * src/MetalinkParserStateMachine.cc
  1462. * src/MetalinkParserStateMachine.h
  1463. * src/OSMetalinkParserState.h
  1464. * src/PieceHashMetalinkParserState.h
  1465. * src/PiecesMetalinkParserState.h
  1466. * src/ResourcesMetalinkParserState.h
  1467. * src/SizeMetalinkParserState.h
  1468. * src/SkipTagMetalinkParserState.h
  1469. * src/URLMetalinkParserState.h
  1470. * src/VerificationMetalinkParserState.h
  1471. * src/VersionMetalinkParserState.h
  1472. * src/XML2SAXMetalinkProcessor.cc
  1473. 2008-04-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1474. Added StringFormat class, which internally calls vasprintf.
  1475. operator<< is defined for this class, so it can be used with iostream
  1476. classes nicely. SimpleLogger and following functions are rewritten
  1477. using StringFormat class.
  1478. Besides, now Logger class's methods are non-const, many classes
  1479. that has a const Logger* as a member variable are modified to remove
  1480. const qualifier from the variable declaration.
  1481. * src/HelpItemFactory.cc
  1482. * src/Request.cc
  1483. * src/SimpleLogger.cc
  1484. * src/StringFormat.cc
  1485. * src/StringFormat.h
  1486. * src/Util.cc
  1487. * src/option_processing.cc
  1488. * src/version_usage.cc
  1489. * test/StringFormatTest.cc
  1490. * src/*.h: The classes that has const Logger* as a member variable.
  1491. 2008-04-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1492. Log error in AccRequestGroup when reading BitTorrent/Metalink file is
  1493. failed. Also fixed memory link when exception is thrown there.
  1494. * src/main.cc (AccRequestGroup)
  1495. 2008-04-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1496. Added build-in "Accept-Features" support. For now only "metalink" is
  1497. used in this header field.
  1498. This "metalink" value is removed from the list when connecting URLs
  1499. fed by metalink file to avoid loop in "transparent" metlaink.
  1500. * src/HttpRequest.cc
  1501. * src/HttpRequest.h: Renamed _userHeaders as _headers. Accept-Features
  1502. header is also held in this variable. Also renamed setUserHeaders as
  1503. addHeader and it was rewritten to add header not just to clear the old
  1504. value.
  1505. * src/HttpRequestCommand.cc
  1506. * src/Metalink2RequestGroup.cc: Added the code to remove "metalink"
  1507. from "Accept-Features" list.
  1508. * src/RequestGroup.cc: Added "metalink" to "Accept-Features" by
  1509. default.
  1510. * src/RequestGroup.h
  1511. * src/TaggedItem.cc: Moved Concat class to a2functional.h.
  1512. * src/a2functional.h: Included <string> because Concat class depends on
  1513. it.
  1514. * test/HttpRequestTest.cc
  1515. 2008-04-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1516. Added comment
  1517. * src/RequestGroup.cc (createNextCommand)
  1518. 2008-04-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1519. Capitalized METHOD_GET and METHOD_HEAD
  1520. * src/Request.cc
  1521. 2008-04-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1522. Added getDownloadResults() method
  1523. * src/RequestGroupMan.cc
  1524. * src/RequestGroupMan.h
  1525. 2008-04-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1526. Fixed the bug that aria2 exits when commands is empty() but
  1527. _routineCommands are not.
  1528. * src/DownloadEngine.cc
  1529. 2008-04-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1530. Use the default value pulled from Option object in HelpItemFactory.
  1531. except options whose defualt value is embedded in a usage text.
  1532. * src/HelpItemFactory.cc
  1533. * src/HelpItemFactory.h
  1534. * src/option_processing.cc
  1535. * src/version_usage.cc
  1536. 2008-04-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1537. Added --quiet option to make aria2 quiet (no console output).
  1538. --quiet option is tagged with ADVANCED.
  1539. * src/HelpItemFactory.cc
  1540. * src/LogFactory.cc
  1541. * src/LogFactory.h
  1542. * src/MultiUrlRequestInfo.cc
  1543. * src/MultiUrlRequestInfo.h
  1544. * src/NullStatCalc.h: New class. This class prints nothing.
  1545. * src/OptionHandlerFactory.cc
  1546. * src/main.cc
  1547. * src/option_processing.cc
  1548. * src/prefs.h
  1549. * src/usage_text.h
  1550. 2008-04-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1551. Add HTTP tag to --header option. Removed ADVANCED tag instead.
  1552. * src/HelpItemFactory.cc (createHelpItems):
  1553. 2008-04-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1554. Fixed compilation error in ExpatMetalinkProcessor.cc
  1555. * src/ExpatMetalinkProcessor.cc
  1556. 2008-04-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1557. Reuse socket if the origin server supports HTTP keep-alive and
  1558. --enable-http-keep-alive or --enable-http-pipelining is given.
  1559. The current implementation doesn't reuse the connections established
  1560. against proxy server.
  1561. * src/AbstractCommand.cc
  1562. * src/DownloadEngine.cc
  1563. * src/DownloadEngine.h
  1564. * src/HttpDownloadCommand.cc
  1565. * src/HttpInitiateConnectionCommand.cc
  1566. * src/HttpResponseCommand.cc
  1567. 2008-04-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1568. Rewritten HTTP keep-alive and pipelining routine.
  1569. * src/AbstractCommand.cc
  1570. * src/HttpConnection.cc
  1571. * src/HttpDownloadCommand.cc
  1572. * src/HttpRequest.cc
  1573. * src/HttpRequestCommand.cc
  1574. * src/HttpResponseCommand.cc
  1575. * src/Request.cc
  1576. * src/Request.h
  1577. * src/RequestGroup.cc
  1578. * test/HttpRequestTest.cc
  1579. * test/HttpResponseTest.cc
  1580. * test/RequestTest.cc
  1581. 2008-04-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1582. Added missing setUserHeaders call
  1583. * src/HttpRequestCommand.cc
  1584. 2008-04-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1585. Call FileAllocationMan::nextFileAllocationEntryExists() first.
  1586. Calling FileAllocationMan::isFileAllocationBeingExecuted() is somwhat
  1587. waste of time because it is more likey false.
  1588. * src/FileAllocationDispatcherCommand.cc (execute)
  1589. 2008-04-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1590. Now HTTP status and version are a member variable of HttpHeader.
  1591. HTTP status is processed as a string, not integer.
  1592. * src/AbstractProxyResponseCommand.cc
  1593. * src/HttpConnection.cc
  1594. * src/HttpHeader.cc
  1595. * src/HttpHeader.h
  1596. * src/HttpHeaderProcessor.cc
  1597. * src/HttpHeaderProcessor.h
  1598. * src/HttpResponse.cc
  1599. * src/HttpResponse.h
  1600. * test/HttpHeaderProcessorTest.cc
  1601. * test/HttpResponseTest.cc
  1602. 2008-04-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1603. Added --header option. You can specify any number of additional HTTP headers
  1604. like:
  1605. aria2 --header="X-A: 300" --header="X-B: 900" http://host/file
  1606. Unlike other commad-line option, you can use --header option multiple times.
  1607. * src/HelpItemFactory.cc
  1608. * src/HttpRequest.{cc, h}
  1609. * src/HttpRequestCommand.cc
  1610. * src/OptionHandlerFactory.cc
  1611. * src/OptionHandlerImpl.h
  1612. * src/option_processing.cc
  1613. * src/prefs.h
  1614. * src/usage_text.h
  1615. * test/HttpRequestTest.cc (testUserHeaders)
  1616. 2008-04-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1617. Eliminates the time lag between sequential downloads and commands in
  1618. the same RequestGroup.
  1619. In old implementation, aria2 occasionally waits 1 seconds before
  1620. executing next command or RequestGroup.
  1621. This is really a waste of time, and new implementation eliminates
  1622. this unnecessary time lag.
  1623. * src/AbstractCommand.cc
  1624. * src/AutoSaveCommand.cc
  1625. * src/CheckIntegrityCommand.cc
  1626. * src/Command.{cc, h}
  1627. * src/DownloadEngine.{cc, h}
  1628. * src/DownloadEngineFactory.cc
  1629. * src/FileAllocationCommand.cc
  1630. * src/FileAllocationDispatcherCommand.cc
  1631. * src/FillRequestGroupCommand.cc
  1632. * src/FtpInitiateConnectionCommand.cc
  1633. * src/HaveEraseCommand.cc
  1634. * src/HttpInitiateConnectionCommand.cc
  1635. * src/HttpResponseCommand.cc
  1636. * src/RealtimeCommand.cc
  1637. * src/RequestGroup.cc
  1638. * src/RequestGroupMan.cc
  1639. * src/StreamFileAllocationEntry.cc
  1640. * src/TimeBasedCommand.{cc, h}
  1641. * src/TimedHaltCommand.cc
  1642. 2008-04-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1643. Rewritten SharedHandle. Now copy constructor taking raw pointer has
  1644. keyword explicit and SharedHandle's default constructor initializes
  1645. its internal obj to null, old implementation initializes it using
  1646. obj's default constructor.
  1647. To assign null, write SharedHandle<T> x(...); x.reset();
  1648. TODO: test/SharedHandleTest.cc needs more tests.
  1649. * src/SharedHandle.h
  1650. 2008-04-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1651. Fixed type in man page.
  1652. * doc/aria2c.1.txt
  1653. 2008-04-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1654. Merged Ross's 0.13.1+1 Cygwin compile fix patch.
  1655. * src/SimpleLogger.{cc, h}
  1656. 2008-04-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1657. Implemented auto protocol detection.
  1658. Now you can do:
  1659. aria2c -Z http://host/file file1.torrent file2.metalink
  1660. (Note: -Z option is required for auto protcol detection.)
  1661. Then aria2c downloads 3 files simultaneously:
  1662. 1. http://host/file
  1663. 2. file1.torrent <-- read local torrent file
  1664. 3. file2.metalink <-- read local Metalink file.
  1665. Same thing goes with -i option. Assume your uris.txt contans:
  1666. http://host/file
  1667. file1.torrent
  1668. file2.metalink
  1669. Then you can do: aria2c -i uris.txt
  1670. (Note: -Z option is not needed if -i option is given.)
  1671. * src/main.cc
  1672. * src/ProtocolDetector.{cc, h}
  1673. * test/ProtocolDetectorTest.cc
  1674. 2008-04-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1675. Fixed compile error without gnutls/libgcrypt/libgpg-error and openSSL
  1676. installed
  1677. * src/ARC4Encryptor.h
  1678. * src/ARC4Decryptor.h
  1679. 2008-04-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1680. Renamed argument from 'errno' to 'err', since errno is confused with
  1681. errno defined in errno.h.
  1682. * src/LibgcryptARC4Decryptor.h
  1683. * src/LibgcryptARC4Context.h
  1684. * src/LibgcryptDHKeyExchange.h
  1685. * src/LibgcryptARC4Encryptor.h
  1686. 2008-04-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1687. Rewritten choking algorithm.
  1688. * src/PeerChokeCommand.{cc, h}
  1689. * src/BtInterestedMessage.cc
  1690. * src/PeerSessionResource.{cc, h}
  1691. * src/DefaultPeerStorage.{cc, h}
  1692. * src/BtNotInterestedMessage.cc
  1693. * src/DefaultBtMessageDispatcher.{cc, h}
  1694. * src/BtMessageDispatcher.h
  1695. * src/Peer.{cc, h}
  1696. * src/BtLeecherStateChoke.{cc, h}
  1697. * src/BtSetup.cc
  1698. * src/BtSeederStateChoke.{cc, h}
  1699. * src/PeerStorage.h
  1700. * test/MockPeerStorage.h
  1701. * test/MockBtMessageDispatcher.h
  1702. 2008-04-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1703. Fixed compilation error on x84-64 platform.
  1704. * src/AuthConfig.cc: Included ostream.
  1705. 2008-03-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1706. Rewritten getBasename() and getDirname(), without standard library
  1707. basename(), dirname().
  1708. * src/File.cc
  1709. * test/FileTest.cc
  1710. 2008-03-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1711. Added Simplified Chinese translation. Also updated the following
  1712. translations: Polish, Dutch, German. Great thanks to all translators.
  1713. 2008-03-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1714. Suppress content-range error when 'Content-Range' response header
  1715. doesn't contains bytes-unit specifier 'bytes'
  1716. * src/HttpHeader.cc (getRange)
  1717. * test/HttpHeaderTest.cc
  1718. 2008-03-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1719. Fixed compilation error with g++-4.3
  1720. 2008-03-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1721. Added missing include files for MinGW
  1722. * test/HttpHeaderProcessorTest.cc
  1723. * test/DHTRoutingTableSerializerTest.cc
  1724. * test/DHTRoutingTableDeserializerTest.cc
  1725. * test/UriListParserTest.cc
  1726. 2008-03-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1727. Now download line is printed nicely with no garbage at the end of
  1728. line. I use ioctl to get the columns of terminal.
  1729. If stdout is redirected to another device, instead of carriage return,
  1730. end of line '\n' character is used. This is feature request#1909659
  1731. * src/ConsoleStatCalc.cc (calculateStat)
  1732. 2008-03-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1733. Included a2time.h
  1734. * src/DHTMessageDispatcher.h
  1735. * src/DHTMessageEntry.h
  1736. * src/DHTReplaceNodeTask.h
  1737. * src/DHTMessageTracker.h
  1738. * src/Util.h
  1739. * src/CookieBox.h
  1740. * src/SocketCore.h
  1741. * src/DefaultBtMessageDispatcher.h
  1742. * src/SocketCore.cc
  1743. * src/Util.cc
  1744. * src/DHTPingTask.h
  1745. 2008-03-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1746. Fixed high memory footprint when DHT is enabled.
  1747. This is not a memory leak, but DHTReplaceNodeTask is more frequently
  1748. queued than it is processed and the queue is getting longer. As a
  1749. consequence, momory usage is increased.
  1750. As for a fix, instead of issuing DHTReplaceNodeTask, I've implemented
  1751. replacement cache in DHTBucket which is described in Kademlia paper.
  1752. * src/DHTRoutingTable.cc (addNode): Removed the issuing of
  1753. DHTReplaceNodeTask.
  1754. * src/DHTBucket.{h, cc}
  1755. (cacheNode): New function.
  1756. (getCachedNodes): New function.
  1757. (dropNode): Push back cached node to _nodes.
  1758. * test/DHTBucketTest.cc
  1759. (testCacheNode): New test
  1760. (testDropNode): New test
  1761. 2008-03-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1762. Allocate memory for peekBuf in initiateSecureConnection() to avoid
  1763. the unused 4KB memory when ssl is not used.
  1764. * src/SocketCore.cc
  1765. 2008-03-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1766. Added summary log for peer announce storage.
  1767. * src/DHTPeerAnnounceStorage.cc (handleTimeout)
  1768. Removed cast
  1769. * src/DefaultPeerStorage.cc (addPeer)
  1770. Log exception message
  1771. * src/DHTMessageTracker.cc (handleTimeout)
  1772. Fixed casting
  1773. * test/HttpRequestTest.cc
  1774. * test/MetalinkProcessorTest.cc
  1775. * test/PieceTest.cc
  1776. * test/MetalinkEntryTest.cc
  1777. * test/SequenceTest.cc
  1778. 2008-03-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1779. * src/ParameterizedStringParser.cc (createLoop):
  1780. Removed unused variable sstep.
  1781. * src/AlphaNumberDecorator.h (decode): Rewritten.
  1782. 2008-03-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1783. * src/Util.{h, cc}
  1784. (parseUInt): New function.
  1785. (alphaToNum): Now returns unsigned int and 0 when overflow detected.
  1786. The actual range is uint32_t.
  1787. * test/UtilTest.cc
  1788. * src/ParameterizedStringParser.cc:
  1789. Use Util::parseUInt() for loop variables.
  1790. * test/ParameterizedStringParserTest.cc
  1791. * src/PStringNumLoop.h: Make _startValue and _endValue unsigned int.
  1792. 2008-03-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1793. Rewritten the functions for binding port.
  1794. * src/DHTConnectionImpl.{h, cc}
  1795. * src/PeerListenCommand.{h, cc}
  1796. * src/DHTSetup.cc
  1797. * src/BtSetup.cc
  1798. * test/DHTConnectionImplTest.cc
  1799. 2008-03-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1800. type cleanup for allmost all remaining files.
  1801. 2008-03-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1802. Type clarification
  1803. * src/PeerSessionResource.{h, cc}
  1804. * src/DefaultPieceStorage.{h, cc}
  1805. * src/Peer.{h, cc}
  1806. * test/PeerSessionResourceTest.cc
  1807. Use div function
  1808. * src/BtPieceMessage.cc (erasePieceOnDisk)
  1809. 2008-03-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1810. Type clarification
  1811. * src/DefaultPeerStorage.{h, cc}
  1812. * test/DefaultPeerStorageTest.cc
  1813. 2008-03-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1814. Type clarification: size_t for length or size, uint64_t for file
  1815. length, off_t for file offset.
  1816. * src/DefaultBtProgressInfoFile.cc
  1817. * src/DefaultBtContext.{h, cc}
  1818. * src/DefaultBtInteractive.cc
  1819. * src/DownloadCommand.{h, cc}
  1820. * src/IteratableChunkChecksumValidator.{h, cc}
  1821. * src/SegmentMan.{h, cc}
  1822. * src/SingleFileDownloadContext.{h, cc}
  1823. * src/IteratableChecksumValidator.{h, cc}
  1824. * src/BtContext.h
  1825. * src/IteratableValidator.h
  1826. * src/DownloadContext.h
  1827. * test/SingleFileDownloadContextTest.cc
  1828. * test/DefaultBtContextTest.cc
  1829. * test/MockBtContext.h
  1830. * test/Metalink2RequestGroupTest.cc
  1831. 2008-03-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1832. Type clarification: size_t for length or size, uint64_t for file
  1833. length, off_t for file offset.
  1834. * src/PiecedSegment.cc
  1835. * src/GrowSegment.h
  1836. * src/DefaultBtRequestFactory.h
  1837. * src/DefaultBtProgressInfoFile.cc
  1838. * src/UnknownLengthPieceStorage.h
  1839. * src/DefaultPieceStorage.cc
  1840. * src/UnknownLengthPieceStorage.cc
  1841. * src/DefaultBtInteractive.cc
  1842. * src/GrowSegment.cc
  1843. * src/BitfieldMan.h
  1844. * src/DownloadCommand.cc
  1845. * src/BtRequestFactory.h
  1846. * src/PiecedSegment.h
  1847. * src/DefaultPieceStorage.h
  1848. * src/Piece.cc
  1849. * src/DefaultBtRequestFactory.cc
  1850. * src/PieceStorage.h
  1851. * src/Segment.h
  1852. * src/Piece.h
  1853. * src/BitfieldMan.cc
  1854. * src/Util.cc
  1855. * test/DefaultBtProgressInfoFileTest.cc
  1856. * test/DefaultPieceStorageTest.cc
  1857. * test/MockPieceStorage.h
  1858. * test/BtRequestMessageTest.cc
  1859. * test/DefaultBtMessageDispatcherTest.cc
  1860. * test/BitfieldManTest.cc
  1861. * test/GrowSegmentTest.cc
  1862. * test/PieceTest.cc
  1863. * test/SegmentTest.cc
  1864. * test/SegmentManTest.cc
  1865. * test/DefaultBtRequestFactoryTest.cc
  1866. * test/MockBtRequestFactory.h
  1867. 2008-03-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1868. Fixed compilation error with --disable-nls
  1869. It seems that defining gettext(Msgid) to ((const char *) (Msgid))
  1870. in gettext.h causes the problem.
  1871. * src/common.h
  1872. 2008-03-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1873. Removed subPiece related functions.
  1874. * src/Piece.{h, cc} : Also rewritten getCompletedLength().
  1875. * src/DefaultPieceStorage.{h, cc}
  1876. * test/PieceTest.cc
  1877. * test/DefaultPieceStorageTest.cc
  1878. 2008-03-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1879. Use unsigned char for data store.
  1880. 2008-03-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1881. Bump up version number to 0.13.0+1
  1882. * configure.ac
  1883. * Release 0.13.0+1
  1884. 2008-03-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1885. Changed inactive connection timeout to 120.
  1886. To accept more mulually interested peers, disconnect peer when there
  1887. is no interest between us after certain time passed.
  1888. * src/DefaultBtInteractive.cc (checkActiveInteraction)
  1889. 2008-03-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1890. Fixed the bug that aria2 only uses first dns server in resolv.conf
  1891. when compiled with async DNS support.
  1892. * src/DownloadEngine.cc
  1893. * src/option_processing.cc: Lengthened DNS timeout to 30. I think old
  1894. value '10' will be a little bit short when some DNS servers are
  1895. offline and several DNS servers are tried. It should be configured
  1896. by command-line option.
  1897. 2008-03-04 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1898. Merged Ross's mingw patch.
  1899. * src/DHTRoutingTableDeserializer.cc
  1900. * src/DHTRoutingTableSerializer.cc
  1901. * src/Platform.{h, cc}
  1902. * src/timegm.h
  1903. * src/gettimeofday.h
  1904. * src/getaddrinfo.h
  1905. * src/SocketCore.h
  1906. * src/common.h
  1907. * src/inet_aton.h
  1908. * src/DownloadEngine.h
  1909. * src/gai_strerror.h
  1910. * src/a2netcompat.h
  1911. * configure.ac
  1912. * configure
  1913. * aclocal.m4
  1914. 2008-03-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1915. Included missing iostream.
  1916. * test/AllTest.cc
  1917. * test/BtDependencyTest.cc
  1918. * test/BtExtendedMessageTest.cc
  1919. * test/DHTConnectionImplTest.cc
  1920. * test/DHTMessageFactoryImplTest.cc
  1921. * test/DHTMessageTrackerEntryTest.cc
  1922. * test/DHTNodeTest.cc
  1923. * test/DHTRoutingTableSerializerTest.cc
  1924. * test/DefaultBtAnnounceTest.cc
  1925. * test/DefaultBtContextTest.cc
  1926. * test/DefaultBtMessageFactoryTest.cc
  1927. * test/DefaultExtensionMessageFactoryTest.cc
  1928. * test/HandshakeExtensionMessageTest.cc
  1929. * test/HttpResponseTest.cc
  1930. * test/MetalinkProcessorTest.cc
  1931. * test/MultiFileAllocationIteratorTest.cc
  1932. * test/SocketCoreTest.cc
  1933. * test/UTPexExtensionMessageTest.cc
  1934. 2008-03-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1935. Reorganized includes.
  1936. * src/NameResolver.cc
  1937. 2008-03-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1938. Fixed compilation error without ares/c-ares
  1939. * src/NameResolver.h:
  1940. 2008-03-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1941. Added a test for large file.
  1942. * test/MetalinkProcessorTest.cc (testLargeFileSize):
  1943. 2008-03-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1944. Fixed the bug that file size is ignored if size > INT32_MAX
  1945. * src/SizeMetalinkParserState.cc (endElement):
  1946. 2008-03-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1947. Bump up version number to 0.13.0
  1948. * configure.ac
  1949. * Release 0.13.0
  1950. 2008-03-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1951. Updated Makfefile.am to make 'make dist' work.
  1952. Now packaged filename is aria2c-VERSION.tar.bz2.
  1953. Added README, README.html, and aria2c.1.html to dist_doc_DATA.
  1954. Added LICENSE.OpenSSL to dist_noinst_DATA.
  1955. Large file support is now configured by configure script.
  1956. * configure.ac
  1957. Removed unsused source files
  1958. * src/
  1959. * test/
  1960. Removed PeerDecl.h and BtContextDecl.h. typedefs are removed to
  1961. Peer.h and BtContext.h respectively.
  1962. * src/Peer.h
  1963. * src/BtContext.h
  1964. Updated translations.
  1965. Added Polish, Thai, Indonesian, Norwegian Nynorsk, Hungarian
  1966. translations. Great thanks to all translators!;)
  1967. * po/*.{po, gmo}
  1968. 2008-02-29 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1969. Create MessageDigestHelper::staticSHA1DigestInit() which uses
  1970. statically declared sha1 MessageDigestContext.
  1971. * src/BtPieceMessage.cc: Use staticSHA1DigestInit() to avoid
  1972. initialization of short-lived MessageDigestContext.
  1973. * src/MessageDigestHelper.{h, cc}
  1974. * src/main.cc
  1975. Now DownloadCommand has a reference to MessageDigestContext to avoid
  1976. the initialization of MessageDigestContext every time in validating
  1977. chunk checksum.
  1978. * src/DownloadCommand.{h, cc}
  1979. 2008-02-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1980. Add a file descriptor which connected to fast peer(latency<1500) to
  1981. select(). This change reduced CPU load.
  1982. * src/PeerInteractionCommand.cc
  1983. * src/DefaultBtInteractive.{h, cc}
  1984. * src/BtInteractive.h
  1985. 2008-02-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1986. Fixed the previous insufficient fix for possible busy loop.
  1987. * src/MSEHandshake.cc (identifyHandshakeType)
  1988. Removed unused functions.
  1989. * src/MSEHandshake.{h, cc} (readDataAndDecrypt)
  1990. 2008-02-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1991. Fixed possible busy loop if first 20 bytes are not received for a few
  1992. minutes.
  1993. * src/MSEHandshake.{h, cc} (identifyHandshakeType)
  1994. * src/ReceiverMSEHandshakeCommand.cc
  1995. 2008-02-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1996. Fixed compilation error
  1997. * src/ExpatMetalinkProcessor.cc
  1998. 2008-02-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  1999. Fixed compile error on Mac OS X, on 64Bit OS maybe.
  2000. * src/DHTBucket.cc
  2001. Removed unnecessary cast.
  2002. * src/HandshakeExtensionMessage.cc
  2003. 2008-02-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2004. Fixed the bug that option handler for PREF_METALINK_ENABLE_UNIQUE_PROTOCOL.
  2005. is missing.
  2006. * src/OptionHandlerFactory.cc
  2007. 2008-02-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2008. Fixed the bug that HAVE message is not sent for a piece they are
  2009. downloaded fom http/ftp server before any BitTorrent handshake is done
  2010. with peers.
  2011. * src/DefaultBtInteractive.cc
  2012. 2008-02-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2013. Removed RequestInfo.h and FileAllocator.h since they have been removed.
  2014. * src/Makefile.am
  2015. * src/Makefile.in
  2016. 2008-02-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2017. Updated README. Added html version of README and man page.
  2018. * README
  2019. * README.html
  2020. * readme2html: Shell script to generate README.html from README using
  2021. asciidoc.
  2022. * doc/aria2c.1.html
  2023. * doc/makeman: Added the line to generate aria2c.1.html
  2024. 2008-02-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2025. Fixed offset calculation.
  2026. * src/LibgcryptDHKeyExchange.h (computeSecret)
  2027. 2008-02-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2028. Rewritten itos and uitos using template. llitos and ullitos are
  2029. replaced with itos and uitos respectively.
  2030. * src/Util.{h, cc}
  2031. * test/UtilTest.cc
  2032. 2008-02-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2033. Fixed the bug that DH key exchange sometimes fails due to bad handling
  2034. of the number of bytes required for storing public key and shared
  2035. secret.
  2036. * src/LibgcryptDHKeyExchange.h
  2037. * src/LibsslDHKeyExchange.h: Also added function name to handleError.
  2038. * src/MSEHandshake.cc
  2039. * test/DHKeyExchangeTest.cc
  2040. 2008-02-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2041. Removed since they are not used.
  2042. * src/Xml2MetalinkProcessor.{h, cc}
  2043. * src/Socket.cc
  2044. * src/SegmentSplitter.{h, cc}
  2045. * test/Xml2MetalinkProcessorTest.cc
  2046. 2008-02-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2047. Fixed the bug that prevents aria2 from stopping other than by pressing
  2048. Ctrl-C in BitTorrent download. It is reproducible using --seed-time
  2049. option. aria2 doesn't stop even after --seed-time is satisfied and
  2050. continues to output blank lines in the console.
  2051. * src/ReceiverMSEHandshakeCommand.cc
  2052. * src/PeerReceiveHandshakeCommand.cc
  2053. * src/PeerListenCommand.cc
  2054. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2055. Bump up version number to 0.13.0rc
  2056. * configure.ac
  2057. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2058. Updated man page and some usage text.
  2059. * doc/aria2c.1.txt
  2060. * src/usage_text.h
  2061. * po/*.{po, gmo}
  2062. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2063. Updated translations. Added Finnish and Hebrew translations.
  2064. Great thanks to all translators!
  2065. * po/*.{po, gmo}
  2066. * po/LINGUAS
  2067. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2068. Log more detailed information about each message.
  2069. * src/DHTQueryMessage.{h, cc}
  2070. * src/DHTGetPeersMessage.{h, cc}
  2071. * src/DHTFindNodeReplyMessage.{h, cc}
  2072. * src/DHTGetPeersReplyMessage.{h, cc}
  2073. * src/DHTAnnouncePeerMessage.{h, cc}
  2074. * src/DHTResponseMessage.{h, cc}
  2075. * src/DHTFindNodeMessage.{h, cc}
  2076. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2077. Use constants defined in prefs.h
  2078. * src/option_processing.cc
  2079. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2080. * test/AllTest.cc: Added OpenSSL, GNUTLS initialization code.
  2081. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2082. Make room for future enchancements for IPv6 addresses.
  2083. Bump up version number of dht.dat file format to 2.
  2084. Not compatible with previous version.
  2085. * src/DHTRoutingTableSerializer.cc
  2086. * src/DHTRoutingTableDeserializer.cc
  2087. * test/DHTRoutingTableSerializerTest.cc
  2088. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2089. Added handling for the return values from
  2090. PeerMessageUtil::createcompact().
  2091. * src/DefaultBtContext.cc (computeFastSet):
  2092. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2093. Fixed abort when peer's ip address is IPv4-mapped address.
  2094. * src/DefaultBtContext.cc (computeFastSet)
  2095. Removed number-and-dots criteria, since Util::isNumberAndDotsNotation()
  2096. cannot handle IPv4-mapped addresses.
  2097. * src/DefaultBtInteractive.cc (addPeerExchangeMessage)
  2098. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2099. Proper return value handling for OpenSSL functions.
  2100. * src/LibsslDHKeyExchange.h
  2101. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2102. Random bytes generation using libgcrypt and OpenSSL.
  2103. * src/DHTUtil.{h, cc}
  2104. * test/DHTUtilTest.cc
  2105. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2106. Fixed segmentation fault when a DHT message which doesn't have 'y' key
  2107. received.
  2108. * src/DHTMessageReceiver.cc (receiveMessage)
  2109. 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2110. Fixed the bug that a return code is always 0. BUG#1897704
  2111. If error occurred during the download or there exist unfinished
  2112. downloads, aria2 returns with code 1.
  2113. * src/RequestGroupMan.{h, cc}
  2114. * src/MultiUrlRequestInfo.{h, cc}
  2115. * src/main.cc
  2116. 2008-02-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2117. IPv6 support for SocketCore class.
  2118. TODO: In SocketCore::establishConnection(), this is insufficient to
  2119. determin the failure of connect() here because the socket is
  2120. non-blocking state. The next addresses should be tried after select().
  2121. TODO: NameResolver still uses c-ares(<= 1.4) ares_gethostbyname().
  2122. If c-ares 1.5 or newer is installed, ares_getaddrinfo() should be used
  2123. instead which address family independent.
  2124. TODO: DHTRoutingTable{Deserializer,Serializer} currently saves peer
  2125. information in a compact peer format which is for IPv4 only.
  2126. Some BitTorrent functions in PeerMessageUtil still depends on IPv4 but
  2127. this is a spec of BitTorrent protocol.
  2128. * src/SocketCore.{h, cc}
  2129. * src/PeerMessageUtil.cc
  2130. * test/SocketCoreTest.cc
  2131. * test/PeerMessageUtilTest.cc
  2132. * test/DHTConnectionImplTest.cc
  2133. Handle IPv4-mapped addresses.
  2134. * src/DHTNode.cc: Now identity is determined by node id.
  2135. * src/DHTMessageTrackerEntry.cc
  2136. Because now PeerMessageUtil::unpackcompact() could fail, the caller
  2137. should handle it.
  2138. * src/DHTRoutingTableDeserializer.cc
  2139. * src/DHTMessageFactoryImpl.cc
  2140. 2008-02-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2141. Change the unit of --stop option from a minute to a second.
  2142. * src/usage_text.h
  2143. * src/DownloadEngineFactory.cc
  2144. * src/OptionHandlerFactory.cc
  2145. * src/message.h
  2146. * src/TimedHaltCommand.cc
  2147. 2008-02-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2148. Make listening socket non-block mode.
  2149. * src/FtpConnection.cc
  2150. * src/FtpNegotiationCommand.{h, cc}
  2151. * src/PeerListenCommand.cc
  2152. Fixed the bug that cause slow ftp negotiation.
  2153. * src/FtpNegotiationCommand.{h, cc}
  2154. 2008-02-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2155. Added basic tag to --enable-dht, --dht-listen-port option.
  2156. * src/HelpItemFactory.cc (createHelpItems)
  2157. 2008-02-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2158. Updated text.
  2159. * src/usage_text.h
  2160. 2008-02-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2161. * src/MSEHandshake.cc (encryptAndSendData): Use std::min().
  2162. 2008-02-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2163. Determin _threadtholdSpeed in each constructor for
  2164. ActivePeerConnectionCommand and PeerReceiveHandshakeCommand.
  2165. * src/ActivePeerConnectionCommand.{h, cc}
  2166. * src/PeerReceiveHandshakeCommand.{h, cc}
  2167. * src/BtSetup.cc
  2168. * src/BtConstants.h
  2169. 2008-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2170. Added --bt-min-crypto-level and --bt-require-crypto options.
  2171. * src/OptionHandlerFactory.cc
  2172. * src/MSEHandshake.cc
  2173. * src/HelpItemFactory.cc
  2174. * src/option_processing.cc
  2175. * src/ReceiverMSEHandshakeCommand.cc
  2176. * src/prefs.h
  2177. * src/DefaultBtAnnounce.cc
  2178. * src/InitiatorMSEHandshakeCommand.cc
  2179. * src/usage_text.h
  2180. * test/MSEHandshakeTest.cc
  2181. 2008-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2182. Bump version number to 0.13.0b
  2183. * configure.ac
  2184. 2008-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2185. Updated doc.
  2186. * src/MessageDigestHelper.h:
  2187. 2008-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2188. Use raw message digest as a token instead of its hexadecimal
  2189. representation.
  2190. * src/DHTTokenTracker.cc (generateToken)
  2191. 2008-02-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2192. Added Message Stream Encryption(MSE) support.
  2193. Currently, aria2 accepts incoming connections with Obfuscation Header
  2194. and legacy BitTorrent Header and establishes connections with
  2195. Obfuscation Header first and if failed then retry with legacy
  2196. BitTorrent header. If plain text and ARC4 is provided, aria2 always
  2197. choose ARC4. The new option to change the default behavior is planned.
  2198. For tracker extension, "supportcrypto=1" is added statically.
  2199. * src/PeerInitiateConnectionCommand.{h, cc}
  2200. * src/PeerConnection.{h, cc}
  2201. * src/HandleRegistry.h
  2202. * src/SocketCore.h
  2203. * src/PeerReceiveHandshakeCommand.{h, cc}
  2204. * src/BtRegistry.{h, cc}
  2205. * src/PeerListenCommand.cc
  2206. * src/InitiatorMSEHandshakeCommand.{h, cc}
  2207. * src/ReceiverMSEHandshakeCommand.{h, cc}
  2208. * src/MSEHandshake.{h, cc}
  2209. * src/ARC4Encryptor.h
  2210. * src/ARC4Decryptor.h
  2211. * src/LibgcryptARC4Encryptor.h
  2212. * src/LibgcryptARC4Decryptor.h
  2213. * src/LibgcryptARC4Context.h
  2214. * src/LibsslARC4Encryptor.h
  2215. * src/LibsslARC4Decryptor.h
  2216. * src/LibsslARC4Context.h
  2217. * src/DHKeyExchange.h
  2218. * src/LibgcryptDHKeyExchange.h
  2219. * src/LibsslDHKeyExchange.h
  2220. * src/DefaultBtAnnounce.cc: Just added "supportcrypto=1" parameter.
  2221. * test/DefaultBtAnnounceTest.cc
  2222. * test/ARC4Test.cc
  2223. * test/DHKeyExchangeTest.cc
  2224. Removed prepareForRetry() because it is not used.
  2225. * src/PeerAbstractCommand.{h, cc}
  2226. * src/PeerInteractionCommand.{h, cc}
  2227. * src/PeerInitiateConnectionCommand.{h, cc}
  2228. 2008-02-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2229. Added the ability to load nodes from torrent file. These nodes are
  2230. added to the routing table when downloading that torrent.
  2231. * src/BtContext.h
  2232. * src/DefaultBtContext.{h, cc}
  2233. * src/DHTSetup.cc
  2234. * src/DHTEntryPointNameResolveCommand.{h, cc}: Now accepts list of
  2235. hostname and port pair, and resolves all of them.
  2236. * src/NameResolver.{h, cc}: Added reset().
  2237. * src/RequestGroup.cc
  2238. * test/DefaultBtContextTest.cc
  2239. * test/MockBtContext.h
  2240. Removed assert() from DefaultBtContext and throw exception instead.
  2241. * src/DefaultBtContext.cc
  2242. 2008-02-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2243. Fixed segmentation fault bug when exiting if dht is disabled.
  2244. * src/RequestGroup.cc
  2245. 2008-02-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2246. Fixed typo in log message and define the message in message.h
  2247. * src/TimedHaltCommand.cc
  2248. * src/message.h
  2249. 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2250. Included RecoverableException.h to fix compilation error.
  2251. * test/DHTMessageFactoryImplTest.cc
  2252. 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2253. Added test 'testDoReceivedAction' for DHTQueryMessage subclasses.
  2254. * test/DHTPingMessageTest.cc
  2255. * test/DHTGetPeersMessageTest.cc
  2256. * test/DHTFindNodeMessageTest.cc
  2257. * test/DHTAnnouncePeerMessageTest.cc
  2258. * test/MockDHTMessage.h
  2259. * test/MockDHTMessageFactory.h
  2260. * test/MockDHTMessageDispatcher.h: New class.
  2261. 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2262. Added DHTMessageDispatcherImpl. Now DHTMessageDispatcher is pure
  2263. virtual.
  2264. * src/DHTMessageDispatcher.h
  2265. * src/DHTMessageDispatcherImpl.{h, cc}
  2266. * src/DHTSetup.cc
  2267. 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2268. Adding handling of DHT error message. Just log error message and
  2269. throw exception.
  2270. * src/DHTMessageFactoryImpl.cc
  2271. * test/DHTMessageFactoryImplTest.cc
  2272. 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2273. Added handling of dynamic cast failure.
  2274. * src/DHTNodeLookupTask.cc
  2275. * src/DHTPeerLookupTask.cc
  2276. 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2277. Added the ability to stop aria2 itself when given time has passed
  2278. from start. Use --stop option to specify time in minutes.
  2279. When 0 is given, this feature is disabled.
  2280. * src/OptionHandlerFactory.cc
  2281. * src/TimeBasedCommand.h: Make _interval protected scope.
  2282. * src/HelpItemFactory.cc
  2283. * src/option_processing.cc
  2284. * src/prefs.h
  2285. * src/FillRequestGroupCommand.cc: Evaluate _e->isHaltRequested()
  2286. before calling RequestGroupMan::fillRequestGroupFromReserver().
  2287. Without this modification, the result list shows "ERR" when aria2 is
  2288. stopped by --stop option. It should be "INPR".
  2289. * src/DownloadEngine.{h, cc}
  2290. * src/DownloadEngineFactory.cc
  2291. * src/usage_text.h
  2292. * src/TimedHaltCommand.{h, cc}: New class.
  2293. 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2294. Bootstrap through node added by port message.
  2295. Currently bootstrap is executed if the number of buckets in routing
  2296. table is 1.
  2297. * src/BtPortMessage.{h, cc}
  2298. * src/DefaultBtMessageFactory.{h, cc}
  2299. * src/PeerInteractionCommand.cc
  2300. * test/BtPortMessageTest.cc
  2301. * test/MockDHTTask.h
  2302. 2008-02-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2303. Extract the Peer class's member variables, which are only needed after
  2304. PeerInteractionCommand, into PeerSessionResource class.
  2305. This class is instantiated in PeerInteractionCommand class's ctor and
  2306. released in its dtor.
  2307. This will make Peer class lightweight and uses less memory for peers
  2308. which are not connected and wait in the queue.
  2309. * src/PeerChokeCommand.cc
  2310. * src/PeerSessionResource.{h, cc}
  2311. * src/PeerInteractionCommand.cc
  2312. * src/PeerAbstractCommand.cc: Note: 0 is given to onAbort() function.
  2313. * src/DefaultBtInteractive.cc
  2314. * src/BtPieceMessage.cc
  2315. * src/BtInterestedMessage.cc
  2316. * src/BtUnchokeMessage.cc
  2317. * src/DefaultPeerStorage.{h, cc}
  2318. * src/PeerInitiateConnectionCommand.cc
  2319. * src/ActivePeerConnectionCommand.cc
  2320. * src/BtNotInterestedMessage.cc
  2321. * src/DefaultBtMessageDispatcher.cc
  2322. * src/BtChokeMessage.cc
  2323. * src/BtRequestMessage.cc
  2324. * src/Peer.{h, cc}
  2325. * src/BtRegistry.h
  2326. * src/TrackerWatcherCommand.cc
  2327. * src/PeerReceiveHandshakeCommand.cc
  2328. * test/BtExtendedMessageTest.cc
  2329. * test/BtAllowedFastMessageTest.cc
  2330. * test/BtCancelMessageTest.cc
  2331. * test/DefaultPieceStorageTest.cc
  2332. * test/BtBitfieldMessageTest.cc
  2333. * test/BtHaveMessageTest.cc
  2334. * test/BtNotInterestedMessageTest.cc
  2335. * test/BtRequestMessageTest.cc
  2336. * test/PeerSessionResourceTest.cc
  2337. * test/DefaultBtMessageDispatcherTest.cc
  2338. * test/PeerTest.cc
  2339. * test/BtInterestedMessageTest.cc
  2340. * test/BtRejectMessageTest.cc
  2341. * test/BtChokeMessageTest.cc
  2342. * test/DefaultPeerStorageTest.cc
  2343. * test/BtHaveNoneMessageTest.cc
  2344. * test/BtHaveAllMessageTest.cc
  2345. * test/DefaultExtensionMessageFactoryTest.cc
  2346. * test/BtUnchokeMessageTest.cc
  2347. * test/DefaultBtMessageFactoryTest.cc
  2348. * test/HandshakeExtensionMessageTest.cc
  2349. * test/UTPexExtensionMessageTest.cc
  2350. * test/DefaultBtRequestFactoryTest.cc
  2351. * test/BtPieceMessageTest.cc
  2352. Removed typedef PeerStats.
  2353. * src/PeerStat.h
  2354. * src/SegmentMan.cc
  2355. 2008-02-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2356. Added std namespace to copy, remove_copy, back_inserter,
  2357. front_inserter.
  2358. * src/RequestGroupMan.cc
  2359. * src/DefaultPieceStorage.cc
  2360. * src/StreamFileAllocationEntry.cc
  2361. * src/BtFileAllocationEntry.cc
  2362. * src/RequestGroup.cc
  2363. * src/MetalinkEntry.cc
  2364. * src/DelegatingPeerListProcessor.cc
  2365. * src/DefaultBtRequestFactory.cc
  2366. * src/DefaultBtMessageDispatcher.cc
  2367. * src/version_usage.cc: Included <algorithm>
  2368. * src/main.cc
  2369. * src/MetalinkParserController.cc
  2370. * src/DefaultBtContext.cc
  2371. * src/DownloadEngineFactory.cc
  2372. * src/a2algo.h
  2373. Removed.
  2374. * test/StreamUriListParserTest.cc
  2375. 2008-02-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2376. Use PREF_MAX_DOWNLOAD_LIMIT as a threshold for
  2377. ActivePeerConnectionCommand when it is given and
  2378. PREF_MAX_DOWNLOAD_LIMIT < default threshold.
  2379. * src/ActivePeerConnectionCommand.{h, cc}
  2380. * src/BtSetup.cc
  2381. 2008-02-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2382. Only add socket to DownloadEngine's select routine when peer or
  2383. localhost is unchoked and interested. This lowers CPU usage a
  2384. little bit.
  2385. * src/PeerInteractionCommand.cc
  2386. * src/PeerAbstractCommand.{h, cc}
  2387. * src/BtInteractive.h
  2388. * src/DefaultBtInteractive.{h, cc}
  2389. 2008-02-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2390. Revert previous change because get_peers message is needed for
  2391. announce_peer anyway.
  2392. * src/DHTGetPeersCommand.cc
  2393. 2008-02-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2394. Request peers thought DHT only when download hasn't finished.
  2395. * src/DHTGetPeersCommand.cc
  2396. 2008-02-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2397. Force refresh bucket when startup if certain time has passed(currently 15 minutes).
  2398. * src/DHTBucketRefreshTask.{h, cc}
  2399. * src/DHTSetup.cc
  2400. 2008-02-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2401. Removed "using namespace std;" from all sources. Appended std:: prefix to c++
  2402. standard classes.
  2403. Included string.h where mem* function are used.
  2404. Added namespace aria2.
  2405. 2008-02-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2406. Create directory before saving DHT routing table.
  2407. Now ios::failure is now handled properly.
  2408. * src/DHTAutoSaveCommand.cc
  2409. 2008-02-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2410. Removed unnecessary cerr.
  2411. * src/DownloadEngine.cc
  2412. 2008-02-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2413. Catch exception inside DHTMessageReceiver::receiveMessage().
  2414. Log unknown message.
  2415. * src/DHTMessageReceiver.{h, cc}
  2416. * src/DHTMessageFactory.h
  2417. * src/DHTMessageFactoryImpl.{h, cc}
  2418. * src/DHTMessageTracker.cc (handleTimeout): Catch and handle exception.
  2419. * src/DHTInteractionCommand.cc
  2420. * src/DHTUnknownMessage.{h, cc}
  2421. * test/DHTUnknownMessageTest.cc
  2422. * test/MockDHTMessageFactory.h
  2423. 2008-02-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2424. Commented out ip address comparison because a host can have multiple
  2425. ip addresses and it is hard to predict the hostname is resolved into
  2426. which one.
  2427. * test/SocketCoreTest.cc (testWriteAndReadDatagram)
  2428. 2008-02-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2429. * po/Makefile.in: Removed since this is generated by configure.
  2430. 2008-02-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2431. Fixed compiler warning about redefinition of SIZE_MAX.
  2432. Use common.h instead of config.h directly here.
  2433. * src/Platform.{h, cc}
  2434. The check of ENABLE_NLS is made in gettext.h, so it is not required
  2435. here.
  2436. * common.h
  2437. 2008-02-02 gettextize <bug-gnu-gettext@gnu.org>
  2438. Updated gettext related files.
  2439. * configure.ac (AC_CONFIG_FILES): Add intl/Makefile.
  2440. * configure.ac (AM_GNU_GETTEXT_VERSION): Bump to 0.17.
  2441. 2008-02-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2442. Added DHT functionality, compatible with mainline.
  2443. DHT is disabled by default. To enable it, give --enable-dht to aria2c.
  2444. You may need to specify entry point to DHT network using
  2445. --dht-entry-point. DHT uses UDP port to listen incoming message.
  2446. Use --dht-listen-port to specify port number. Make sure that your
  2447. firewall configuration can pass through UDP traffic to the port.
  2448. The routing table is saved in $HOME/.aria2/dht.dat.
  2449. * src/DHT*
  2450. * src/BNode.{h, cc}
  2451. * src/PeerInteractionCommand.cc: enable DHT functionality for a
  2452. particular torrent.
  2453. * src/Data.cc: Rewritten ctor.
  2454. * src/OptionHandlerFactory.cc: Added --enable-dht, --dht-listen-port,
  2455. --dht-entry-point.
  2456. * src/DefaultBtInteractive.cc: Send port message if dht is enabled.
  2457. * src/RequestGroup.cc: Initialize DHT functionality. When download
  2458. ends, remove BtContext from DHTPeerAnnounceStorage.
  2459. * src/BtPortMessage.{h, cc}: Rewritten.
  2460. * src/message.h
  2461. * src/OptionHandlerImpl.cc
  2462. * src/option_processing.cc: Added --enable-dht, --dht-listen-port,
  2463. --dht-entry-point.
  2464. * src/Dictionary.{h, cc} (remove): New function.
  2465. * src/prefs.h
  2466. * src/DefaultBtMessageFactory.h
  2467. * src/BtHandshakeMessage.cc
  2468. * src/ActivePeerConnectionCommand.cc
  2469. * src/SocketCore.{h, cc}: Added datagram socket support.
  2470. * src/DefaultBtMessageFactory.cc
  2471. * src/BtSetup.cc: Add BtContext to DHTPeerAnnounceStorage here.
  2472. Create DHT commands.
  2473. * src/BtMessageFactory.h
  2474. * src/PeerMessageUtil.{h, cc}
  2475. 2008-01-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2476. Fixed the bug that log file is not written when configuration file doesn't exist.
  2477. This is caused by using Logger class before LogFactory is not configured.
  2478. BUG #1875079
  2479. * src/option_processing.cc
  2480. Warning message "configuration doesn't exist" is only printed when --conf is
  2481. given.
  2482. * src/option_processing.cc
  2483. 2008-01-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2484. Use BencodeVisitor and MessageDigestHelper instead of ShaVisitor.
  2485. ShaVisitor is now deprecated and slated to be removed.
  2486. * src/DefaultBtContext.cc
  2487. 2008-01-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2488. Externalize message to message.h
  2489. * src/Platform.cc
  2490. * src/message.h
  2491. 2008-01-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2492. Set default domain and default path to cookie.
  2493. * src/HttpResponse.cc
  2494. * src/CookieBox.{h, cc}
  2495. * src/CookieParser.{h, cc}
  2496. * test/CookieParserTest.cc
  2497. 2008-01-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2498. Added --no-conf and --conf-path command-line option.
  2499. --no-conf option disables loading aria2.conf file.
  2500. --conf-path option changes the configuration file path. The default
  2501. file path is $HOME/.aria2/aria2.conf
  2502. Added a warning message when the configuration file is not found.
  2503. * src/HelpItemFactory.cc
  2504. * src/option_processing.cc
  2505. * src/prefs.h
  2506. * src/usage_text.h
  2507. 2008-01-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2508. Added the message to inform users that other help categories are
  2509. available in -h option.
  2510. * src/version_usage.cc
  2511. * src/TagContainer.{h, cc}
  2512. * test/TagContainerTest.cc
  2513. * src/TaggedItem.{h, cc}
  2514. * test/TaggedItemTest.cc
  2515. * src/HelpItem.h
  2516. 2008-01-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2517. Added Piece::getFirstMissingBlockIndexWithoutLock() and it is called
  2518. from PiecedSegment's ctor.
  2519. Previously Piece::getAllMissingBlockIndexes() is called from
  2520. PiecedSegment() but it is rather expensive since only first element is
  2521. used.
  2522. * src/PiecedSegment.cc
  2523. * src/Piece.{h, cc}
  2524. 2008-01-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2525. Rewritten get*Missing*Index functions. Now no need to allocate memory
  2526. each time these functions are called.
  2527. * src/BitfieldMan.{h, cc}
  2528. * test/BitfieldManTest.cc
  2529. * src/array_fun.h
  2530. * test/array_funTest.cc
  2531. Now BitfieldMan::countBlock() returns BitfieldMan::blocks.
  2532. Added new BitfieldMan::countFilteredBlock() to get the number of blocks
  2533. filtered. Removed unnecessary cast to int32_t.
  2534. * src/BitfieldMan.{h, cc}
  2535. 2008-01-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2536. Fixed the bug that EX_TOO_LONG_PAYLOAD exception is thrown if just
  2537. payload length(4bytes) are received. This happens because lenbufLength
  2538. is not updated in this particular case and successive call of
  2539. receiveMessage() overwrites payload length with bytes recieved which
  2540. are payload body.
  2541. * src/PeerConnection.{h, cc}
  2542. * src/message.h
  2543. 2008-01-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2544. Fixed the bug that DefaultPeerStorage::returnPeer() may delete wrong
  2545. peer if there are peers that have same ipaddr and port.
  2546. I've experiened segmentation fault and "pure virtual function was
  2547. called" error.
  2548. * src/Peer.h
  2549. * test/PeerTest.cc
  2550. * src/DefaultPeerStorage.cc
  2551. * test/DefaultPeerStorageTest.cc
  2552. 2008-01-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2553. Removed a call to isPowerOf() because it is no longer necessary here
  2554. and a request block is not always power of 2.
  2555. BUG#1866924
  2556. * src/PeerMessageUtil.cc (checkLength)
  2557. 2008-01-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2558. Fixed the bug that always first found Segment is removed from
  2559. usedSegmentEntries. Removed unused functions.
  2560. * src/SegmentMan.{h, cc}
  2561. * test/SegmentManTest.cc
  2562. Fixed the bug that ServerHost is not removed.
  2563. * src/RequestGroup.cc
  2564. 2008-01-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2565. Fixed the bug that SegmentMan::completeSegment() is not called
  2566. even if Segment is complete when --lowest-speed-limit is enabled.
  2567. BUG#1864525
  2568. * src/DownloadCommand.{h, cc}
  2569. 2008-01-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2570. Fixed: hash algorithm 'sha1' is always used.
  2571. * src/DownloadCommand.cc (validatePieceHash)
  2572. 2008-01-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2573. Added --enable-peer-exchange command-line option.
  2574. * src/OptionHandlerFactory.cc
  2575. * src/HelpItemFactory.cc
  2576. * src/option_processing.cc
  2577. * src/usage_text.h
  2578. 2008-01-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2579. Move extension from BtRuntime to ExtensionMessageFactory, because
  2580. extension can be specified per peer, not per torrent.
  2581. * src/DefaultBtInteractive.cc
  2582. * src/BtRuntime.h
  2583. * src/ExtendedMessagingAware.h
  2584. * src/ExtensionMessageFactory.h
  2585. * src/DefaultExtensionMessageFactory.cc
  2586. * test/DefaultExtensionMessageFactoryTest.cc
  2587. 2008-01-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2588. Added categorized option help. Specify category using --help option.
  2589. Also added the ability to search options in forward match.
  2590. * src/HelpItem.{h, cc}
  2591. * test/HelpItemTest.cc
  2592. * src/HelpItemFactory.{h, cc}
  2593. * src/TagContainer.{h, cc}
  2594. * test/TagContainerTest.cc
  2595. * src/option_processing.cc
  2596. * src/prefs.h
  2597. * src/TaggedItem.{h, cc}
  2598. * test/TaggedItemTest.cc
  2599. * src/version_usage.cc
  2600. * src/help_tags.h
  2601. * src/usage_text.h
  2602. 2008-01-04 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2603. Fixed segmentation fault when bad torrent metainfo is parsed.
  2604. Added dynamic_cast properly to detect the misconfiguration of metainfo
  2605. and then throw exception or skip it.
  2606. * src/DefaultBtContext.{h, cc}
  2607. * test/DefaultBtContextTest.cc
  2608. * src/AnnounceList.cc
  2609. * src/CompactPeerListProcessor.cc
  2610. * src/message.h
  2611. * src/DefaultBtAnnounce.{h, cc}
  2612. * test/DefaultBtAnnounceTest.cc
  2613. * src/BencodeVisitor.cc
  2614. 2007-12-29 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2615. Added missing "B"(=Byte). So now the message looks like this:
  2616. Your share ratio was 1.0, uploaded/downloaded=12MiB/12MiB
  2617. * src/message.h (MSG_SHARE_RATIO_REPORT)
  2618. 2007-12-29 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2619. Show the seed ratio after torrent downloads.
  2620. For example, after torrent download completed and --seed-time and
  2621. --seed-ratio conditions are fulfilled, following message is printed
  2622. right after "Download complete: .....":
  2623. Your share ratio was 1.0, uploaded/downloaded=12M/12M
  2624. * src/RequestGroupMan.cc
  2625. * src/RequestGroup.{h, cc}
  2626. * src/message.h
  2627. 2007-12-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2628. Remove a defunct control file. A defunct control file means that while
  2629. it exists, but the corresponding download file is missing.
  2630. After its removal, a download restarts from the beginning.
  2631. * src/RequestGroup.cc
  2632. * src/message.h
  2633. 2007-12-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2634. Allocate bitfield in Peer when it is really used. More specifically,
  2635. bitfield in Peer is allocated after the connection is established and
  2636. deallocated when the connection is dropped.
  2637. Since 2 parameters(piece length and total length) was removed from the
  2638. constructor of Peer class, many test classes were modified accordingly.
  2639. See svn log for more detailed information.
  2640. * src/PeerInteractionCommand.cc
  2641. * src/CompactPeerListProcessor.cc
  2642. * src/Peer.cc
  2643. * src/DefaultPeerListProcessor.cc
  2644. * src/PeerListenCommand.cc
  2645. * src/PeerReceiveHandshakeCommand.cc
  2646. Fixed memory leak
  2647. * src/Piece.cc
  2648. 2007-12-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2649. Changed the default value of PREF_PEER_CONNECTION_TIMEOUT and
  2650. lowestSpeedLimit in ActivePeerConnectionCommand. TODO: Make them
  2651. command-line options.
  2652. * src/option_processing.cc
  2653. * src/ActivePeerConnectionCommand.cc
  2654. 2007-12-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2655. Send have message to peer if it already has the piece.
  2656. * src/BtHaveMessage.{h, cc}
  2657. 2007-12-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2658. Removed incomingPeer. Set 0 to peer's port if it is not a listening
  2659. port.
  2660. * src/DefaultPeerStorage.{h, cc}
  2661. * test/DefaultPeerStorageTest.cc
  2662. * src/HandshakeExtensionMessage.cc
  2663. * test/HandshakeExtensionMessageTest.cc
  2664. * src/Peer.{h, cc}: Added ipaddr and port to identity comparison.
  2665. * src/PeerStorage.h
  2666. * test/MockPeerStorage.h
  2667. * src/PeerListenCommand.cc
  2668. * src/PeerReceiveHandshakeCommand.cc
  2669. 2007-12-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2670. Added --metalink-enable-unique-protocol option.
  2671. * src/Metalink2RequestGroup.cc
  2672. * src/option_processing.cc
  2673. * src/prefs.h
  2674. * src/version_usage.cc
  2675. * doc/aria2c.1.txt
  2676. * doc/aria2c.1
  2677. 2007-12-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2678. Allow a peer in incomingPeer to be added peers.
  2679. * src/DefaultPeerStorage.cc
  2680. * test/DefaultPeerStorageTest.cc
  2681. 2007-12-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2682. Fixed the bug that causes aria2 not to finish download. BUG#1855875.
  2683. I could reproduce this bug in following procedure:
  2684. 1. Stop the download at the very beginning(1% or 100KB downloaded).
  2685. 2. Restart aria2.
  2686. 3. You see the download stopped around 99%.
  2687. * src/HttpResponseCommand.cc (handleDefaultEncoding)
  2688. * src/StreamFileAllocationEntry.cc: Removed the timeout handling.
  2689. If timeout is reached, then _nextCommand is unused and it may contains
  2690. segments and they won't be canceled. Actually, timeout is not needed
  2691. here because if the server dropped connection, then retry is made.
  2692. 2007-12-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2693. Added uTorrent compatible Peer Exchange.
  2694. * src/BencodeVisitor.{h, cc}
  2695. * test/BencodeVisitorTest.cc
  2696. * src/BtConstants.h
  2697. * src/BtContext.h: Added 'private' flag.
  2698. * src/BtExtendedMessage.{h, cc}
  2699. * test/BtExtendedMessageTest.cc
  2700. * src/BtHandshakeMessage.{h, cc}: Set extended messaging bit in
  2701. reserved field.
  2702. * test/BtHandshakeMessageTest.cc
  2703. * src/BtMessageFactory.h
  2704. * src/BtRegistry.h
  2705. * src/BtRuntime.h: This class holds default extension message IDs for
  2706. aria2. By default, aria2 uses ID 8 for ut_pex.
  2707. * src/DefaultBtContext.cc
  2708. * src/DefaultBtInteractive.{h, cc}: This class holds _utPexEnabled.
  2709. When it is true, aria2 enables ut_pex. This value is set by
  2710. PeerInteractionCommand.
  2711. * src/DefaultBtMessageFactory.{h, cc}
  2712. * test/DefaultBtMessageFactoryTest.cc
  2713. * src/DefaultBtMessageReceiver.cc: Moved the code of fast extension
  2714. handling to DefaultBtInteractive class.
  2715. * src/DefaultExtensionMessageFactory.{h, cc}
  2716. * test/DefaultExtensionMessageFactoryTest.cc
  2717. * src/DefaultPeerStorage.cc: Returns false if a peer is already in
  2718. the container(peers and incomingPeers. The equality is determined by
  2719. Peer::id).
  2720. * test/DefaultPeerStorageTest.cc
  2721. * src/ExtensionMessage.h
  2722. * test/MockExtensionMessage.h
  2723. * src/ExtensionMessageFactory.h
  2724. * test/MockExtensionMessageFactory.h
  2725. * src/HandshakeExtensionMessage.{h, cc}
  2726. * test/HandshakeExtensionMessageTest.cc
  2727. * src/MetaEntry.h
  2728. * src/Peer.{h, cc}
  2729. * src/PeerInteractionCommand.cc
  2730. * src/PeerReceiveHandshakeCommand.cc: Evaluate the return value of
  2731. addIncomingPeer.
  2732. * src/PeerMessageUtil.{h, cc}
  2733. * src/PeerObject.h
  2734. * src/UTPexExtensionMessage.{h, cc}
  2735. * test/UTPexExtensionMessageTest.cc
  2736. * src/message.h
  2737. * src/prefs.h
  2738. Fixed the bug that returns incomplete data when it contains null
  2739. character. A convenient constructor was also added.
  2740. * src/Data.{h, cc}
  2741. Rewritten.
  2742. * src/CompactPeerListProcessor.cc
  2743. Fixed typos.
  2744. * src/message.h
  2745. * src/MetaFileUtil.cc
  2746. 2007-12-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2747. Added "Status Legend" label to the explanation text of 'stat' in
  2748. download result and moved it to the last. BUG#1848214
  2749. * src/RequestGroupMan.cc
  2750. 2007-12-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2751. Fixed the bug that -lexpat is always added to aria2c_LDADD.
  2752. * src/Makefie.am
  2753. * test/Makefile.am
  2754. 2007-12-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2755. Fixed the bug that prevents aria2 from loading cookie file when expire
  2756. value is greater than 2^31-1. BUG#1851066
  2757. * src/CookieBoxFactory.cc
  2758. * test/CookieBoxFactoryTest.cc
  2759. 2007-12-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2760. Fixed possible memory leak when an exception is thrown.
  2761. * src/XML2SAXMetalinkProcessor.cc
  2762. Added Expat support. If both libxml2 and Expat are installed, then
  2763. libxml2 is used by default.
  2764. MetalinkProcessorFactory chooses from XML2SAXMetalinkProcessor and
  2765. ExpatMetalinkProcessor according to the configuration.
  2766. * src/ExpatMetalinkProcessor.{h, cc}
  2767. * src/main.cc: Removed libxml2 specific header and init/free function.
  2768. * src/MetalinkProcessorFactory.{h, cc}
  2769. * src/MetalinkHelper.cc
  2770. * src/Metalinker.h: Removed unnecessary libxml2 header.
  2771. * src/MetalinkProcessor.h
  2772. * test/XML2SAXMetalinkProcessorTest.cc: Removed because
  2773. MetalinkProcessorTest is used instead.
  2774. * test/MetalinkProcessorTest.cc: Added. It is actually the same with
  2775. XML2SAXMetalinkProcessor, replaced XML2SAXMetalinkProcessor with
  2776. MetalinkProcessorFactory::newInstance().
  2777. * m4/libexpat.m4
  2778. * configure.ac: Added configuration options for libexpat.
  2779. 2007-12-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2780. Disabled -s option in metalink download.
  2781. * src/Metalink2RequestGroup.cc
  2782. 2007-12-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2783. If several protocols are available for a mirror in metalink file,
  2784. aria2 now use one of them. --metalink-preferred-protocol option was
  2785. added to specify the preference of protocol.
  2786. * src/AbstractCommand.cc
  2787. * src/OptionHandlerFactory.cc
  2788. * src/ServerHost.{h, cc}
  2789. * src/Metalink2RequestGroup.cc
  2790. * src/RequestGroup.{h, cc}
  2791. * test/RequestGroupTest.cc
  2792. * src/option_processing.cc
  2793. * src/prefs.h
  2794. * src/HttpResponseCommand.cc
  2795. * src/MetalinkResource.{h, cc}
  2796. * src/FtpNegotiationCommand.cc
  2797. * src/MetalinkEntry.{h, cc}
  2798. * src/MetalinkEntryTest.cc
  2799. 2007-12-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2800. Code cleanup and added debug log.
  2801. * src/PeerConnection.cc
  2802. 2007-12-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2803. Compiler error fix: applied the patch by Tiziano Mueller
  2804. * src/RequestGroup.cc
  2805. 2007-12-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2806. Fixed the bug: only first announce URL is tried in AnnounceTier,
  2807. in stopped and completed event.
  2808. * src/AnnounceList.{h, cc}
  2809. * test/AnnounceListTest.cc
  2810. * src/DefaultBtAnnounce.cc
  2811. * test/DefaultBtAnnounceTest.cc
  2812. Sorted URLs.
  2813. * test/Metalink2RequestGroupTest.cc
  2814. 2007-12-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2815. Removed unnecessary string copy. Updated doc and corrected indentation.
  2816. * src/Base64.cc
  2817. Fixed compilation warnings
  2818. * test/DataTest.cc
  2819. * test/HttpRequestTest.cc
  2820. * test/MetaFileUtilTest.cc
  2821. * test/RequestTest.cc
  2822. * Release 0.12.0
  2823. 2007-12-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2824. Updated translations
  2825. * po/{de,fr,ja,nl,ru}.po
  2826. Added Brazilian Portuguese, Catalan, Italian, Spanish, Swedish
  2827. translations. Many thanks to translators.
  2828. * po/{ca,es,it,pt_BR,sv}.po
  2829. * po/LINGUAS
  2830. 2007-12-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2831. Added a notice about URL
  2832. * src/version_usage.cc
  2833. 2007-12-07 Tatsuhiro Tsujikawa <tujikawa at rednoah com>
  2834. Fixed the bug#1845750; CTRL+C does not stop torrent.
  2835. aria2 repeatedly sends stopped request when tracker returns error code.
  2836. * src/AnnounceList.cc
  2837. * test/AnnounceListTest.cc
  2838. * src/AnnounceTier.h
  2839. Added a message when ctrl-c is hit.
  2840. Now second ctrl-c is also handled in signal handler.
  2841. * src/RequestGroupMan.{h, cc}
  2842. * src/RequestGroup.{h, cc}
  2843. * src/MultiUrlRequestInfo.cc
  2844. * src/DownloadEngine.cc
  2845. * src/TrackerWatcherCommand.cc
  2846. 2007-12-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2847. Code cleanup
  2848. * src/Base64.cc (encode)
  2849. 2007-12-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2850. Changed Direct/IO enable/disable procesure in file allocation routine.
  2851. * src/SingleFileAllocationIterator.cc
  2852. (SingleFileAllocationIterator):
  2853. Disable directIO if offset is not multiple of 512.
  2854. (~SingleFileAllocationIterator): Removed a call to disableDirectIO.
  2855. * src/MultiFileAllocationIterator.cc (allocateChunk):
  2856. Enable created SingleFileAllocationIterator's directIO.
  2857. * src/FileAllocationEntry.cc
  2858. (FileAllocationEntry): Enable directIO here.
  2859. (~FileAllocationEntry): Disable directIO here.
  2860. 2007-12-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2861. Fixed the bug: aria2 doesn't utilize fast set index offered by peer.
  2862. * src/Peer.{h, cc}
  2863. * src/DefaultPieceStorage.cc
  2864. * test/DefaultPieceStorageTest.cc
  2865. 2007-12-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2866. Rewritten direct I/O support routine
  2867. * src/SingleFileAllocationIterator.cc
  2868. * src/MultiDiskAdaptor.{h, cc}
  2869. * src/ByteArrayDiskWriter.h
  2870. * src/AbstractSingleDiskAdaptor.h
  2871. * src/AbstractDiskWriter.cc
  2872. * src/DefaultPieceStorage.cc
  2873. * src/DiskWriter.h
  2874. * src/BinaryStream.h
  2875. * src/IteratableChunkChecksumValidator.cc
  2876. * src/IteratableChecksumValidator.cc
  2877. * src/CheckIntegrityEntry.cc
  2878. * src/FileAllocationEntry.cc
  2879. 2007-12-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2880. Fixed typo
  2881. * src/version_usage.cc
  2882. Updated doc
  2883. * doc/aria2c.1.txt
  2884. * doc/aria2c.1
  2885. 2007-12-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2886. Fixed compile error without message digest support.
  2887. * src/FileMetalinkParserState.cc
  2888. * src/MetalinkParserController.{h, cc}
  2889. * test/XML2SAXMetalinkProcessorTest.cc
  2890. * test/MetalinkParserControllerTest.cc
  2891. 2007-12-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2892. Enable direct I/O support in checksum checking.
  2893. * src/IteratableChunkChecksumValidator.{h, cc}
  2894. * test/IteratableChunkChecksumValidatorTest.cc
  2895. * src/CheckIntegrityEntry.cc
  2896. * src/PieceHashCheckIntegrityEntry.cc
  2897. * src/IteratableChecksumValidator.{h, cc}
  2898. * src/BtCheckIntegrityEntry.cc: Added doc.
  2899. 2007-12-04 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2900. Added --allow-piece-length-change option.
  2901. * src/DefaultBtProgressInfoFile.cc
  2902. * test/DefaultBtProgressInfoFileTest.cc
  2903. * src/OptionHandlerFactory.cc
  2904. * src/option_processing.cc
  2905. * src/prefs.h
  2906. * src/version_usage.cc
  2907. * doc/aria2c.1.txt
  2908. * doc/aria2c.1
  2909. Fixed: duplicated result entry appears when exception is thrown in
  2910. RequestGroup::createInitiateConnectionCommand().
  2911. * src/RequestGroupMan.cc (fillRequestGroupFromReserver):
  2912. Add RequestGroup to _requestGroup after RequetGroup::
  2913. createInitiateConnectionCommand() succeeds.
  2914. Externalized message
  2915. * src/XML2SAXMetalinkProcessor.cc
  2916. * src/message.h
  2917. 2007-12-04 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2918. Forced download abort when received negative response from http/ftp
  2919. server.
  2920. * src/HttpResponseCommand.cc
  2921. * src/FtpNegotiationCommand.cc
  2922. * src/HttpResponse.cc
  2923. * src/FtpConnection.cc
  2924. 2007-12-04 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2925. Added XML2SAXMetalinkProcessor class, which is a lot faster than
  2926. the predecessor, Xml2MetalinkParser class.
  2927. I tested them against 94KB metalink file with 1234 chunk checksums.
  2928. The new one parsed it in 22msec, while it took 6000msec with old one.
  2929. * src/XML2SAXMetalinkProcessor.{h, cc}
  2930. * test/XML2SAXMetalinkProcessorTest.cc
  2931. * src/MetalinkParserController.{h, cc}
  2932. * test/MetalinkParserControllerTest.cc
  2933. * src/MetalinkParserState.h: Also added 16 subclasses.
  2934. * src/main.cc
  2935. * src/Metalink2RequestGroup.cc
  2936. * src/MetalinkHelper.cc
  2937. * src/MetalinkEntry.cc
  2938. * src/ChunkChecksum.h
  2939. Rewritten Base64 class for better performance.
  2940. * src/Base64.{h, cc}
  2941. * test/Base64Test.cc
  2942. * src/HttpRequest.cc
  2943. 2007-12-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2944. Fixed the bug#1841757: aria2 will connect to server to only get
  2945. file size.
  2946. * src/StreamFileAllocationEntry.cc
  2947. * src/option_processing.cc
  2948. * src/HttpResponseCommand.cc: Now reuse connection in segmented
  2949. downloads.
  2950. * src/FtpNegotiationCommand.cc
  2951. Suppressed wrong message when finding PreDownloadHandler
  2952. * src/RequestGroup.cc
  2953. 2007-11-29 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2954. Updated usage
  2955. * src/version_usage.cc
  2956. Updated man page
  2957. * doc/aria2c.1.txt
  2958. * doc/aria2c.1
  2959. Updated po files
  2960. * po/aria2c.pot
  2961. * po/*.po
  2962. * po/*.gmo
  2963. 2007-11-29 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2964. Eliminated g++-4.2 warning
  2965. * src/DownloadHandlerConstants.{h, cc}
  2966. * src/Util.cc
  2967. * test/MetaFileUtilTest.cc
  2968. * test/PStringBuildVisitorTest.cc
  2969. Fixed bug: --check-integrity doesn't work for multi file torrent.
  2970. * src/RequestGroup.cc
  2971. * src/BtCheckIntegrityEntry.cc
  2972. 2007-11-29 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2973. Fixed a2io.h
  2974. * src/a2io.h
  2975. 2007-11-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  2976. Added direct I/O support. The current implementation uses O_DIRECT,
  2977. which is not posix standard and is tested on linux 2.6.21.
  2978. Currently only file allocation uses direct I/O.
  2979. * src/SingleFileAllocationIterator.{h, cc}
  2980. * test/SingleFileAllocationIteratorTest.cc
  2981. * src/MultiFileAllocationIterator.{h, cc}
  2982. * test/MultiFileAllocationIteratorTest.cc
  2983. * src/BinaryStream.h
  2984. * src/DiskWriter.h
  2985. * src/AbstractDiskWriter.{h, cc}
  2986. * src/ByteArrayDiskWriter.h
  2987. * src/DiskAdaptor.h
  2988. * src/AbstractSingleDiskAdaptor.{h, cc}
  2989. * src/MultiDiskAdaptor.{h, cc}
  2990. * src/FileAllocationEntry.cc
  2991. * src/Util.{h, cc}
  2992. * src/OptionHandlerFactory.cc
  2993. * src/prefs.h
  2994. * src/version_usage.cc
  2995. * src/option_processing.cc
  2996. Moved FileAllocationMan::markCurrentFileAllocationEntryDone() to
  2997. handleException.
  2998. * src/MultiFileAllocationIterator.cc
  2999. Added EINTR handling
  3000. * src/SocketCore.cc
  3001. 2007-11-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3002. Updated usage
  3003. * src/version_usage.cc
  3004. 2007-11-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3005. Applied Ross's patch for MinGW port.
  3006. * src/DownloadEngine.h
  3007. 2007-11-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3008. Set Content-Type to SingleFileDownloadContext when http response is
  3009. received.
  3010. * src/HttpResponseCommand.cc
  3011. * src/HttpResponse.{h, cc}
  3012. * test/HttpResponseTest.cc
  3013. 2007-11-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3014. Rewritten to add content-type support.
  3015. * src/DownloadHandler.{h, cc}
  3016. * src/BtPostDownloadHandler.{h, cc}
  3017. * test/BtPostDownloadHandlerTest.cc
  3018. * src/MetalinkPostDownloadHandler.{h, cc}
  3019. * test/MetalinkPostDownloadHandlerTest.cc
  3020. * src/PostDownloadHandler.{h, cc}
  3021. * src/DownloadHandlerConstants.{h, cc}
  3022. * src/RequestGroup.cc
  3023. * src/HttpResponseCommand.cc
  3024. * src/FtpNegotiationCommand.cc
  3025. * src/SingleFileDownloadContext.{h, cc}
  3026. * src/RequestGroup.h
  3027. * src/RequestGroupCriteria.h
  3028. * src/ContentTypeRequestGroupCriteria.h
  3029. Added 'mem' option value for --follow-metalink, --follow-torrent.
  3030. If it is give, metalink/torrent file is not written to the disk, but
  3031. just is kept in memory. Parsing is occurred on memory.
  3032. * src/MetalinkHelper.{h, cc}
  3033. * src/MetalinkProcessor.h
  3034. * src/Xml2MetalinkProcessor.{h, cc}
  3035. * test/Xml2MetalinkProcessorTest.cc
  3036. * src/DownloadHandlerFactory.{h, cc}
  3037. * test/DownloadHandlerFactoryTest.cc
  3038. * src/PreDownloadHandler.{h, cc}
  3039. * src/OptionHandlerFactory.cc
  3040. * src/DefaultBtContext.{h, cc}
  3041. * test/DefaultBtContextTest.cc
  3042. * src/version_usage.cc
  3043. * src/Metalink2RequestGroup.{h, cc}
  3044. * src/RequestGroup.{h, cc}
  3045. * src/a2functional.h
  3046. * test/a2functionalTest.cc
  3047. * src/MemoryBufferPreDownloadHandler.{h, cc}
  3048. * src/OptionHandlerImpl.h
  3049. * src/prefs.h
  3050. * src/Util.{h, cc}
  3051. * test/UtilTest.cc
  3052. Keep DownloadResult rather than RequestGroup after downloads to reduce
  3053. memory usage.
  3054. * src/RequestGroupMan.{h, cc}
  3055. * src/DownloadEngine.cc
  3056. * src/BtDependency.{h, cc}: Changed the type of dependee from
  3057. WeakHandle to SharedHandle because WeakHandle could be null.
  3058. * src/RequestGroup.{h, cc}
  3059. * src/DownloadEngineFactory.cc
  3060. * src/DownloadResult.h
  3061. Set totalLength after download finished
  3062. * src/UnknownLengthPieceStorage.{h, cc}
  3063. Keep torrent file specified in metalink in memory.
  3064. * src/Metalink2RequestGroup.cc
  3065. * src/BtDependency.cc
  3066. * src/TrueRequestGroupCriteria.h
  3067. Fixed the bug: seekg is used where seekp should be used.
  3068. * src/ByteArrayDiskWriter.cc
  3069. * test/ByteArraydiskWriterTest.cc
  3070. 2007-11-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3071. Fixed syntax error
  3072. * test/SequenceTest.cc
  3073. 2007-11-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3074. Return false if RequestGroup::isPreLocalFileCheckEnabled() == true
  3075. * src/RequestGroupMan.cc (isSameFileBeingDownloaded)
  3076. Return false if RequestGroup::isPreLocalFileCheckEnabled() == true
  3077. * src/RequestGroup.cc (downloadFinishedByFileLength)
  3078. 2007-11-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3079. Added the check to see whether ares_host_callback accepts timeouts
  3080. with c-ares; only c-ares 1.5.0 or newer accepts it.
  3081. * src/NameResolver.{h, cc}
  3082. * m4/libcares.m4
  3083. * configure.ac: Set C++ for language choice.
  3084. 2007-11-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3085. Fixed: compilation fails without c-ares/ares
  3086. * src/DownloadEngine.cc (addCommand): Moved outside #ifdef
  3087. Generate http/ftp commands only when download is incomplete.
  3088. * src/BtFileAllocationEntry.cc (prepareForNextAction)
  3089. 2007-11-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3090. Corrected typo. Examples are removed since they are available in man
  3091. page.
  3092. * src/version_usage.cc
  3093. Updated man page.
  3094. * doc/aria2c.1
  3095. * doc/aria2c.1.txt
  3096. * doc/makeman: Commented out sed command.
  3097. 2007-11-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3098. Throw DlAbortEx when a remote file is not found.
  3099. * src/HttpResponse.cc
  3100. * src/FtpNegotiationCommand.cc
  3101. * src/message.h
  3102. Overwrite an existing file if --allow-overwrite=true is given.
  3103. * src/RequestGroup.cc
  3104. Removed unused functions
  3105. * src/AbstractCommand.h
  3106. 2007-11-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3107. Removed 'extern' from 'extern typedef ...' in src/*.h
  3108. 2007-11-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3109. Updated usage
  3110. * src/version_usage.cc
  3111. 2007-11-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3112. Trim announce URL
  3113. * src/DefaultBtContext.cc
  3114. * test/ShaVisitorTest.cc
  3115. Trim argument s. Give trimed s to exception constructor.
  3116. * src/Util.cc (parseInt)(parseLLInt)
  3117. * test/UtilTest.cc
  3118. 2007-11-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3119. Set precision back to 1.
  3120. * src/ConsoleStatCalc.cc (calculateStat)
  3121. 2007-11-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3122. Replaced strtol with Util::parseInt
  3123. * src/ChunkedEncoding.cc
  3124. * src/HttpConnection.cc
  3125. * src/CookieBoxFactory.cc
  3126. * src/ParameterizedStringParser.cc
  3127. * src/Util.cc
  3128. * test/UtilTest.cc
  3129. * test/OptionHandlerTest.cc
  3130. * src/Request.cc
  3131. Throw exception when empty string is given. The message for exception
  3132. changed.
  3133. * src/Util.cc (parseInt)(parseLLInt)
  3134. * src/message.h
  3135. 2007-11-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3136. Set precision to 2 because share ratio is rounded into 1.0 if precision
  3137. set to 1.
  3138. * src/ConsoleStatCalc.cc (calculateStat)
  3139. 2007-11-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3140. Preallocate non-requested file which is adjacent forward to requested
  3141. file('requested' files means the files given in --select-file option)
  3142. if they share a same piece.
  3143. This fixes long pause in the file system which doesn't support sparse
  3144. files like FAT32 while downloading.
  3145. * src/MultiFileAllocationIterator.{h, cc}
  3146. * test/MultiFileAllocationIteratorTest.cc
  3147. * src/FileEntry.{h, cc}
  3148. Removed unused _option.
  3149. * src/MultiDiskAdaptor.h
  3150. * test/MultiDiskAdaptorTest.cc
  3151. * src/DefaultPieceStorage.cc
  3152. Set the default value of --seed-ratio to 1.0.
  3153. If 0.0 is given, then seeding continues regardless of share ratio.
  3154. * src/version_usage.cc
  3155. * src/option_processing.cc
  3156. * src/BtSetup.cc
  3157. * doc/aria2c.1.txt
  3158. * doc/aria2c.1
  3159. Fixed: Selective download is not working in BitTorrent
  3160. * src/RequestGroup.cc
  3161. Introduced Sequence class. Use this instead of Util::unfoldRange()
  3162. * src/PieceStorage.h
  3163. * test/MockPieceStorage.h
  3164. * src/UnknownLengthPieceStorage.h
  3165. * src/DefaultPieceStorage.{h, cc}
  3166. * src/Metalink2RequestGroup.cc
  3167. * src/RequestGroup.cc
  3168. * src/Sequence.h
  3169. * test/SequenceTest.cc
  3170. * src/IntSequence.h
  3171. * src/message.h
  3172. * src/Util.{h, cc}
  3173. * test/UtilTest.cc
  3174. Added new function 'parse' to catch exception thrown by subclass's
  3175. parseArg
  3176. * src/OptionHandler.h
  3177. * src/OptionParser.cc
  3178. * src/NameMatchOptionHandler.h
  3179. * src/OptionHandlerImpl.h
  3180. * test/OptionHandlerTest.cc
  3181. Added IntegerRangeOptionHandler. Used for --listen-port and
  3182. --select-file. Now --listen-port accepts range of port.
  3183. * src/OptionHandlerFactory.cc
  3184. * src/version_usage.cc
  3185. * src/OptionHandlerImpl.h
  3186. * src/option_processing.cc
  3187. * src/BtSetup.cc
  3188. * src/PeerListenCommand.{h, cc}
  3189. * doc/aria2c.1.txt
  3190. * doc/aria2c.1
  3191. Implemented operator< for Exception class to provide easy way to print
  3192. exception stack trace.
  3193. * src/Exception.{h, cc}
  3194. * src/main.cc
  3195. * src/option_processing.cc
  3196. 2007-11-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3197. * src/version_usage.cc
  3198. (showVersion): Reworked.
  3199. (showUsage): Added examples.
  3200. Removed Hint for total length and file name.
  3201. * src/Metalink2RequestGroup.cc
  3202. * src/RequestGroup.{h, cc}
  3203. * src/HttpResponseCommand.cc
  3204. * src/FtpNegotiationCommand.cc
  3205. Now --follow-torrent and --follow-metalink option work properly.
  3206. * src/RequestGroup.cc
  3207. Updated man page
  3208. * doc/aria2c.1.txt
  3209. * doc/aria2c.1
  3210. 2007-11-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3211. Removed.
  3212. * src/PiecedSegment.{h, cc} (operator==)(operator!=)
  3213. Use Segment::operator==()
  3214. * src/HttpConnection.cc
  3215. * src/Segment.h
  3216. Updated usage
  3217. * src/version_usage.cc
  3218. Added EINTR treatment.
  3219. * src/SocketCore.cc
  3220. * src/AbstractDiskWriter.cc
  3221. Rewritten.
  3222. * src/Util.cc (rangedFileCopy)
  3223. 2007-11-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3224. Fixed typo.
  3225. * src/version_usage.cc
  3226. 2007-11-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3227. Implemented. Now -c option works fine.
  3228. * src/DefaultPieceStorage.cc (markPiecesDone)
  3229. * test/DefaultPieceStorageTest.cc
  3230. Removed.
  3231. * src/SegmentMan.{h, cc}
  3232. (markAllPiecesDone)
  3233. (markPieceDone)
  3234. Synchronized po files with
  3235. https://translations.launchpad.net/aria2/trunk/+pots/aria2c
  3236. * src/fr.po
  3237. * src/ru.po
  3238. * src/de.po
  3239. * src/ja.po
  3240. 2007-11-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3241. Added ifdef and some modifications to compile without BitTorrent,
  3242. Metalink, MessageDigest
  3243. support.
  3244. * src/PieceHashCheckIntegrityEntry.cc
  3245. * src/MetalinkEntry.h
  3246. * src/version_usage.cc
  3247. * src/main.cc
  3248. * src/DownloadEngine.{h, cc}
  3249. * src/Metalink2RequestGroup.cc
  3250. * src/Peer.cc
  3251. * src/RequestGroup.cc
  3252. * src/MetalinkHelper.cc
  3253. * test/DefaultPieceStorageTest.cc
  3254. * test/MetalinkPostDownloadHandlerTest.cc
  3255. * test/Metalink2RequestGroupTest.cc
  3256. Hide TOTAL SPD when all downloads complete.
  3257. * src/ConsoleStatCalc.cc
  3258. Log target system information.
  3259. * src/main.cc
  3260. 2007-11-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3261. Now --metalink-location accepts a comma-deliminated list of locations.
  3262. * src/MetalinkEntry.{h, cc}
  3263. * test/MetalinkEntryTest.cc
  3264. * src/version_usage.cc
  3265. * src/Metalink2RequestGroup.cc
  3266. * src/Xml2MetalinkProcessor.cc
  3267. * test/Xml2MetalinkProcessorTest.cc
  3268. * doc/aria2c.1.txt
  3269. * doc/aria2c.1
  3270. * src/Util.cc (toUpper)(toLower): Rewritten.
  3271. 2007-11-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3272. Added the ability to detect duplicate download entry which is about to
  3273. download the same file other RequestGroup is downloading.
  3274. * src/RequestGroup.cc
  3275. * src/HttpResponseCommand.cc
  3276. * src/FtpNegotiationCommand.cc
  3277. 2007-11-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3278. Recalculates download progress when loading a control file,
  3279. if the piece length of DownloadContext is different from the one saved
  3280. in the control file. Currently in-flight pieces are ignored.
  3281. * src/DefaultBtProgressInfoFile.cc
  3282. * test/DefaultBtProgressInfoFileTest.cc
  3283. * src/Util.{h, cc}
  3284. * test/UtilTest.cc
  3285. 2007-11-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3286. Do not rotate tiers in announce-list.
  3287. * src/DefaultBtAnnounce.{h, cc}: Removed trackerNumTry.
  3288. AnnounceList::allTiersFailed() used instead to detect whether all
  3289. tiers are tried and failed.
  3290. * test/DefaultBtAnnounceTest.cc
  3291. * src/AnnounceList.{h, cc}: If all tiers are tried and failed then
  3292. allTiersFailed() returns true. To reset tier pointer, call resetTier();
  3293. * test/AnnounceListTest.cc
  3294. * src/TrackerWatcherCommand.cc (execute): Removed DlAbortEx catch
  3295. clause. Catch RecoverableException instead of DlRetryEx instead.
  3296. 2007-11-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3297. Implemented checksum validation feature(1 checksum for each file)
  3298. The validation takes place after the download.
  3299. * src/PieceHashCheckIntegrityEntry.{h, cc}: New class.
  3300. * src/IteratableChecksumValidator.{h, cc}: Rewritten.
  3301. * src/CheckIntegrityCommand.cc: Changed log message.
  3302. * src/Metalink2RequestGroup.cc: Set checksum to
  3303. SingleFileDownloadContext.
  3304. * src/StreamCheckIntegrityEntry.{h, cc}: Now derived from
  3305. PieceHashCheckIntegrity class.
  3306. * src/BtCheckIntegrityEntry.{h, cc}: Now derived from
  3307. PieceHashCheckIntegrity class.
  3308. * src/ChecksumCheckIntegrityEntry.{h, cc}: New class.
  3309. * src/IteratableValidator.h: New class.
  3310. * src/message.h
  3311. * src/CheckIntegrityEntry.{h, cc}
  3312. * src/IteratableChunkChecksumValidator.{h, cc}
  3313. * src/SingleFileDownloadContext.h
  3314. * src/DownloadCommand.cc
  3315. --allow-overwrite=true is no longer needed to check file integrity
  3316. before download in BitTorrent download.
  3317. * src/RequestGroup.cc (getInitialCommand)
  3318. Removed RequestGroup from queue when RequestGroup::getInitialCommand()
  3319. throws exception.
  3320. * src/RequestGroupMan.cc (getInitialCommands)
  3321. 2007-11-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3322. urlencode the given url inside Request::parseUrl(...)
  3323. * src/Request.{h, cc}
  3324. * src/Util.{h, cc}
  3325. * test/RequestTest.cc
  3326. Removed #!metalink3! notation support because it is deleted from
  3327. the metalink specification.
  3328. * src/Request.{h, cc}
  3329. * test/RequestTest.cc
  3330. 2007-11-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3331. Don't connect server before checking file integrity at startup, if
  3332. filesize and output file path are known.
  3333. * src/AbstractCommand.cc
  3334. * src/StreamFileAllocationEntry.cc
  3335. * src/Metalink2RequestGroup.cc
  3336. * src/RequestGroup.{h, cc}
  3337. * src/HttpResponseCommand.cc
  3338. * src/FtpNegotiationCommand.cc
  3339. Added DownloadFailureException. If it is thrown, RequestGroup should
  3340. halt.
  3341. * src/AbstractCommand.cc
  3342. * src/DownloadFailureException.h
  3343. * src/RequestGroup.cc
  3344. Catch RecoverableException, instead of DlAbortEx.
  3345. * src/RequestGroupMan.cc
  3346. * src/FillRequestGroupCommand.cc
  3347. * src/MetaFileUtil.cc
  3348. * src/IteratableChunkChecksumValidator.cc
  3349. Now first parameter of MSG_DOWNLOAD_ABORTED is gid(RequestGroup::
  3350. getGID())
  3351. * src/CheckIntegrityCommand.cc
  3352. * src/message.h
  3353. Print gid instead of idx.
  3354. * src/RequestGroupMan.cc
  3355. Removed exception throwers declaration.
  3356. * src/DirectDiskAdaptor.{h, cc}
  3357. * src/SocketCore.{h, cc}
  3358. * src/MultiDiskAdaptor.{h, cc}
  3359. * src/HttpConnection.{h, cc}
  3360. * src/HttpResponse.{h, cc}
  3361. * src/DiskAdaptor.{h, cc}
  3362. * src/CopyDiskAdaptor.{h, cc}
  3363. * src/MultiDiskAdaptor.{h, cc}
  3364. * src/HttpHeaderProcessor.{h, cc}
  3365. * src/AbstractSingleDiskAdaptor.{h, cc}
  3366. * src/Util.{h, cc}
  3367. * test/UtilTest.cc
  3368. * src/DefaultDiskWriter.{h, cc}
  3369. * src/FtpConnection.{h, cc}
  3370. * src/AbstractDiskWriter.{h, cc}
  3371. Removed duplicate code.
  3372. * src/StreamCheckIntegrityEntry.cc
  3373. Removed unnecessary include.
  3374. * src/DiskWriter.h
  3375. Included Exception.h
  3376. * src/option_processing.cc
  3377. Included 2 files and added doc
  3378. * src/TrackerWatcherCommand.cc
  3379. * src/SocketCore.cc (writeData): Fixed send error with GnuTLS.
  3380. 2007-11-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3381. Changed CheckIntegrityEntry interface so that it can define
  3382. the action when all the chunk checksums are valid.
  3383. * src/CheckIntegrityEntry.h
  3384. * src/StreamCheckIntegrityEntry.{h, cc}
  3385. * src/BtCheckIntegrityEntry.{h, cc}: Currently,when all the checksums
  3386. are valid, then aira2 goes to seeding mode. Sometimes it is better
  3387. to exit rather than doing seeding. So, it would be good to toggle this
  3388. behavior.
  3389. * src/CheckIntegrityCommand.cc
  3390. * src/AbstractCommand.cc
  3391. * src/RequestGroup.cc
  3392. 2007-11-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3393. Reflect the download length of in-flight pieces.
  3394. It makes the download length readout more precise.
  3395. * src/DefaultPieceStorage.{h, cc}
  3396. * test/DefaultPieceStorageTest.cc
  3397. * src/a2functional.h
  3398. * test/a2functionalTest.cc
  3399. Lower CPU load when --max-download-limit is used.
  3400. There is up and down in speed indicator when enabling
  3401. http-pipelining but a download goes well. I think the problem is that
  3402. because http-pipelining is enabled, DownloadCommand is created for
  3403. each segment and in its constructor, PeerStat::downloadStart() is
  3404. called. In PeerStat::downloadStart(), speed calculation object is
  3405. reseted, which makes download speed zero.
  3406. * src/DownloadCommand.cc
  3407. Rewritten using accumulate.
  3408. * src/RequestGroupMan.cc (calculateStat)
  3409. Code clearnup.
  3410. * src/FtpNegotiationCommand.cc
  3411. * src/HttpResponseCommand.cc
  3412. 2007-11-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3413. Fixed: Can not resume: aria2 reports download already finished.
  3414. * src/AbstractCommand.{h, cc}
  3415. * src/HttpResponseCommand.cc
  3416. * src/FtpNegotiateCommand.cc
  3417. 2007-11-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3418. Now a file is stored in the directory specified in .metalnk file
  3419. (file[@name]).
  3420. * src/Metalink2RequestGroup.cc
  3421. Create the directory structure when opening the file if it doesn't
  3422. exist.
  3423. * src/AbstractDiskWriter.cc
  3424. * src/Util.{h, cc}
  3425. * src/File.h
  3426. * test/UtilTest.cc
  3427. Removed file name comparison
  3428. * src/Metalink2RequestGroup.cc
  3429. * src/HttpResponseCommand.cc
  3430. Rewritten using Util::mkdirs()
  3431. * src/FileEntry.cc (setupDir)
  3432. * test/FileEntryTest.cc
  3433. Updated doc
  3434. * src/SingleFileDownloadContext.h
  3435. 2007-11-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3436. Now SleepCommand dispatches nextCommand when halt is requested.
  3437. It avoids a possible long wait after hitting CTRL-C.
  3438. * src/SleepCommand.{h, cc}
  3439. * src/RequestGroupAware.{h, cc}
  3440. 2007-11-04 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3441. Fixed: the listen port sent to the tracker is wrong. If aria2 fails
  3442. to open listen port, then remove the port number from the tracker
  3443. request.
  3444. * src/DefaultBtAnnounce.cc
  3445. * test/DefaultBtAnnounceTest.cc
  3446. * test/MockPieceStorage.h
  3447. Inject randomizer to DefaultBtAnnounce and DefaultBtContext to make
  3448. them more testable.
  3449. * src/DefaultBtAnnounce.{h, cc}
  3450. * src/DefaultBtContext.{h, cc}
  3451. * src/Util.{h, cc}
  3452. * test/DefaultBtAnnounceTest.cc
  3453. * test/DefaultBtContextTest.cc
  3454. * test/UtilTest.cc
  3455. Added 'B' to upload bytes readout.
  3456. * src/ConsoleStatCalc.cc
  3457. Now the listen port for BitTorrent download is opened when it is
  3458. needed.
  3459. * src/DownloadEngineFactory.cc
  3460. * src/BtSetup.{h, cc}
  3461. * src/PeerListenCommand.{h, cc}
  3462. Now an exception thrown while parsing tracker response is now logged.
  3463. If DlAbortEx is catched, then btAnnounce->resetAnnounce() immediately
  3464. called, which means no retry is made in this case, assuming a tracker
  3465. has a problem.
  3466. * src/TrackerWatcherCommand.cc
  3467. Fixed: downloading a file whose length is unkown fails.
  3468. * src/DownloadCommand.cc
  3469. Simplified prepareForNextSegment()
  3470. * src/DownloadCommand.cc
  3471. Updated
  3472. * po/POTFILES.in
  3473. 2007-11-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3474. Re-implemented a file listing for Metalink, which was dropped while
  3475. http/ftp/torrent integration was being implemented.
  3476. * src/MetalinkHelper.{h, cc}: New class.
  3477. * test/MetalinkHelperTest.cc
  3478. * src/main.cc
  3479. * src/Metalink2RequestGroup.cc
  3480. 2007-11-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3481. Added the ability to display the detailed torrent file information.
  3482. Now -S option gives not only a file listing, but also total download
  3483. length, info hash, announce URI, piece length, the number of pieces,
  3484. and mode(single or multi-torrent).
  3485. * src/DefaultBtContext.{h, cc} (operator<<): New function.
  3486. * src/Util.cc (toStream): Show file length in a abbreviated form(like
  3487. KiB)
  3488. * test/UtilTest.cc
  3489. * src/main.cc
  3490. 2007-10-30 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3491. Added ftp://USER:PASSWD@Servername automatic parsing.
  3492. * src/Request.{h, cc}: Removed AuthResolvers. Added _username and
  3493. _password. Recognize username and password in URI.
  3494. * src/main.cc: Use AuthConfigFactory instead of RequestFactory.
  3495. * src/RequestGroup.cc: Use AuthConfigFactory instead of RequestFactory.
  3496. * src/RequestFactory.{h, cc}: Removed.
  3497. * src/AuthConfigFactory.{h, cc}: New class.
  3498. * src/FtpConnection.cc: Use AuthConfigFactory.
  3499. * src/HttpRequest.cc: Use AuthConfigFactory.
  3500. * test/HttpRequestTest.cc: Updated.
  3501. * test/RequestTest.cc: Updated.
  3502. * test/AuthConfigFactoryTest.cc: New class.
  3503. * test/RequestFactoryTest.cc: Removed.
  3504. 2007-10-29 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3505. Use RequestGroup::allDownloadFinished() to decide whether the control
  3506. file should be removed or saved.
  3507. * src/RequestGroup.{h, cc} (allDownloadFinished): New function.
  3508. * src/RequestGroupMan.cc (removeStoppedGroup) (save)
  3509. 2007-10-29 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3510. Use File::renameTo()
  3511. * src/DefaultBtProgressInfoFile.cc
  3512. Added --no-file-allocation-limit command-line option.
  3513. * src/version_usage.cc
  3514. * src/option_processing.cc
  3515. * src/OptionHandlerFactory.cc
  3516. * src/RequestGroup.{h, cc}
  3517. * src/BtCheckIntegrityEntry.cc
  3518. * src/StreamCheckIntegrityEntry.cc
  3519. * src/prefs.h
  3520. * doc/aria2c.1.txt
  3521. * doc/aria2c.1
  3522. Now prealloc is the default value for --file-allocation option.
  3523. * src/version_usage.cc
  3524. * src/option_processing.cc
  3525. * doc/aria2c.1.txt
  3526. * doc/aria2c.1
  3527. Don't URL-encode user-agent.
  3528. * src/HttpRequest.cc
  3529. Updated translations
  3530. * po/LINGUAS: Added nl for Dutch translation.
  3531. * po/nl.po: Added Dutch translation, thanks to A. Bram Neijt.
  3532. * po/de.po: Updated German translation, thanks to Patrick Ruckstuhl.
  3533. * po/POTFILES.in: Updated.
  3534. 2007-10-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3535. Added the ability to recognize url-list in a torrent file.
  3536. The retrieved URLs are attached to the corresponding FileEntry.
  3537. * src/DefaultBtContext.{h, cc}
  3538. * src/FileEntry.{h, cc}
  3539. * test/DefaultBtContextTest.cc
  3540. 2007-10-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3541. * src/ConsoleStatCalc.cc: Let the user know that aria2 is now seeding
  3542. after the download finishes.
  3543. 2007-10-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3544. * src/Piece.{h, cc}: Added SubPiece infrastructure to track down
  3545. the data smaller than block length.
  3546. A block length can be specified by constructor's argument.
  3547. * src/DefaultPieceStorage.{h, cc} (getMissingPiece):
  3548. Get a missing piece in the range of given FileEntry. This function is
  3549. not used in the program yet.
  3550. * src/Util.h: Added some macros.
  3551. 2007-10-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3552. Added HTTP/1.1 keep alive and pipelining support.
  3553. See --enable-http-keep-alive and --enable-http-pipelining option.
  3554. * src/AbstractCommand.{h, cc}: Now it has one-to-many relation to
  3555. Segment.
  3556. * src/HttpDownloadCommand.{h, cc}
  3557. * src/OptionHandlerFactory.cc
  3558. * src/HttpConnection.{h, cc}
  3559. * src/version_usage.cc
  3560. * src/HttpInitiateConnectionCommand.cc
  3561. * src/FtpInitiateConnectionCommand.cc
  3562. * src/Segment.h
  3563. * src/HttpRequestCommand.{h, cc}
  3564. * src/option_processing.cc
  3565. * src/prefs.h
  3566. * src/HttpResponseCommand.cc
  3567. * src/SegmentMan.{h, cc}
  3568. * src/FtpNegotiateCommand.cc
  3569. * src/HttpProxyResponseCommand.cc
  3570. * src/Request.cc
  3571. * src/HttpRequest.cc
  3572. * src/DownloadCommand.cc
  3573. * test/HttpRequestTest.cc
  3574. * test/RequestTest.cc
  3575. 2007-10-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3576. * src/ConsoleCalc.cc (calculateStat): Hide SPD after the download
  3577. finished.
  3578. 2007-10-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3579. * src/Metalink2RequestGroup.cc (generate): Throw exception instead of
  3580. catching it inside the method.
  3581. When no file entry is found in a metalink without querying user
  3582. preferences, throw the exception with the error message that suggests
  3583. metalink file is probably broken.
  3584. * src/RequestGroup.cc (postDownloadProcessing): Catch exception here.
  3585. 2007-10-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3586. Fixed the bug that prevents remote Metalink/Torrent file from begin
  3587. processed.
  3588. * src/RequestGroupMan.cc (removeStoppedGroup)
  3589. Added debug message.
  3590. * src/BtPostDownloadHandler.cc
  3591. * src/MetalinkPostDownloadHandler.cc
  3592. * src/PostDownloadHandler.{h, cc}
  3593. * src/RequestGroup.cc
  3594. 2007-10-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3595. * src/Request.cc (parseUrl): Removed unnecessary slashes around dir.
  3596. 2007-10-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3597. * src/MultiUrlRequestInfo.h: Updated the message shown when program
  3598. stops and there are any unfinished or in-progress downloads.
  3599. Added the legend of "stat".
  3600. 2007-10-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3601. Throw exception when chunck checksum verification fails.
  3602. * src/DownloadCommand.cc (validatePieceHash): New function.
  3603. * src/PiecedSegment.{h, cc} (clear): New function.
  3604. * src/GrowSegment.{h, cc} (clear): New function.
  3605. * src/Segment.h (clear): New function.
  3606. * src/SegmentMan.{h, cc} (validatePieceHash): Removed.
  3607. * test/SegmentTest.cc
  3608. * test/GrowSegmentTest.cc
  3609. 2007-10-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3610. Do not send referer when redirected.
  3611. * src/Request.cc (redirectUrl)
  3612. * test/RequestTest.cc
  3613. * test/HttpRequestTest.cc
  3614. 2007-10-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3615. Implemented BitTorrent/http/ftp integrated download.
  3616. I've rewritten lots of files and now some headers have forward
  3617. class declarations to reduce compile time.
  3618. The implementation is extremely alpha stage, I recommend to use this
  3619. for testing purpose only.
  3620. 2007-09-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3621. Fixed the compilation error on 64bit platform.
  3622. * test/HttpHeaderProcessorTest.cc
  3623. 2007-09-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3624. Merged Ross's patch that fixes compilation problem in MinGW
  3625. * test/DefaultBtProgressInfoFileTest.cc
  3626. 2007-09-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3627. Updated fr.po by sebone
  3628. * po/fr.po
  3629. Updated man page.
  3630. * doc/aria2c.1.txt
  3631. * Release 0.11.3
  3632. 2007-09-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3633. * src/MetalinkRequestInfo.cc (execute): Fixed BitTorrent download
  3634. failure in Metalink.
  3635. 2007-09-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3636. Automatically save *.aria2 control file of http/ftp download in every
  3637. 60 seconds.
  3638. * src/AutoSaveCommand.{h, cc}: New class.
  3639. * src/TimeBasedCommand.{h, cc}: New class.
  3640. * src/DownloadEngineFactory.cc (newConsoleEngine)
  3641. Disable parameterized URI support by default. Added -P option to
  3642. enable the feature.
  3643. * src/prefs.h: Added PREF_PARAMETERIZED_URI
  3644. * src/OptionHandlerFactory.cc
  3645. * src/main.cc: Also updated usages for -Z and --auto-file-renaming
  3646. Updated Japanese translation.
  3647. * po/ja.po
  3648. Updated man page.
  3649. * doc/aria2c.1.txt
  3650. * Release 0.11.3-rc
  3651. 2007-09-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3652. Now *.aria2 contorol file is first saved to *.aria2__temp and if
  3653. it is successful, then renamed to *.aria2.
  3654. This prevents *.aria2 file from being truncated or corrupted when
  3655. file system becomes out of space.
  3656. * src/DefaultBtProgressInfoFile.cc (save)
  3657. * src/SegmentMan.cc (save)
  3658. * test/DefaultBtProgressInfoFileTest.cc (testSave): Implemented.
  3659. 2007-09-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3660. Reduced the fragmentation of bitfield in http/ftp download.
  3661. * src/BitfieldMan.cc (getSparseMissingUnusedIndex)
  3662. * test/BitfieldManTest.cc
  3663. 2007-08-30 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3664. Added the ability to disable segmented download in .metalink.
  3665. aria2 can now recognize 'maxconnections' attribute in 'resources' and
  3666. 'url' tag.
  3667. * src/MetalinkEntry.{h, cc}
  3668. * src/RequestResource.{h, cc}
  3669. * src/MetalinkRequestInfo.cc
  3670. * src/Xml2MetalinkProcessor.cc
  3671. * test/Xml2MetalinkProcessorTest.cc
  3672. 2007-08-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3673. Added parameterized URI support.
  3674. * src/main.cc: -Z option added.
  3675. * src/OptionHandlerFactory.cc
  3676. * src/prefs.h: Added PREF_FORCE_SEQUENTIAL.
  3677. * src/PStringDatum.h: New class.
  3678. * src/PStringSegment.{h,cc}: New class.
  3679. * src/PStringNumLoop.h: New class.
  3680. * src/PStringSelect.h: New class.
  3681. * src/NumberDecorator.h: New class.
  3682. * src/FixedWidthNumberDecorator.h: New class.
  3683. * src/AlphaNumberDecorator.h: New class.
  3684. * src/PStringVisitor.h: New class.
  3685. * src/PStringBuildVisitor.{h,cc}: New class.
  3686. * src/ParameterizedStringParser.{h,cc}: New class.
  3687. * src/Util.{h,cc}
  3688. (isNumber): New function.
  3689. (isLowercase): New function.
  3690. (isUppercase): New function.
  3691. (alphaToNum): New function.
  3692. * test/ParameterizedStringParserTest.cc: New class.
  3693. * test/AlphaNumberDecoratorTest.cc: New class.
  3694. * test/PStringBuildVisitorTest.cc: New class.
  3695. * test/UtilTest.cc
  3696. (testIsNumber): New function.
  3697. (testIsLowercase): New function.
  3698. (testIsUppercase): New function.
  3699. (testAlphaToNum): New function.
  3700. Added '\n' after the error message
  3701. * src/RequestInfo.h (printDownloadAbortMessage)
  3702. Added auto file renaming feature in http(s)/ftp download.
  3703. * src/main.cc: Added --auto-file-renaming command-line option.
  3704. * src/OptionHandlerFactory.cc
  3705. * src/prefs.h: Added PREF_AUTO_FILE_RENAMING
  3706. * src/RequestGroup.{h, cc}
  3707. (shouldCancelDownloadForSafety): Rewritten
  3708. (tryAutoFileRenaming): New function.
  3709. * src/SegmentMan.{h, cc} (shouldCancelDownloadForSafety): Removed.
  3710. * src/HttpResponseCommand.cc
  3711. (executeInternal): Removed the call to RequestGroupMan::
  3712. isSameFileBeingDownloaded()
  3713. * src/FtpNegotiateCommand.cc
  3714. (recvSize): Removed the call to RequestGroupMan::
  3715. isSameFileBeingDownloaded()
  3716. * test/RequestGroupTest.cc: New class.
  3717. 2007-08-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3718. Merged Ross's patch: Removed setmode(). Use _CRT_fmode to enable binary
  3719. IO.
  3720. * src/DefaultBtProgressInfoFile.cc
  3721. * src/MetaFileUtil.cc
  3722. * src/SimpleLogger.cc
  3723. * src/SegmentMan.cc
  3724. * src/Util.cc
  3725. * src/Platform.cc
  3726. 2007-08-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3727. * src/Xml2MetalinkProcessor.cc (getPieceHash): Added missing .c_str().
  3728. 2007-08-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3729. Avoid sparse files if possible, because VFAT32 doesn't support it.
  3730. * src/DefaultDiskWriter.cc (initAndOpenFile)
  3731. Fixed the bug that prevents file allocation is not done when
  3732. dowloading multi-torrent file.
  3733. * src/AbstractDiskWriter.cc (openFile)
  3734. Increase the maximum number of -j option from 15 to 45.
  3735. * src/OptionHandlerFactory.cc (createOptionHandlers)
  3736. Added fr.po, thanks to Charles Landemaine.
  3737. * po/fr.po
  3738. * po/LINGUAS
  3739. 2007-08-10 Ross Smith II <aria2spam at smithii dot com>
  3740. gcc 3.4.4 support:
  3741. * src/DefaultBtContext.cc: int32_t -> int
  3742. * src/main.cc: int -> int32_t, int32_t -> int
  3743. * src/messageDigest.h: uint32_t -> unsigned int
  3744. * src/NameResolver.h: int32_t -> int
  3745. * src/PeerConnection.cc: int -> int32_t
  3746. * src/SpeedCalc.cc: int32_t -> int
  3747. * src/TrackerUpdateCommand.h: int -> int32_t
  3748. * src/Util.cc: int32_t -> int
  3749. * src/Util.h: int32_t -> int
  3750. * src/Xml2MetalinkProcessor.cc: int -> uint32_t, int64_t -> uint64_t
  3751. * test/AnnounceListTest.cc: int -> int32_t
  3752. * test/ChunkedEncodingTest.cc: int -> int32_t
  3753. * test/DataTest.cc: int -> int32_t
  3754. * test/DefaultBtRequestFactoryTest.cc: int -> int32_t
  3755. * test/DefaultPeerListProcessorTest.cc: int -> int32_t
  3756. * test/DefaultPieceStorageTest.cc: int -> int32_t
  3757. * test/FeatureConfigTest.cc: int -> int32_t
  3758. * test/MetalinkEntryTest.cc: int -> int32_t
  3759. * test/MockBtRequestFactory.h: int -> int32_t
  3760. * test/MockPieceStorage.h: int -> int32_t
  3761. * test/OptionTest.cc: int -> int32_t
  3762. * test/RequestTest.cc: int -> int32_t
  3763. * test/SegmentManTest.cc: int -> int32_t
  3764. * test/Xml2MetalinkProcessorTest.cc: int -> int32_t
  3765. 2007-08-10 Ross Smith II <aria2spam at smithii dot com>
  3766. Move sleep functions to Util class:
  3767. * src/Util.cc
  3768. (sleep): New function.
  3769. (usleep): New function.
  3770. * src/DownloadCommand.cc: sleep -> Util::sleep
  3771. * test/TimeSeedCriteriaTest.cc: sleep -> Util::sleep
  3772. MinGW build enhancements. The following files are added:
  3773. * src/timegm.{c,h}
  3774. Changes to support the above new files:
  3775. * configure.ac
  3776. * src/Makefile.am
  3777. * src/a2time.h
  3778. * src/Util.cc:
  3779. * src/strptime.c: Added support for %Z option.
  3780. Fixed MinGW non-blocking bug.
  3781. * src/SocketCore.cc
  3782. * src/HttpRequestCommand.cc
  3783. Miscellenous build fixes/enhancements.
  3784. * configure.ac: Added summary report.
  3785. * src/Platform.h: Tweaked #include's.
  3786. * src/a2netcompat.h: Tweaked #include's.
  3787. * src/strptime.h: Tweaked #include's.
  3788. * src/gai_strerror.c: Tweaked #include's.
  3789. * src/gai_strerror.h: _D_GETADDRINFO_H -> _D_GAI_STRERROR_H
  3790. * src/getaddrinfo.h: Moved #ifndef __MINGW32__
  3791. * src/gettimeofday.h: Added HAVE_CONFIG_H
  3792. 2007-08-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3793. Increased the initial connection size in BitTorrent download to 40.
  3794. * src/BtRuntime.h
  3795. Added the usage message of --peer-id-prefix option.
  3796. * src/main.cc
  3797. * Release 0.11.2
  3798. 2007-08-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3799. MessageDigestHelper is introduced in order to simplify the use
  3800. of message digest. Removed repeated code.
  3801. The message digest algorithm is now specified by string, like "sha1",
  3802. "md5".
  3803. * src/messageDigest.{h, cc}
  3804. * src/MessageDigestHelper.{h, cc}: New class.
  3805. * src/DefaultPieceStorage.cc
  3806. * src/DefaultBtContext.{h, cc}
  3807. (computeFastSet): New function.
  3808. (setInfoHash): Added for unit testing.
  3809. (setNumPieces): Added for unit testing.
  3810. * src/DefaultBtInteractive.cc
  3811. * src/BtPieceMessage.cc
  3812. * src/Peer.cc
  3813. * src/Checksum.h
  3814. * src/message.h
  3815. * src/IteratableChecksumValidator.h
  3816. * src/ChunkChecksumValidator.{h, cc}: Use IteratableChecksumValidator
  3817. inside it.
  3818. * src/SegmentMan.{h, cc}
  3819. (checkIntegrity): Removed.
  3820. * src/IteratableChunkChecksumValidator.{h, cc}
  3821. * src/Util.h
  3822. (sha1Sum): Removed.
  3823. (simpleMessageDigest): Removed.
  3824. (fileChecksum): Removed.
  3825. (computeFastSet): Removed.
  3826. * src/ShaVisitor.cc
  3827. * src/ChunkChecksum.h
  3828. * src/DownloadCommand.cc
  3829. Removed messageDigest virtual functions.
  3830. * src/MultiDiskAdaptor.{h, cc}
  3831. * src/DiskAdaptor.h
  3832. * src/ByteArrayDiskWriter.h
  3833. * src/DiskWriter.h
  3834. * src/DiskAdaptorWriter.h
  3835. * src/AbstractSingleDiskAdaptor.{h, cc}
  3836. * src/AbstractDiskWriter.{h, cc}
  3837. Fixed comilation error when message digest is disabled.
  3838. * src/MetalinkEntry.{h, cc}
  3839. * src/MetalinkRequestInfo.cc
  3840. Removed srandom and random.
  3841. * src/SimpleRandomizer.h
  3842. Added size() virtual function to DiskAdaptor
  3843. * src/MultiDiskAdaptor.h
  3844. Fixed the bug that causes that files are not opened correctly in
  3845. multi-file torrent.
  3846. * src/TorrentRequestInfo.cc
  3847. * src/MultiDiskAdaptor.cc
  3848. Added SHA256 support
  3849. * src/messageDigest.cc
  3850. * src/Xml2MetalinkProcessor.cc
  3851. Show supported message digest algorithms
  3852. * src/main.cc
  3853. Updated contact info.
  3854. * src/main.cc
  3855. Applied Ross's patch
  3856. * src/a2netcompat.h
  3857. * src/main.cc
  3858. Fixed the bug that prevents a remote metalink from not being processed
  3859. even if '-o foo.metalink' is specified.
  3860. * src/MetalinkRequestInfo.cc
  3861. 2007-08-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3862. Merged Dan's patch:
  3863. * src/ByteArrayDiskWriter.cc: ios_base -> ios
  3864. Use va_copy to avoid core dump on amd64:
  3865. * src/SimpleLogger.cc
  3866. Updated contact info.
  3867. * src/main.cc
  3868. Added #ifdef ENABLE_MESSAGE_DIGEST to fix test errors when message
  3869. digest is not available.
  3870. * src/MetalinkEntry.h
  3871. 2007-08-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3872. Make a2netcompat.h include a2io.h to fix compilation error:
  3873. * src/a2netcompat.h
  3874. * src/SocketCore.cc: Removed include of a2io.h
  3875. * src/Util.cc: Removed include of a2io.h
  3876. Gather time related functions to a2time.h:
  3877. * src/a2time.h: New file.
  3878. * src/DefaultPeerStorage.cc
  3879. * src/SimpleLogger.cc
  3880. * src/Util.{h, cc}
  3881. * src/SimpleRandomizer.h
  3882. * src/TimeA2.{h,cc}
  3883. * src/DownloadCommand.cc
  3884. * src/main.cc
  3885. Removed #ifdef __MINGW32__ since gai_strerror is included in
  3886. a2netcompat.h:
  3887. * src/NameResolver.cc
  3888. Fixed compilation error without openssl:
  3889. * src/SocketCore.{h,cc}: Moved include of openssl/err.h to SocketCore.h
  3890. Added default block to suppress compiler warnings:
  3891. * src/MetalinkRequestInfo.cc (AccumulateNonP2PUrl::operator())
  3892. 2007-07-26 Ross Smith II <aria2spam at smithii dot com>
  3893. MinGW build enhancements. The following files are added:
  3894. * src/gai_strerror.{c,h}
  3895. * src/gettimeofday.{c,h}
  3896. Changes to support the above new files:
  3897. * configure.ac
  3898. * src/Makefile.am
  3899. * src/a2netcompat.h
  3900. * src/TimeA2.cc
  3901. * src/DefaultPeerStorage.cc
  3902. * src/NameResolver.cc: removed mingw_strerror() function.
  3903. * src/SocketCore.cc: removed mingw_strerror() function.
  3904. Miscellaneous MinGW build fixes.
  3905. * src/a2io.h: Use _lseeki64() instead of lseek()
  3906. * src/common.h
  3907. * src/DefaultFileAllocator.cc
  3908. * src/GlowFileAllocator.cc
  3909. * src/main.cc: Moved #include "prefs.h" to quiet compile error.
  3910. * src/NameResolver.cc
  3911. (callback): Changed int32_t to int.
  3912. (resolve): Changed int32_t to int.
  3913. * src/Platform.cc
  3914. * src/Platform.h
  3915. * test/MultiDiskWriterTest.cc
  3916. * test/PeerMessageUtilTest.cc
  3917. * src/localtime_r.c: Add DeleteCriticalSection() and at exit().
  3918. Other enhancements and fixes.
  3919. * src/HttpRequestCommand.cc
  3920. (executeInternal) Use non-blocking socket for HTTPS (MinGW only).
  3921. * src/SocketCore.cc:
  3922. (error): New function to abstract errno/WSAGetLastError().
  3923. (errorMsg): New function to abstract errno/WSAGetLastError().
  3924. (initiateSecureConnection): Added more detailed error reporting.
  3925. * src/SocketCore.h: Added private variable blocking, to allow
  3926. proper handling of OpenSSL psuedo-errors.
  3927. * src/message.h
  3928. (EX_SSL_INIT_FAILURE)
  3929. (EX_SSL_IO_ERROR)
  3930. (EX_SSL_PROTOCOL_ERROR)
  3931. (EX_SSL_UNKNOWN_ERROR)
  3932. (EX_SSL_CONNECT_ERROR)
  3933. (EX_SOCKET_BLOCKING)
  3934. (EX_SOCKET_NONBLOCKING)
  3935. (EX_SOCKET_UNKNOWN_ERROR)
  3936. * src/Util.cc
  3937. (setGlobalSignalHandler): Renamed signal to sig as signal is a
  3938. reserved name.
  3939. (httpGMT): Fixed typo.
  3940. 2007-07-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3941. Merged Ross's win32 patch(manually)
  3942. In the course of merging, following files are added.
  3943. * src/strptime.{h,c}
  3944. * src/libgen.{h,c}
  3945. * src/inet_aton.{h,c}
  3946. * src/Platform.{h,cc}
  3947. * src/localtime_r.{h,c}
  3948. * src/getaddrinfo.{h,c}
  3949. I've gethered network related things, and put them to following file:
  3950. * src/a2netcompat.h
  3951. Also io related things are put to following file:
  3952. * src/a2io.h
  3953. Changed %lld to %s because mingw32 doesn't recognize %lld.
  3954. * src/message.h
  3955. (MSG_ALLOCATION_COMPLETED)
  3956. (EX_TOO_LARGE_FILE)
  3957. (EX_SIZE_MISMATCH)
  3958. (EX_FILE_OFFSET_OUT_OF_RANGE)
  3959. (EX_INVALID_CHUNK_CHECKSUM)
  3960. (EX_INVALID_RANGE_HEADER)
  3961. * src/FileAllocationCommand.cc
  3962. * src/HttpResponse.cc
  3963. * src/RequestGroup.cc
  3964. * src/MultiDiskAdaptor.cc
  3965. * src/OptionHandlerImpl.h
  3966. * src/HttpResponseCommand.cc
  3967. * src/FtpNegotiateCommand.cc
  3968. * src/IteratableChecksumValidator.cc
  3969. * src/SegmentMan.cc
  3970. * src/ChunkChecksumValidator.cc
  3971. Added Randomizer::getRandomNumber(long int)
  3972. * src/Randomizer.h (getRandomNumber)
  3973. * src/SimpleRandomizer.h (getRandomNumber)
  3974. * src/BitfieldMan.cc (getMissingIndexRandomly): Use this new function.
  3975. * src/Util.cc (randomAlpha): Use this new function.
  3976. 2007-07-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3977. Converted int's to in32_t. long long int's are also converted to
  3978. int64_t
  3979. 2007-07-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3980. Fixed the bug that prevents cookies from being sent to the server
  3981. if the domain of cookie is FQDN and starts with ".".
  3982. * src/Cookie.cc (match)
  3983. To add the ability to change peer id.
  3984. * src/DefaultBtContext.h
  3985. (_peerIdPrefix): New variable
  3986. (setPeerIdPrefix): New function.
  3987. * src/torrentRequestInfo.cc
  3988. (execute): Set the option value of PREF_PEER_ID_PREFIX to
  3989. DefaultBtContext.
  3990. * src/main.cc (main): Added peer-id-prefix command-line option.
  3991. The usage message is not added yet.
  3992. * src/DefaultBtContext.cc
  3993. (generatePeerId): Use _peerIdPrefix.
  3994. * src/prefs.h (PREF_PEER_ID_PREFIX): New definition.
  3995. 2007-07-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  3996. Fixed the bug that prevents filename in content-disposition from
  3997. being retrieved when filename is not quoted.
  3998. * src/Util.cc (getContentDispositionFilename)
  3999. Fixed the bug that causes infinate loop and memory leak when file open
  4000. operation failed.
  4001. * src/HttpResponseCommand.cc (handleDefaultEncoding)
  4002. 2007-07-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4003. Fixed the bug that causes segfault when all URIs specified are
  4004. unsupported.
  4005. * src/RequestGroupMan.cc (getInitialCommands)
  4006. Check if RequestGroup::createNextCommand() returns empty list of
  4007. commands.
  4008. * src/RequestGroup.cc (createNextCommand)
  4009. Change log level from info to error so that users can notice that
  4010. an error occurred.
  4011. Fixed the bug that causes segfault when a zero-sized file is
  4012. downloaded.
  4013. * src/BitfieldMan.cc (isAllBitSet)
  4014. Return true if bitfieldLength is 0.
  4015. 2007-07-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4016. * src/main.cc
  4017. (showUsage): Added 3 usage examples for metalink download.
  4018. Replace MetalinkChunkChecksum with ChunkChecksum.
  4019. * src/MetalinkChunkChecksum.h: Removed.
  4020. * src/MetalinkEntry.h: MetalinkChunkChecksum -> ChunkChecksum.
  4021. * src/Xml2MetalinkProcessor.h: MetalinkChunkChecksum -> ChunkChecksum.
  4022. * src/Xml2MetalinkProcessor.cc
  4023. (getPieceHash): Use ChunkChecksum instead of MetalinkChunkChecksum.
  4024. * src/MetalinkRequestInfo.cc (execute)
  4025. * Release 0.11.1
  4026. 2007-07-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4027. Reads URIs from stdin when "-i -" is specified.
  4028. * src/UriFileListParser.h, src/UriFileListParser.cc: Removed.
  4029. * src/UriListParser.h, src/UriListParser.cc: New class.
  4030. * src/StreamUriListParser.h: New class.
  4031. * src/FileUriListParser.h: New class.
  4032. * src/main.cc (main): Use StreamUriListParser and FileUriListParser
  4033. instead of UriFileListParser.
  4034. 2007-07-04 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4035. Made console readout more readable.
  4036. * src/ConsoleDownloadEngine.cc (sendStatistics)
  4037. 2007-07-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4038. Fix the bug that causes -s option not to work.
  4039. * src/main.cc (main)
  4040. * src/a2algo.h: New file.
  4041. 2007-07-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4042. Create directory structure specified in metalink file.
  4043. * src/RequestGroup.h, src/RequestGroup.cc
  4044. (initAndOpenFile): Create a directory to store files if it does not
  4045. exist.
  4046. (getDir): New function.
  4047. Added ETA and download speed for an individual file to readout.
  4048. * src/ConsoleDownloadEngine.cc (sendStatistics)
  4049. * src/RequestGroup.h
  4050. (calculateDownloadSpeed): New function.
  4051. 2007-06-30 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4052. Made -S option work with metalink file and provided selective download
  4053. to metalink.
  4054. * src/MetalinkEntry.h, src/MetalinkEntry.cc
  4055. (filename): Removed.
  4056. (file): New variable.
  4057. (size): Removed.
  4058. (operator=): Updated.
  4059. (getPath): New function.
  4060. (getLength): New function.
  4061. (toFileEntry): New function.
  4062. * src/TorrentRequestInfo.h, src/TorrentRequestInfo.cc
  4063. (execute): Use toStream.
  4064. (showFileEntry): Removed.
  4065. * src/MetalinkRequestInfo.h
  4066. (targetFiles): New variable.
  4067. (setTargetFiles): New variable.
  4068. * src/MetalinkRequestInfo.cc
  4069. (execute): Added the ability to print file information included in
  4070. a metalink file.
  4071. Added selective download mode to metalink.
  4072. * src/main.cc
  4073. (showUsage): Updated to denote that -S and --select-file options are
  4074. applicable to metalink.
  4075. * src/FileEntry.h
  4076. (operator=): New function.
  4077. (getBasename): New function.
  4078. (getDirname): New function.
  4079. * src/Util.h, src/Util.cc
  4080. (toStream): New function.
  4081. * src/Xml2MetalinkProcessor.cc: Updated.
  4082. Made aria2 work with metalink with directory structure.
  4083. * src/File.h, src/File.cc
  4084. (getBasename): New function.
  4085. (getDirname): New function.
  4086. * src/RequestGroup.h, src/RequestGroup.cc
  4087. (_topDir): New variable.
  4088. (setTopDir): New function.
  4089. (initSegmentMan): A directory structure is added to _segmentMan->dir.
  4090. Rewrote HTTP header parsing with stringstream.
  4091. * src/HttpConnection.h, src/HttpConnection.cc
  4092. (HttpRequestEntry): New class.
  4093. (headerBuf): Removed.
  4094. (headerBufLength): Removed.
  4095. (outstandingHttpRequests): Now its element type is
  4096. HttpRequestEntryHandle.
  4097. (findEndOfHeader): Removed.
  4098. (receiveResponse): Rewritten.
  4099. * src/HttpHeaderProcessor.h, src/HttpHeaderProcessor.cc: New class.
  4100. Updated doc for -j option to notice that it should be used with -i
  4101. option.
  4102. * src/main.cc (showUsage)
  4103. Removed unused classes.
  4104. * src/RequestInfo.h
  4105. (FileInfo): Removed.
  4106. (checksum): Removed.
  4107. (fileInfo): Removed.
  4108. (setChecksum): Removed.
  4109. (getChecksum): Removed.
  4110. (getFileInfo): Removed.
  4111. Use ISO units.
  4112. * src/ConsoleDownloadEngine.cc
  4113. * src/TorrentConsoleDownloadEngine.cc
  4114. * src/Util.cc (abbrevSize)
  4115. 2007-06-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4116. Added the default listening ports to the help message.
  4117. * src/main.cc (showUsage)
  4118. 2007-06-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4119. Reduce the number of calls to gettimeofday to lower CPU load.
  4120. * src/TimeA2.h, src/TimeA2.cc (differenceInMillis): New function.
  4121. * src/SpeedCalc.h, src/SpeedCalc.cc (calculateSpeed): New function.
  4122. * src/Peer.h (calculateUploadSpeed): New function.
  4123. (calculateDownloadSpeed): New function.
  4124. * src/DefaultPeerStorage.cc
  4125. (CalculateStat): Added _now variable.
  4126. In operator(), call Peer::calculateDownloadSpeed(const struct timeval&)
  4127. and Peer::calculateUploadSpeed(const struct timeval&)
  4128. Drop connection if no request or piece message is exchanged in
  4129. a certain interval.
  4130. * src/DefaultBtInteractive.h
  4131. (btRuntime): New variable.
  4132. (inactiveCheckPoint): New variable.
  4133. (checkActiveInteraction): New function.
  4134. * src/DefaultBtInteractive.cc (receiveMessages): Reset timer when
  4135. request or piece message is received.
  4136. (checkActiveInteraction): New function.
  4137. (doInteractionProcessing): Call checkActiveInteraction.
  4138. Fixed the bug that causes remote Metalink and Torrent files are not
  4139. processed.
  4140. * src/MultiUrlRequestInfo.cc (createNextRequestInfo): Fixed the bug.
  4141. 2007-06-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4142. Changed format of log file.
  4143. * src/SimpleLogger.cc
  4144. * Release 0.11.0
  4145. 2007-06-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4146. * src/AbstractCommand.cc
  4147. (execute): Changed log level of MSG_RESTARTING_DOWNLOAD and
  4148. MSG_MAX_TRY from error to info.
  4149. Added MSG_DOWNLOAD_ABORTED after MSG_MAX_TRY.
  4150. * src/message.h
  4151. (MSG_TORRENT_DOWNLOAD_ABORTED): New definition.
  4152. (MSG_DOWNLOAD_ABORTED): Added %s.
  4153. (MSG_RESTARTING_DOWNLOAD): Added %s.
  4154. (MSG_DOWNLOAD_ALREADY_COMPLETED): Updated.
  4155. * src/PeerAbstractCommand.cc
  4156. (execute): MSG_DOWNLOAD_ABORTED -> MSG_TORRENT_DOWNLOAD_ABORTED
  4157. * src/Request.h
  4158. (cookieBox): Made ShardHandle.
  4159. * src/RequestGroup.h, src/RequestGroup.cc
  4160. (createNextCommandWithAdj): New function.
  4161. * src/FileAllocationCommand.cc
  4162. (executeInternal): Use createNextCommandWithAdj().
  4163. * src/CheckIntegrityCommand.cc
  4164. (executeInternal): Use createNextCommandWithAdj().
  4165. Added --load-cookies command-option.
  4166. * src/OptionHandlerFactory.cc
  4167. (createOptionHandlers): Added PREF_LOAD_COOKIES.
  4168. * src/CookieBox.h, src/CookieBox.cc: Rwritten using CookieParser.
  4169. Now aria2 can handle cookie's expiration date.
  4170. * src/Cookie.h (expires): Changed its type to time_t.
  4171. * src/main.cc: Added --load-cookies command-line option.
  4172. * src/prefs.h (PREF_LOAD_COOKIES): New definition.
  4173. * src/Util.h, src/Util.cc (httpGMT): New function.
  4174. * src/Request.cc (Request): Initialize cookieBox using
  4175. CookieBoxFactory.
  4176. * src/CookieBoxFactory.h, src/CookieBoxFactory.cc: New class.
  4177. * src/CookieParser.h, src/CookieParser.cc: New class.
  4178. * src/main.cc: Chagned the default value of --metalink-servers to 5.
  4179. * src/HttpResponseCommand.cc
  4180. (handleOtherEncoding): Call RequestGroup::shouldCancelDownloadForSafety
  4181. * src/MetalinkRequestInfo.cc: Now -s option is ignored in Metalink
  4182. download.
  4183. 2007-06-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4184. Added -j command-line option.
  4185. * src/OptionHandlerFactory.cc (createOptionHandlers)
  4186. * src/main.cc
  4187. * src/ByteArrayDiskWriter.h, src/ByteArrayDiskWriter.cc
  4188. Rewritten using stringstream.
  4189. * src/TrackerUpdateCommand.h, src/TrackerUpdateCommand.cc
  4190. Rewritten using stringstream.
  4191. 2007-06-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4192. Make download size shown in MB, KB.
  4193. * src/ConsoleDownloadEngine.h (sendStatistics)
  4194. * src/Util.h, srcUtil.cc (abbrevSize): New function.
  4195. 2007-06-04 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4196. Accept incoming connections if download rate is low.
  4197. * src/PeerListenCommand.h, src/PeerListenCommand.cc:
  4198. (_lowestSpeedLimit): New variable.
  4199. (setLowestSpeedLimit): New function.
  4200. (execute): Accept incoming connections if download rate is low.
  4201. MAX_PEERS is ignored in this case.
  4202. Disable PREF_OUT in multiple concurrent download:
  4203. * src/RequestGroup.h, src/RequestGroup.cc
  4204. (setUserDefinedFilename): New function.
  4205. * src/DownloadEngineFactory.cc
  4206. (newConsoleEngine): Do not set PREF_OUT to requestGroup in multiple
  4207. concurrent download.
  4208. * src/DefaultSegmentManFactory.cc
  4209. (createNewInstance): Comment out the line: segmentMan->ufilename = ...
  4210. 2007-06-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4211. RequestGroup::getNextCommand() was renamed to createNextCommand().
  4212. Added its overloaded method.
  4213. * src/RequestGroup.h
  4214. (_numConcurrentCommand): New variable.
  4215. (setNumConcurrentCommand): New function.
  4216. * src/RequestGroup.cc
  4217. Abort download if same file is being downloaded concurrently.
  4218. * src/RequestGroup.h, src/RequestGroupMan.cc
  4219. (isSameFileBeingDownloaded): New function.
  4220. * src/HttpResponseCommand.cc (executeInternal)
  4221. * src/FtpNegotiateCommand.cc (recvSize)
  4222. * src/message.h (EX_DUPLICATE_FILE_DOWNLOAD): New definition.
  4223. * main.cc: Added help message for -i option.
  4224. 2007-06-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4225. * src/FileAllocationCommand.cc: Derived from RealtimeCommand.
  4226. * src/CheckIntegrityCommand.cc: Derived from RealtimeCommand.
  4227. * src/MetalinkEntry.h
  4228. (checksum): Changed to ChecksumHandle
  4229. * src/MetalinkRequestInfo.cc
  4230. (checksum): Changed to ChecksumHandle
  4231. * src/File.cc
  4232. (mkdirs): OPEN_MODE -> DIR_OPEN_MODE
  4233. * src/common.h
  4234. (DIR_OPEN_MODE): New definition
  4235. * src/RequestGroup.cc
  4236. (prepareForNextAction): Added an argument.
  4237. * src/message.h
  4238. (MSG_GOOD_CHECKSUM): New definition
  4239. (MSG_BAD_CHECKSUM): New definition
  4240. * src/HttpResponseCommand.cc
  4241. (handleDefaultEncoding): Continue download sequence in new
  4242. non-segmented download.
  4243. * src/FileAllocationEntry.h
  4244. (_nextDownloadCommand): New variable.
  4245. * src/DownloadCommand.cc
  4246. (prepareForNextSegment): Create ChecksumCommand if checksum is
  4247. available.
  4248. * src/RealtimeCommand.h, src/RealtimeCommand.cc: New class.
  4249. * src/IteratableChecksumValidator.h,
  4250. src/IteratableChecksumValidator.cc: New class.
  4251. * src/ChecksumCommand.h, src/ChecksumCommand.cc: New class.
  4252. 2007-05-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4253. Change file mode to 666:
  4254. * src/common.h (OPEN_MODE): New definition.
  4255. * src/File.cc
  4256. * src/Util.cc
  4257. * src/Directry.cc
  4258. * src/AbstractDiskWriter.cc
  4259. Change the level of log message "download aborted" to debug:
  4260. * src/PeerAbstractCommand.cc (execute)
  4261. * src/RequestGroup.h (RequestGroup): Initialized _hintTotalLength to 0.
  4262. * src/TrackerWatcherCommand.cc
  4263. (createCommand): Sleep some seconds after request failed.
  4264. If tracker request fails more than value of PREF_TRACKER_MAX_TRIES,
  4265. then abort tracker request.
  4266. 2007-05-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4267. * Added the simultaneous download feature.
  4268. * src/main.cc: Print "Exception caught: " when exception is caught.
  4269. Use CUIDCounter instead of BtRuntime::getNewCuid():
  4270. * src/ActivePeerConnectionCommand.cc
  4271. * src/PeerInteractionCommand.cc
  4272. * src/BtRuntime.h
  4273. (cuidCounter): Removed.
  4274. (getNewCuid): Removed.
  4275. * src/DownloadEngineFactory.cc
  4276. * src/PeerListenCommand.cc
  4277. * src/TrackerUpdateCommand.cc
  4278. * src/PeerInitiateConnectionCommand.cc
  4279. 2007-04-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4280. * src/PeerAbstractCommand.cc
  4281. (onAbort): Call PeerStorage::returnPeer()
  4282. * src/DefaultPeerStorage.h, src/DefaultPeerStorage.cc
  4283. (incomingPeers): New variable.
  4284. (addIncomingPeer): New function.
  4285. (returnPeer): New function.
  4286. (onErasingPeer): New function.
  4287. (addPeer): push_back -> push_front
  4288. (getActivePeers): Rewritten.
  4289. (calculateStat): Rewritten.
  4290. * src/PeerStorage.h
  4291. (TransferStat::copy): New function.
  4292. (TransferStat::TransferStat): New function.
  4293. (TransferStat::operator=): New function.
  4294. (addIncomingPeer): New function.
  4295. (returnPeer): New function.
  4296. * src/PeerListenCommand.cc
  4297. (execute): Use PeerStorage::addIncomingPeer() instead of
  4298. Peer::addPeer().
  4299. 2007-04-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4300. Connect to a peer actively when download speed is lower than specified
  4301. speed in torrent download:
  4302. * src/ActivePeerConnectionCommand.h: New class.
  4303. 2007-03-29 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4304. * src/HttpRequest.cc (createRequest): url-encode user-agent
  4305. * src/main.cc: Fixed the bug that prevents download if .netrc
  4306. doesn't exist.
  4307. 2007-03-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4308. To cache resolved hostname:
  4309. * src/AbstractCommand.h, src/AbstractCommand.cc
  4310. (resolveHostname): Put outside #ifdef ENABLE_ASYNC_DNS clause.
  4311. Added dns cache.
  4312. * src/FtpInitiateConnectionCommand.cc
  4313. (executeInternal): Removed #ifdef ENABLE_ASYNC_DNS.
  4314. * src/NameResolver.h, src/NameResolver.cc: Added synchronized
  4315. NameResolver working without ares.
  4316. * src/TorrentRequestInfo.cc
  4317. (execute): Don't cache dns in torrent download.
  4318. * src/HttpInitiateConnectionCommand.cc
  4319. (executeInternal): Removed #ifdef ENABLE_ASYNC_DNS
  4320. * src/DNSCache.h: New class.
  4321. * src/UrlRequestInfo.cc
  4322. (execute): Use dns cache.
  4323. In http request, suppress port number in http request header if port
  4324. is 80 or 443:
  4325. * src/HttpRequest.cc (getHostText): Suppress port number in http
  4326. request header if port is 80 or 443.
  4327. (createProxyRequest): Allways send port number.
  4328. 2007-03-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4329. To add the command-line option which disables netrc support:
  4330. * src/OptionHandlerFactory.cc
  4331. (createOptionHandlers): Added PREF_NO_NETRC.
  4332. * src/main.cc: Added -n option.
  4333. * src/prefs.h (PREF_NO_NETRC): New definition.
  4334. * src/RequestFactory.cc: Do not use netrc in ftp if PREF_NO_NETRC is
  4335. V_TRUE.
  4336. Note that netrc is not used in http, http proxy even if PREF_NO_NETRC
  4337. is V_FALSE. This may get configurable in the future release.
  4338. To clear peer's error status by time basis:
  4339. * src/PeerAbstractCommand.cc
  4340. (onAbort): Call Peer::startBadCondition().
  4341. * src/Peer.h, src/Peer.cc
  4342. (error): Removed.
  4343. (_badConditionStartTime): New variable.
  4344. (_badConditionInterval): New variable. Initialized to 10 seconds.
  4345. (startBadCondition): New function.
  4346. (isGood): New function.
  4347. * src/DefaultPeerStorage.cc
  4348. (addPeer): Use Peer::isGood().
  4349. (FindFinePeer): Use Peer::isGood().
  4350. Always include port number in http request header:
  4351. * src/HttpRequest.cc (getHostText): Always include port number in
  4352. http request header.
  4353. 2007-03-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4354. To the ability to read options from a config file:
  4355. * src/main.cc: Command-line parameter validation is delegated to
  4356. OptionHandler class.
  4357. * src/OptionHandlerFactory.h, src/OptionHandlerFactory.cc: New class.
  4358. * src/Option.h, src/Option.cc (clear): New function.
  4359. * src/OptionParser.h, src/OptionParser.cc: New class.
  4360. * src/OptionHandler.h: New class.
  4361. * src/NameMatchOptionHandler.h: New class.
  4362. * src/OptionHandlerImpl.h: New classes.
  4363. * src/prefs.h: '_' -> '-'
  4364. (FTP_PASV_ENABLED): Renamed to FTP_PASV.
  4365. (FTP_PASV): New definition.
  4366. * src/Util.h, src/Util.cc (getRealSize): New function.
  4367. To disable netrc support if .netrc file does not have correct
  4368. permissions:
  4369. * src/File.h, src/File.cc (mode): New function.
  4370. To prevent confidential information to be logged:
  4371. * src/HttpConnection.h, src/HttpConnection.cc
  4372. (eraseConfidentialInfo): New function.
  4373. (sendRequest): Call eraseConfidentialInfo().
  4374. (sendProxyRequest): Call eraseConfidentialInfo().
  4375. * src/main.cc: Validate permissions of .netrc file.
  4376. To add --user-agent command-line option:
  4377. * src/main.cc: Added new command line option: --user-agent
  4378. * src/prefs.h (PREF_USER_AGENT): New definition.
  4379. * src/HttpRequestCommand.cc (executeInternal): Set user-agent option
  4380. parameter to HttpRequest object.
  4381. * src/AbstractProxyRequestCommand.cc
  4382. (executeInternal): Set user-agent option parameter to HttpRequest
  4383. object.
  4384. Marged the patches from Dan Fandrich.
  4385. 2007-03-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4386. Use filename and size from Metalink file instead of sending HEAD
  4387. request:
  4388. * src/UrlRequestInfo.h
  4389. (_filename): New variable.
  4390. (_totalLength): New variable.
  4391. (setTotalLength): New variable.
  4392. (setFilename): New variable.
  4393. * src/MetalinkRequestInfo.cc
  4394. (execute): Set filename and size to UrlRequestInfo
  4395. * src/UrlRequestInfo.cc
  4396. (execute): Use filename and size from Metalink instead of seding
  4397. HEAD request to servers.
  4398. 2007-03-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4399. To add the ability to resume downloading a partially downloaded file
  4400. which is downloaded from the beginning:
  4401. * src/FileAllocator.h: Made abstract class. New DefaultFileAllocator
  4402. takes this role.
  4403. * src/main.cc: Added -c option.
  4404. * src/BitfieldMan.h, src/BitfieldMan.cc (setBitRange): New function.
  4405. * src/DiskWriter.h (openExistingFile): Added totalLength argument.
  4406. * src/prefs.h (PREF_CONTINUE): New definition.
  4407. * src/SegmentMan.h, src/SegmentMan.cc (markPieceDone): New function.
  4408. * src/DefaultDiskWriter.cc
  4409. (createNewDiskWriter): Add GlowFileAllocator to the new object.
  4410. * src/AbstractDiskWriter.h
  4411. (glowFileAllocator): New variable.
  4412. * src/AbstractDiskWriter.cc
  4413. (openExistingFile): Now preallocate file space from the end of the
  4414. existing file if totalLength argument is specified and grater than 0.
  4415. * src/UrlRequestInfo.cc: If -c option is specified and the file
  4416. to download exists in local, continue the download of the file.
  4417. --allow-overwrite=true is assumed in this context.
  4418. * src/DefaultFileAllocator.h, src/DefaultFileAllocator.cc: New class.
  4419. * src/GlowFileAllocator.h, src/GlowFileAllocator.cc: New class.
  4420. Throw exception if --check-integrity=true is specified but chunk
  4421. checksums are not provided:
  4422. * src/UrlRequestInfo.cc
  4423. Do not print URLs to stdout:
  4424. * src/UrlRequestInfo.cc
  4425. 2007-03-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4426. * src/Request.h: Use AuthResolver to get authentication information.
  4427. * src/main.cc: Made RequestFactory a singleton object. Netrc is now
  4428. set to RequestFactory object.
  4429. * src/AuthConfigItem.h, src/AuthConfigItem.cc: Removed.
  4430. * src/AuthConfig.h, src/AuthConfig.cc: Rewritten.
  4431. * src/TrackerWatcherComand.cc: Use RequestFactorySingletonHolder to
  4432. create Request object.
  4433. 2007-03-19 Tatsuhiro Tsujikawa <tujikawa at valkyrie dot rednoah com>
  4434. To integrate Netrc into exsiting classes:
  4435. * src/Request.h
  4436. (_userDefinedAuthConfig): New variable.
  4437. (findNetrcAuthenticator): New function.
  4438. (segment): Removed.
  4439. (setUserDefinedAuthConfig): New function.
  4440. (resolveHttpAuthConfigItem): New function.
  4441. (resolveFtpAuthConfigItem): New function.
  4442. (resolveHttpProxyAuthConfigItem): New function.
  4443. * src/HttpRequest.h
  4444. (authConfig): Removed.
  4445. (proxyAuthConfig): Removed.
  4446. (setAuthConfig): Removed.
  4447. (setProxyAuthConfig): Removed.
  4448. * src/UrlRequest.h
  4449. (getHeadResult): Added a parameter: authConfigHandle
  4450. * src/common.h
  4451. (SingletonHolder.h): New include.
  4452. * src/main.cc
  4453. (Netrc.h): New include.
  4454. (main): Removed initial values of PREF_FTP_USER, PREF_FTP_PASSWD.
  4455. Added initial value of PREF_NETRC_PATH.
  4456. Added the initialization of netrc.
  4457. * src/AuthConfig.h: New class.
  4458. * src/prefs.h
  4459. (PREF_NETRC_PATH): New definition.
  4460. * src/HttpAuthConfig.h: Removed.
  4461. * src/Netrc.cc
  4462. (getRequiredNextToken): New function.
  4463. (skipMacdef): New function.
  4464. (parse): Rewritten.
  4465. * src/Netrc.h
  4466. (getRequiredNextToken): New function.
  4467. (skipMacdef): New function.
  4468. * src/Util.h, src/Util.cc
  4469. (getHomeDir): New function.
  4470. * src/TrackerWatcherComand.cc
  4471. (createRequestCommand): Use AuthConfig.
  4472. * src/FtpConnection.cc
  4473. (sendUser): Use Request::resolveFtpAuthConfigItem().
  4474. (sendPass): Use Request::resolveFtpAuthConfigItem().
  4475. * src/Request.cc
  4476. (findNetrcAuthenticator): New function.
  4477. (resolveHttpAuthConfigItem): New function.
  4478. (resolveFtpAuthConfigItem): New function.
  4479. (resolveHttpProxyAuthConfigItem): New function.
  4480. * src/UrlRequestInfo.cc: Use AuthConfig.
  4481. * src/HttpRequest.cc
  4482. (createRequest): Use authConfig.
  4483. (getProxyAuthString): Use authConfig.
  4484. (configure): Removed PREF_HTTP_USER, PREF_HTTP_PASSWD,
  4485. PREF_HTTP_PROXY_USER, PREF_HTTP_PROXY_PASSWD.
  4486. 2007-03-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4487. To reduce overhead to find commands whose socket is either
  4488. readable or writable in the download engine loop:
  4489. * src/Command.h, src/Command.cc
  4490. (STATUS): New enum.
  4491. (status): New variable.
  4492. (statusMatch): New function.
  4493. (setStatusActive): New function.
  4494. (setStatusInactive): New function.
  4495. * src/DownloadEngine.h, src/DownloadEngine.cc
  4496. (executeCommand): New function.
  4497. (run): Simplified.
  4498. (waitData): Call Command::setStatusActive() when command's socket is
  4499. readable or writable.
  4500. 2007-03-15 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4501. To handle Segment as SegmentHandle:
  4502. * src/AbstractCommand.cc (execute): Rewritten.
  4503. * src/SegmentMan.h: Segment -> SegmentHandle
  4504. Introducded HttpResponse class, HttpRequest class to improve code
  4505. extensiveness and make it clear:
  4506. * src/HttpDownloadCommand.cc: transfer encoders are now managed by
  4507. HttpResponse class.
  4508. * src/HttpRequest.h, src/HttpRequest.cc: New class.
  4509. * src/HttpResponse.h, src/HttpResponse.cc: New class.
  4510. * src/HttpConnection.cc: Contruction of http request were moved to
  4511. HttpRequest class.
  4512. * src/HttpResponseCommand.h, src/HttpResponseCommand.cc: Refactored.
  4513. * src/HttpRequestCommand.cc (executeInternal): Rewritten.
  4514. * src/HttpAuthConfig.h: New class.
  4515. * src/Range.h: New class.
  4516. To make FtpTunnel{Request, Response}Command and
  4517. HttpProxy{Request, Response}Command derived from
  4518. AbstractProxy{Request, Response}Command:
  4519. * src/FtpTunnelResponseCommand.h, src/FtpTunnelResponseCommand.cc:
  4520. Derived from AbstractProxyRequestCommand class.
  4521. * src/FtpTunnelRequestCommand.h, src/FtpTunnelRequestCommand.cc:
  4522. Derived from AbstractProxyResponseCommand class.
  4523. * src/HttpProxyRequestCommand.h, src/HttpProxyRequestCommand.cc:
  4524. Derived from AbstractProxyRequestCommand class.
  4525. * src/HttpProxyResponseCommand.h, src/HttpProxyResponseCommand.cc:
  4526. Derived from AbstractProxyResponseCommand class.
  4527. * src/AbstractProxyRequestCommand.h, src/AbstractProxyRequestCommand.cc
  4528. : New class.
  4529. * src/AbstractProxyResponseCommand.h,
  4530. src/AbstractProxyResponseCommand.cc: New class.
  4531. To add netrc support:
  4532. * src/Netrc.h, src/Netrc.cc: New class.
  4533. * src/Util.h, src/Util.cc (split): New function.
  4534. * src/HttpHeader.cc (getRange): Fixed so that it inspects
  4535. "Content-Range" header instead of "Range" header.
  4536. * src/HttpHeader.h
  4537. (getStatus): Removed.
  4538. (setStatus): Removed.
  4539. * src/Segment.h
  4540. (getPositionToWrite): New function.
  4541. 2007-03-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4542. * src/HttpHeader.h
  4543. (Range.h): New include.
  4544. (status): New variable.
  4545. (HttpHeader): Initialized status with 0.
  4546. (getStatus): New function.
  4547. (setStatus): New function.
  4548. (getRange): New function.
  4549. (HttpHeaderHandle): New function.
  4550. * src/HttpHeader.cc
  4551. (getRange): New function.
  4552. * src/Request.h
  4553. (RequestWeakHandle): New definition.
  4554. * src/HttpConnection.h
  4555. (HttpConnectionHandle): New type definition.
  4556. * src/HttpConnection.cc
  4557. (receiveResponse): Set HTTP status to headers.
  4558. * src/main.cc
  4559. (showUsage): Fixed typo.
  4560. * src/Segment.h
  4561. (SegmentHandle): New type definition.
  4562. * src/BitfieldMan.h
  4563. (getMissingUnusedLength): New function.
  4564. * src/BitfieldMan.cc
  4565. (getMissingUnusedLength): New function.
  4566. 2007-02-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4567. To fix static initialization order problem:
  4568. * src/BitfieldManFactory.h
  4569. (defaultRandomizer): Removed.
  4570. (factory): New variable.
  4571. (getNewFactory): Removed.
  4572. (getFactoryInstance): New function.
  4573. (setDefaultRandomizer): Rewritten.
  4574. (getDefaultRandomizer): Rewritten.
  4575. * src/BitfieldManFactory.cc
  4576. (defaultRandomizer): Removed.
  4577. (factory): Initialized to 0.
  4578. (BitfieldManFactory): Initialized randomizer to 0.
  4579. * src/DefaultPieceStorage.cc
  4580. (DefaultPieceStorage): getNewFactory() -> getFactoryInstance()
  4581. * src/Peer.cc
  4582. (Peer): getNewFactory() -> getFactoryInstance()
  4583. * src/SegmentMan.cc
  4584. (initBitfield): getNewFactory() -> getFactoryInstance()
  4585. * src/Piece.cc
  4586. (Piece): getNewFactory() -> getFactoryInstance()
  4587. 2007-02-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4588. To fix the bug that causes crash on Max OS X:
  4589. * src/SimpleRandomizer.h
  4590. (getInstance): Create new instance if the static variable is null.
  4591. * src/SimpleRandomizer.cc
  4592. (randomizer): Initialized to 0.
  4593. * src/BitfieldManFactory.h
  4594. (getNewFactory): Removed the call to setRandomizer().
  4595. To fix the miscalculation of the range of checksum:
  4596. * src/BitfieldMan.h
  4597. (isBitSetOffsetRange): New function.
  4598. * src/BitfieldMan.cc
  4599. (isBitSetOffsetRange): New function.
  4600. * src/SegmentMan.cc
  4601. (tryChunkChecksumValidation): Use BitfieldMan::isBitSetOffsetRange().
  4602. Use bitfield->getBlockLength() instead of segment.segmentLength.
  4603. * Release 0.10.1
  4604. 2007-02-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4605. To lower CPU usage in BitTorrent download when --max-upload-limit
  4606. command-line option specified:
  4607. * src/DefaultBtMessageDispatcher.cc
  4608. (sendMessages): Calculate uploading speed only when current message
  4609. is uploading data and is not sent yet.
  4610. * src/DefaultPeerStorage.h
  4611. (MAX_PEER_LIST_SIZE): 100 -> 60, because 60 is well enough.
  4612. * src/HttpResponseCommand.cc
  4613. (handleDefaultEncoding): Added the cast to int32_t to itos.
  4614. This fixes compile error in Soralis 10.
  4615. 2007-01-30 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4616. To fix segfault in Metalink download:
  4617. * src/UrlRequestInfo.h
  4618. (filename): Removed.
  4619. (totalLength): Removed.
  4620. (setTotalLength): Removed.
  4621. (setFilename): Removed.
  4622. * src/MetalinkRequestInfo.cc
  4623. (execute): Do not set filename and totalLength to reqInfo.
  4624. Set chunk checksum to reqInfo if it is not null.
  4625. * src/HttpResponseCommand.cc
  4626. (executeInternal): Fixed filename in log.
  4627. (handleDefaultEncoding): Removed the call to initBitfield() and
  4628. markAllPiecesDone().
  4629. (handleOtherEncoding): Added HEAD method handling.
  4630. * src/FtpNegotiateCommand.cc
  4631. (executeInternal): Added SEQ_HEAD_OK handling.
  4632. (recvSize): In HEAD handling, set sequence to SEQ_HEAD_OK and
  4633. return false.
  4634. * src/FtpNegotiateCommand.h
  4635. (SEQ_HEAD_OK): New definition.
  4636. * src/SegmentMan.cc
  4637. (initBitfield): Delete bitfield.
  4638. (isChunkChecksumValidationReady): Fixed the condition.
  4639. * src/UrlRequestInfo.cc: Fixed so that Metalink and Torrent download
  4640. works fine.
  4641. 2007-01-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4642. * src/Xml2MetalinkProcessor.h
  4643. (xpathExists): New function.
  4644. * src/Xml2MetalinkProcessor.cc
  4645. (xpathExists): New function.
  4646. Not to send HEAD request if filename and size are available in Metalink
  4647. file:
  4648. * src/UrlRequestInfo.h
  4649. (filename): New variable.
  4650. (totalLength): New variable.
  4651. (setTotalLength): New function.
  4652. (setFilename): New function.
  4653. * src/MetalinkRequestInfo.cc
  4654. (execute): Set filename and size to UrlRequestInfo.
  4655. * src/MetalinkEntry.cc
  4656. (MetalinkEntry): Initialize size with 0.
  4657. * src/UrlRequestInfo.cc
  4658. (execute): Set filename and size to SegmentMan.
  4659. Not to download rest of the files after selected files are downloaded
  4660. in BitTorrent:
  4661. * src/PieceStorage.h
  4662. (allDownloadFinished): New function.
  4663. * src/DefaultBtAnnounce.cc
  4664. (isCompleteAnnounceReady): Use allDownloadFinished instead of
  4665. downloadFinished.
  4666. (getAnnounceUrl): Use allDownloadFinished instead of downloadFinished.
  4667. * src/DefaultPieceStorage.cc
  4668. (completePiece): Use allDownloadFinished instead of downloadFinished.
  4669. Commented out the call to finishSelectiveDownloadingMode().
  4670. (downloadFinished): Call isFilteredAllBitSet() instead of
  4671. isAllBitSet().
  4672. (allDownloadFinished): New function.
  4673. * src/DefaultBtInteractive.cc
  4674. (addBitfieldMessageToQueue): Call allDownloadFinished() instead of
  4675. downloadFinished().
  4676. (checkHave): Call allDownloadFinished() instead of downloadFinished().
  4677. * src/TorrentDownloadEngine.cc
  4678. (onEndOfRun): Call allDownloadFinished() instead of downloadFinished().
  4679. * src/BitfieldMan.h
  4680. (isFilteredAllBitSet): New function.
  4681. * src/ShareRatioSeedCriteria.h
  4682. (PieceStorage.h): New include.
  4683. (pieceStorage): New variable.
  4684. (evaluate):
  4685. btContext->getTotalLength() -> pieceStorage->getCompletedLength()
  4686. * src/BitfieldMan.cc
  4687. (isFilteredAllBitSet): New function.
  4688. (isAllBitSet): Filter is not took into account.
  4689. Rename --force-truncate as --allow-overwrite:
  4690. * src/TorrentRequestInfo.cc
  4691. (execute): PREF_FORCE_TRUNCATE -> PREF_ALLOW_OVERWRITE
  4692. * src/main.cc
  4693. (showUsage): --force-truncate -> --allow-overwrite
  4694. * src/message.h
  4695. (EX_FILE_ALREADY_EXISTS): --force-truncate -> --allow-overwrite
  4696. * src/prefs.h
  4697. (PREF_FORCE_TRUNCATE): Removed.
  4698. (PREF_ALLOW_OVERWRITE): New definition.
  4699. * src/SegmentMan.cc
  4700. (shouldCancelDownloadForSafety): --force-truncate -> --allow-overwrite
  4701. * src/MetalinkRequestInfo.cc
  4702. (execute): Queueing message are now logged in info level.
  4703. * src/common.h
  4704. (LONG_LONG_MAX): Removed.
  4705. (LONG_LONG_MIN): Removed.
  4706. * src/HttpResponseCommand.cc
  4707. (handleDefaultEncoding): LONG_LONG_MAX -> INT64_MAX
  4708. * src/FtpNegotiateCommand.cc
  4709. (recvSize): LONG_LONG_MAX -> INT64_MAX
  4710. * src/main.cc
  4711. (showUsage): Added --check-integriy and --realtime-chunk-checksum
  4712. command-line option.
  4713. (main): Added --check-integriy and --realtime-chunk-checksum
  4714. command-line option.
  4715. --force-truncate -> --allow-overwrite
  4716. Set initial value of --check-integrity option to false.
  4717. Don't show usage when error occurs while persing command-line options.
  4718. Removed deprecated --upload-limit option.
  4719. 2007-01-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4720. * src/message.h: Added EX_INVALID_PAYLOAD_SIZE and
  4721. EX_INVALID_BT_MESSAGE_ID. Following source files affected.
  4722. * src/BtAllowedFastMessage.cc:
  4723. * src/BtBitfieldMessage.cc
  4724. * src/BtCancelMessage.cc
  4725. * src/BtChokeMessage.cc
  4726. * src/BtHaveAllMessage.cc
  4727. * src/BtHaveMessage.cc
  4728. * src/BtHaveNoneMessage.cc
  4729. * src/BtInterestedMessage.cc
  4730. * src/BtNotInterestedMessage.cc
  4731. * src/BtPieceMessage.cc
  4732. * src/BtPortMessage.cc
  4733. * src/BtRejectMessage.cc
  4734. * src/BtRequestMessage.cc
  4735. * src/BtSuggestPieceMessage.cc
  4736. * src/BtUnchokeMessage.cc
  4737. * src/message.h: Added EX_INVALID_CHUNK_CHECKSUM. Following source
  4738. files are affected.
  4739. * src/ChunkChecksumValidator.cc
  4740. * src/SegmentMan.cc
  4741. 2007-01-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4742. To add chunk checksum validation:
  4743. * src/MetalinkEntry.h
  4744. (MetalinkChunkChecksum.h): New include.
  4745. (chunkChecksum): New variable.
  4746. * src/Request.h
  4747. (method): New variable.
  4748. (setMethod): New function.
  4749. (getMethod): New function.
  4750. (METHOD_GET): New static constant.
  4751. (METHOD_HEAD): New static constant.
  4752. * src/Xml2MetalinkProcessor.h
  4753. (getPieceHash): New function.
  4754. * src/PieceStorage.h
  4755. (markAllPiecesDone): New function.
  4756. (checkIntegrity): New function.
  4757. * src/FileAllocator.h
  4758. (NullFileAllocationMonitor.h): New include.
  4759. (FileAllocator): Initialize fileAllocationMonitor with new
  4760. NullFileAllocationMonitor().
  4761. * src/MultiDiskAdaptor.h
  4762. (messageDigest.h): Remove include.
  4763. (ctx): Removed.
  4764. (hashUpdate): Added ctx.
  4765. (MultiDiskAdaptor): Removed ctx.
  4766. (sha1Sum): Renamed as messageDigest.
  4767. (messageDigest): New function.
  4768. * src/UrlRequestInfo.h
  4769. (HeadResult): New class.
  4770. (digestAlgo): New variable.
  4771. (chunkChecksumLength): New variable.
  4772. (chunkChecksums): New variable.
  4773. (getHeadResult): New function.
  4774. (UrlRequestInfo): Added digestAlgo, chunkChecksumLength.
  4775. (setDigestAlgo): New function.
  4776. (setChunkChecksumLength): New function.
  4777. (setChunkChecksums): New function.
  4778. * src/DefaultPieceStorage.cc
  4779. (DiskAdaptorWriter.h): New include.
  4780. (ChunkChecksumValidator.h): New include.
  4781. (markAllPiecesDone): New function.
  4782. (checkIntegrity): New function.
  4783. * src/DefaultBtContext.h
  4784. (getPieceHashes): New function.
  4785. * src/TorrentRequestInfo.cc
  4786. (execute): Try to validate chunk checksum if file already exists and
  4787. .aria2 file doesn't there and user allows aria2 to overwrite it.
  4788. * src/messageDigest.h
  4789. (~MessageDigestContext): Added digestFree().
  4790. * src/MetalinkRequestInfo.cc
  4791. (execute): Set digestAlgo, chunkChecksum, chunkChecksums to reqInfo.
  4792. * src/DiskAdaptor.h
  4793. (messageDigest.h): New include.
  4794. (sha1Sum): Renamed as messageDigest.
  4795. (messageDigest): New function.
  4796. * src/DownloadCommand.h
  4797. (PeerStat.h): New include.
  4798. (maxDownloadSpeedLimit): New variable.
  4799. (startupIdleTime): New variable.
  4800. (lowestDownloadSpeedLimit): New variable.
  4801. (peerStat): New variable.
  4802. (setMaxDownloadSpeedLimit): New function.
  4803. (setStartupIdleTime): New function.
  4804. (setLowestDownloadSPeedLimit): New function.
  4805. * src/BtContext.h
  4806. (getPieceHashes): New function.
  4807. * src/main.cc
  4808. (main): Set PREF_REALTIME_CHUNK_CHECKSUM and PREF_CHECK_INTEGRITY
  4809. option to true for testing purpose.
  4810. * src/BtPieceMessage.cc
  4811. (checkPieceHash): Use messageDigest
  4812. * src/DownloadEngine.cc
  4813. (SetDescriptor): Removed.
  4814. (AccumulateActiveCommand): Removed.
  4815. (waitData): Rewritten.
  4816. (updateFdSet): Rewritten.
  4817. * src/MultiDiskAdaptor.cc
  4818. (hashUpdate): Added ctx.
  4819. (sha1Sum): Renamed as messageDigest.
  4820. (messageDigest): New function.
  4821. * src/BitfieldMan.h
  4822. (isBitRangeSet): New function.
  4823. (unsetBitRange): New function.
  4824. * src/ByteArrayDiskWriter.h
  4825. (sha1Sum): Renamed as messageDigest.
  4826. (messageDigest): New function.
  4827. * src/ConsoleDownloadEngine.cc
  4828. (calculateStatistics): If nspeed < 0 then set nspeed to 0.
  4829. * src/DiskWriter.h
  4830. (messageDigest.h): New include.
  4831. (sha1Sum): Renamed as messageDigest.
  4832. (messageDigest): New function.
  4833. * src/ChunkChecksumValidator.h: New class.
  4834. * src/DiskAdaptorWriter.h: New class.
  4835. * src/prefs.h
  4836. (PREF_REALTIME_CHUNK_CHECKSUM): New definition.
  4837. (PREF_CHECK_INTEGRITY): New definition.
  4838. * src/HttpResponseCommand.cc
  4839. (handleDefaultEncoding): Added method "HEAD" handling.
  4840. Removed the call to e->segmentMan->shouldCancelDownloadForSafety().
  4841. (handleOtherEncoding):
  4842. Added the call to e->segmentMan->shouldCancelDownloadForSafety().
  4843. (createHttpDownloadCommand): Set maxDownloadSpeedLimit,
  4844. startupIdleTime, lowestDownloadSpeedLimit to command.
  4845. * src/SegmentMan.h
  4846. (getSegmentEntryByIndex): New function.
  4847. (getSegmentEntryByCuid): New function.
  4848. (getSegmentEntryIteratorByCuid): New function.
  4849. (diskWriter): DiskWriter -> DiskWriterHandle
  4850. (pieceHashes): New variable.
  4851. (chunkHashLength): New variable.
  4852. (digestAlgo): New variable.
  4853. (FindPeerStat): Removed.
  4854. (getPeerStat): Rewritten.
  4855. (markAllPiecesDone): New function.
  4856. (checkIntegrity): New function.
  4857. (tryChunkChecksumValidation): New function.
  4858. (isChunkChecksumValidationReady): New function.
  4859. * src/BitfieldMan.cc
  4860. (BitfieldMan): Initialized bitfieldLength, blocks to 0.
  4861. (BitfieldMan): Initialized blockLength, totalLength, bitfieldLength,
  4862. blocks to 0.
  4863. (isBitRangeSet): New function.
  4864. (unsetBitRange): New function.
  4865. * src/FtpNegotiateCommand.cc
  4866. (executeInternal): Set maxDownloadSpeedLimit,
  4867. startupIdleTime, lowestDownloadSpeedLimit to command.
  4868. (recvSize): Added method "HEAD" handling.
  4869. Removed the call to e->segmentMan->shouldCancelDownloadForSafety().
  4870. * src/AbstractSingleDiskAdaptor.cc
  4871. (sha1Sum): Renamed as messageDigest.
  4872. (messageDigest): New function.
  4873. * src/AbstractSingleDiskAdaptor.h
  4874. (sha1Sum): Renamed as messageDigest.
  4875. (messageDigest): New function.
  4876. * src/Util.h
  4877. (indexRange): New function.
  4878. * src/MetalinkEntry.cc
  4879. (MetalinkEntry): Initialized chunkChecksum to 0.
  4880. * src/ShaVisitor.cc
  4881. (~ShaVisitor): Removed the call to ctx.digestFree().
  4882. * src/SegmentMan.cc
  4883. (ChunkChecksumValidator.h): New include.
  4884. (SegmentMan): Initialized chunkHashLength to 0. Initialized digestAlgo
  4885. to DIGEST_ALGO_SHA1.
  4886. (~SegmentMan): Removed diskWriter.
  4887. (FindSegmentEntryByIndex): Removed.
  4888. (FindSegmentEntryByCuid): Removed.
  4889. (checkoutSegment): Rewritten.
  4890. (findSlowerSegmentEntry): Rewritten.
  4891. (getSegment): Rewritten.
  4892. (updateSegment): Rewritten.
  4893. (completeSegment): Rewritten.
  4894. (markAllPiecesDone): New function.
  4895. (checkIntegrity): New function.
  4896. (isChunkChecksumValidationReady): New function.
  4897. (tryChunkChecksumValidation): New function.
  4898. * src/Xml2MetalinkProcessor.cc
  4899. (getEntry): Get size and set it to entry.
  4900. Get chunk checksum and set it to entry.
  4901. (getPieceHash): New function.
  4902. * src/Util.cc
  4903. (sha1Sum): Removed ctx.digestFree()
  4904. (fileChecksum): Removed ctx.digestFree()
  4905. (indexRange): New function.
  4906. * src/Request.cc
  4907. (METHOD_GET): New variable.
  4908. (METHOD_HEAD): New variable.
  4909. (Request): Added method.
  4910. * src/UrlRequestInfo.cc
  4911. (FatalException.h): New include.
  4912. (message.h): New include.
  4913. (operator<<): Added operator<< for class HeadResult.
  4914. (getHeadResult): New function.
  4915. (execute): Get filename and size in separate download engine.
  4916. * src/ChunkChecksumValidator.cc: New class.
  4917. * src/DownloadCommand.cc:
  4918. (DownloadCommand): Added peerStat.
  4919. (executeInternal): Use maxDownloadSpeedLimit member instead of getting
  4920. the value from Option.
  4921. The buffer size is now 16KB.
  4922. Use peerStat member instead of getting it from SegmentMan.
  4923. Use startupIdleTime member instead of gettingit from Option.
  4924. Added chunk checksum validation.
  4925. * src/AbstractDiskWriter.cc
  4926. (AbstractDiskWriter): Removed ctx.
  4927. (~AbstractDiskWriter): Removed ctx.digestFree()
  4928. (writeDataInternal): Returns the return value of write.
  4929. (readDataInternal): Returns the return value of read.
  4930. (sha1Sum): Renamed as messageDigest
  4931. (messageDigest): New function.
  4932. * src/AbstractDiwkWriter.h
  4933. (messageDigest.h): Removed include.
  4934. (ctx): Removed.
  4935. (sha1Sum): Renamed as messageDigest
  4936. (messageDigest): New function.
  4937. * src/DefaultPieceStorage.h
  4938. (markAllPiecesDone): New function.
  4939. (checkIntegrity): New function.
  4940. * src/NullFileAllocationMonitor.h: New class.
  4941. * src/MetalinkChunkChecksum.h: New class.
  4942. 2007-01-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  4943. To decrease CPU usage in bittorrent download, calculation results in
  4944. BitfieldMan were cached and realtime fetching PeerObject was removed
  4945. with WeakHandle introduced. Option values are set to the objects
  4946. by setter before download begins.
  4947. * src/DefaultBtRequestFactory.cc: Use messageFactory member.
  4948. * src/DefaultBtRequestFactory.h
  4949. (dispatcher): BtMessageDispatcherHandle ->
  4950. BtMessageDispatcherWeakHandle.
  4951. (messageFactory): New variable.
  4952. (setBtMessageDispatcher): BtMessageDispatcherHandle ->
  4953. BtMessageDispatcherWeakHandle.
  4954. (setBtMessageFactory): New function.
  4955. * src/DefaultBtMessageDispatcher.cc:
  4956. (sendMessages): Use maxUploadSpeedLimit instead of fetching the value
  4957. from Option.
  4958. (checkRequestSlotAndDoNecessaryThing): Use requestTimeout instead of
  4959. feating the value from Option.
  4960. Use messageFactory member.
  4961. * src/PeerInteractionCommand.cc
  4962. (PeerInteractionCommand): Added maxDownloadSpeedLimit.
  4963. Add reverse dependencies to factory object.
  4964. Set maxUploadSpeedLimit and requestTimeout and messageFactory to
  4965. dispatcher.
  4966. Set messageFactory to receiver.
  4967. Set keepAliveInterval and maxDownloadSpeedLimit and messageFactory to
  4968. btInteractive.
  4969. Set receiver to peerObject.
  4970. Set maxDownloadSpeedLimit to this.
  4971. (executeInternal): Use maxDownloadSpeedLimit member.
  4972. * src/BtChokeMessage.cc
  4973. (doReceivedAction): Use dispatcher, requestFactory member.
  4974. (onSendComplete): Use dispatcher member.
  4975. * src/PeerInteractionCommand.h
  4976. (maxDownloadSpeedLimit): New variable.
  4977. * src/DefaultBtMessageReceiver.h
  4978. (peerConnection): PeerConnectionHandle -> PeerConnectionWeakHandle
  4979. (dispatcher):
  4980. BtMessageDispatcherHandle -> BtMessageDispatcherWeakHandle
  4981. (messageFactory): New variable.
  4982. (setPeerConnection): PeerConnectionHandle -> PeerConnectionWeakHandle
  4983. (getPeerConnection): PeerConnectionHandle -> PeerConnectionWeakHandle
  4984. (setDispatcher):
  4985. BtMessageDispatcherHandle -> BtMessageDispatcherWeakHandle
  4986. (setBtMessageFactory): New function.
  4987. * src/DefaultBtInteractive.cc
  4988. (initiateHandshake): Use messageFactory member.
  4989. (addBitfieldMessageToQueue): Use messageFactory member.
  4990. (addAllowedFastMessageToQueue): Use messageFactory member.
  4991. (decideChoking): Use messageFactory member.
  4992. (checkHave): Use messageFactory member.
  4993. (sendKeepAlive): Use keepAliveInterval, messageFactory member.
  4994. (receiveMessages): Use maxDownloadSpeedLimit member.
  4995. (decideInterest): Use messageFactory member.
  4996. * src/BtRequestMessage.cc
  4997. (doReceivedAction): Use messageFactory, dispatcher member.
  4998. (onQueued): Use dispatcher member.
  4999. * src/BtPieceMessage.cc
  5000. (doReceivedAction): Use dispatcher member.
  5001. (send): Use peerConnection member.
  5002. (onWrongPiece): Use requestFactory member.
  5003. (handleChokingEvent): Use messageFactory, dispatcher member.
  5004. (handleCancelSendingPieceEvent): Use messageFactory, dispatcher member.
  5005. * src/BtMessageDispatcher.h
  5006. (BtMessageDispatcherWeakHandle): New type definition.
  5007. * src/SimpleBtMessage.cc
  5008. (send): Use peerConnection member.
  5009. * src/BtRejectMessage.cc
  5010. (doReceivedAction): Use dispatcher member.
  5011. * src/DefaultBtMessageDispatcher.h
  5012. (Option.h): Removed include.
  5013. (messageFactory): New variable.
  5014. (option): Removed.
  5015. (maxUploadSpeedLimit): New variable.
  5016. (requestTimeout): New variable.
  5017. (DefaultBtMessageDispatcher): Removed option.
  5018. Added maxUploadSpeedLimit, requestTimeout.
  5019. (setOption): Removed.
  5020. (getOption): Removed.
  5021. (setMaxUploadSpeedLimit): New function.
  5022. (setRequestTimeout): New function.
  5023. (setBtMessageFactory): New function.
  5024. * src/DefaultBtInteractive.h
  5025. (btMessageReceiver):
  5026. BtMessageReceiverHandle -> BtMessageReceiverWeakHandle
  5027. (dispatcher):
  5028. BtMessageDispatcherHandle -> BtMessageReceiverWeakHandle
  5029. (btRequestFactory):
  5030. BtRequestFactoryHandle -> BtRequestFactoryWeakHandle
  5031. (peerConnection):
  5032. PeerConnectionHandle -> PeerConnectionWeakHandle
  5033. (messageFactory): New variable.
  5034. (option): Removed.
  5035. (keepAliveInterval): New variable.
  5036. (maxDownloadSpeedLimit): New variable.
  5037. (DefaultBtInteractive): Added keepAliveInterval, maxDownloadSpeedLimit.
  5038. (setBtMessageReceiver):
  5039. BtMessageReceiverHandle -> BtMessageReceiverWeakHandle
  5040. (setDispatcher):
  5041. BtMessageDispatcherHandle -> BtMessageReceiverWeakHandle
  5042. (setBtRequestFactory):
  5043. BtRequestFactoryHandle -> BtRequestFactoryWeakHandle
  5044. (setPeerConnection):
  5045. PeerConnectionHandle -> PeerConnectionWeakHandle
  5046. (setOption): Removed.
  5047. (setKeepAliveInterval): New function.
  5048. (setMaxDownloadSpeedLimit): New function.
  5049. (setBtMessageFactory): New function.
  5050. * src/BitfieldMan.h
  5051. (cachedNumMissingBlock): New variable.
  5052. (cachedNumFilteredBlock): New variable.
  5053. (cachedCompletedLength): New variable.
  5054. (cachedFilteredComletedLength): New variable.
  5055. (cachedFilteredTotalLength): New variable.
  5056. (countMissingBlockNow): New function.
  5057. (countFilteredBlockNow): New function.
  5058. (getFilteredTotalLengthNow): New function.
  5059. (getCompletedLengthNow): New function.
  5060. (getFilteredCompletedLengthNow): New function.
  5061. (updateCache): New function.
  5062. * src/AbstractBtMessage.h
  5063. (BtMessageDispatcher.h): New include.
  5064. (PeerConnection.h): New include.
  5065. (BtRequestFactory.h): New include
  5066. (BtMessageFactory.h): New include.
  5067. (dispatcher): New variable.
  5068. (messageFactory): New variable.
  5069. (peerConnection: New variable.
  5070. (setBtMessageDispatcher): New function.
  5071. (setPeerConnection): New function.
  5072. (setBtMessageFactory): New function.
  5073. (setBtRequestFactory): New function.
  5074. * src/DefaultBtMessageFactory.cc
  5075. (setCommonProperty): Set dispatcher, requestFactory, this,
  5076. peerConnection to msg.
  5077. * src/BtRegistry.h
  5078. (BT_MESSAGE_RECEIVER): New macro.
  5079. * src/PeerConnection.h
  5080. (PeerConnectionWeakHandle): New type definition.
  5081. * src/BtMessageFactory.h
  5082. (BtMessageFactoryWeakHandle): New type definition.
  5083. * src/BitfieldMan.cc
  5084. (BitfieldMan): Added cachedNumMissingBlock, cachedNumFilteredBlock,
  5085. cachedCompletedLength, cachedFilteredComletedLength,
  5086. cachedFilteredTotalLength.
  5087. Call updateCache().
  5088. (countMissingBlock): Return cachedNumMissingBlock.
  5089. (countMissingBlockNow): New function.
  5090. (countBlock): Return cachedNumFilteredBlock if filterEnabled is true.
  5091. (countFilteredBlockNow): New function.
  5092. (setBit): Call updateCache().
  5093. (unsetBit): Call updateCache().
  5094. (setBitfield): Call updateCache().
  5095. (clearAllBit): Call updateCache().
  5096. (setAllBit): Use setBitInternal instead of setBit.
  5097. Call updateCache().
  5098. (addFilter): Call updateCache().
  5099. (enableFilter): Call updateCache().
  5100. (disableFilter): Call updateCache().
  5101. (clearFilter): Call updateCache().
  5102. (getFilteredTotalLength): Return cachedFilteredTotalLength.
  5103. (getFilteredTotalLengthNow): New function.
  5104. (getCompletedLength): Return cachedCompletedLength.
  5105. (getCompletedLengthNow): New function.
  5106. (getFilteredCompletedLength): Return cachedFilteredComletedLength.
  5107. (getFilteredCompletedLengthNow): New function.
  5108. (updateCache): New function.
  5109. * src/BtMessageReceiver.h
  5110. (BtMessageReceiverWeakHandle): New type definition.
  5111. * src/DefaultBtMessageReceiver.cc
  5112. (receiveHandshake): Use messageFactory member.
  5113. (sendHandshake): Use messageFactory member.
  5114. (receiveMessage): Use messageFactory member.
  5115. * src/DefaultBtMessageFactory.h
  5116. (dispatcher): New variable.
  5117. (requestFactory): New variable.
  5118. (peerConnection): New variablle.
  5119. (setBtMessageDispatcher): New function.
  5120. (setBtRequestFactory): New function.
  5121. (setPeerConnection): New function.
  5122. * src/SharedHandle.h
  5123. (RefCount): New class.
  5124. (WeakHandle): New class.
  5125. * src/PeerObject.h
  5126. (BtMessageReceiver.h): New include.
  5127. (PeerObject): Added btMessageReceiver.
  5128. (btMessageReceiver): New variable.
  5129. * src/Util.cc
  5130. (countBit): Simplified.
  5131. * src/BtCancelMessage.cc
  5132. (doReceivedAction): Use dispatcher member.
  5133. * src/BtRequestFactory.h
  5134. (BtRequestFactoryWeakHandle): New type definition.
  5135. * src/PeerStorage.h
  5136. (downloadSpeed): int -> uint32_t
  5137. (uploadSpeed): int -> uint32_t
  5138. (sessionDownloadLength): long long int -> uint64_t
  5139. (sessionUploadLength): long long int -> uint64_t
  5140. 2007-01-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  5141. To add RecoverableException, FatalException:
  5142. * src/AbstractCommand.cc
  5143. (onAbort): Exception -> RecoverableException
  5144. * src/PeerAbstractCommand.h
  5145. (RecoverableException.h): New include.
  5146. (onAbort): Exception -> RecoverableException.
  5147. * src/PeerInteractionCommand.cc
  5148. (onAbort): Exception -> RecoverableException.
  5149. * src/PeerAbstractCommand.cc
  5150. (execute): Exception -> RecoverableException.
  5151. (onAbort): Exception -> RecoverableException.
  5152. * src/TorrentRequestInfo.cc
  5153. (execute): Exception -> RecoverableException.
  5154. * src/MetalinkRequestInfo.cc
  5155. (execute): Exception -> RecoverableException.
  5156. * src/MetaFileUtil.cc: RecoverableException.
  5157. * src/AbstractCommand.h
  5158. (onAbort): Exception -> RecoverableException.
  5159. * src/DlRetryEx.h: Exception -> RecoverableException.
  5160. * src/DlAbortEx.h: Exception -> RecoverableException.
  5161. * src/PeerListenCommand.cc: Exception -> RecoverableException.
  5162. * src/Util.cc: Exception -> RecoverableException.
  5163. * src/DefauldDiskWriter.cc: Exception -> RecoverableException.
  5164. * src/TrackerUpdateCommand.cc: Exception -> RecoverableException.
  5165. * src/UrlRequestInfo.cc: Exception -> RecoverableException.
  5166. To make ID static const int
  5167. * src/BtInterestedMessage.h
  5168. (ID_t): Removed.
  5169. (ID): New variable.
  5170. (getId): Made non-const.
  5171. * src/BtPieceMessage.h
  5172. (ID_t): Removed.
  5173. (ID): New variable.
  5174. (getId): Made non-const.
  5175. * src/BtChokeMessage.h
  5176. (ID_t): Removed.
  5177. (ID): New variable.
  5178. (getId): Made non-const.
  5179. * src/BtHaveAllMessage.h
  5180. (ID_t): Removed.
  5181. (ID): New variable.
  5182. (getId): Made non-const.
  5183. * src/BtKeepAliveMessage.h
  5184. (ID_t): Removed.
  5185. (ID): New variable.
  5186. (getId): Made non-const.
  5187. * src/BtHandshakeMessage.h
  5188. (ID): New variable.
  5189. (getId): Made non-const.
  5190. * src/BtSuggestPieceMessage.h
  5191. (ID_t): Removed.
  5192. (ID): New variable.
  5193. (getId): Made non-const.
  5194. * src/BtPortMessage.h
  5195. (ID_t): Removed.
  5196. (ID): New variable.
  5197. (getId): Made non-const.
  5198. * src/AbstractBtMessage.h
  5199. (id): Removed.
  5200. (AbstractBtMessage): Removed id.
  5201. (getId): Removed.
  5202. * src/BtHaveMessage.h
  5203. (ID_t): Removed.
  5204. (ID): New variable.
  5205. (getId): Made non-const.
  5206. * src/BtAllowedFastMessage.h
  5207. (ID_t): Removed.
  5208. (ID): New variable.
  5209. (getId): Made non-const.
  5210. * src/BtCancelMessage.h
  5211. (ID_t): Removed.
  5212. (ID): New variable.
  5213. (getId): Made non-const.
  5214. * src/BtNotInterestedMessage.h
  5215. (ID_t): Removed.
  5216. (ID): New variable.
  5217. (getId): Made non-const.
  5218. * src/BtChokeMessage.h
  5219. (ID_t): Removed.
  5220. (ID): New variable.
  5221. (getId): Made non-const.
  5222. * src/BtRejectMessage.h
  5223. (ID_t): Removed.
  5224. (ID): New variable.
  5225. (getId): Made non-const.
  5226. * src/BtBitfieldMessage.h
  5227. (ID_t): Removed.
  5228. (ID): New variable.
  5229. (getId): Made non-const.
  5230. * src/BtUnchokeMessage.h
  5231. (ID_t): Removed.
  5232. (ID): New variable.
  5233. (getId): Made non-const.
  5234. * src/BtRequestMessage.h
  5235. (ID_t): Removed.
  5236. (ID): New variable.
  5237. (getId): Made non-const.
  5238. * src/BtHaveMessage.h
  5239. (ID_t): Removed.
  5240. (ID): New variable.
  5241. (getId): Made non-const.
  5242. To add --force-truncate command-line option and a check whether
  5243. the file already exists:
  5244. * src/DirectDiskAdaptor.h
  5245. (getFilePath): Made virtual public.
  5246. * src/MultiDiskAdaptor.h
  5247. (File.h): New include.
  5248. (DiskWriterEntry::fileEntry): Made private.
  5249. (DiskWriterEntry::fileExists): New function.
  5250. (DiskWriterEntry::getFileEntry): New function.
  5251. (fileExists): New function.
  5252. (getFilePath): New function.
  5253. * src/TorrentRequestInfo.cc
  5254. (FatalException.h): New include.
  5255. (message.h): New include.
  5256. (RecoverableException.h): New include.
  5257. (execute): Added a check whether file is already exists or not.
  5258. * src/DiskAdaptor.h
  5259. (fileExists): New function.
  5260. (getFilePath): New function.
  5261. * src/main.cc
  5262. (showUsage): Added an explanation of --force-truncate command-line
  5263. option.
  5264. (main): Added --force-truncate command-line option.
  5265. * src/Exception.h
  5266. (setMsg): buf[256] -> buf[1024]
  5267. * src/CopyDiskWriter.h
  5268. (getFilePath): Made public virtual.
  5269. * src/MultiDiskAdaptor.cc: fileEntry -> getFileEntry()
  5270. (fileExists): New function.
  5271. * src/DownloadEngineFactory.cc
  5272. (newTorrentConsoleEngine): Don't open file here.
  5273. * src/message.h
  5274. (EX_FILE_ALREADY_EXISTS): New definition.
  5275. * src/prefs.h
  5276. (PREF_FOECE_TRUNCATE): New definition.
  5277. * src/HttpResponseCommand.cc
  5278. (handleDefaultEncoding): Added a check whether the file already exists.
  5279. * src/SegmentMan.h
  5280. (fileExists): New function.
  5281. (shouldCancelDownloadForSafety): New function.
  5282. * src/FtpNegotiateCommand.cc
  5283. (recvSize): Added a check whether the file already exists.
  5284. * src/AbstractSingleDiskAdaptor.cc
  5285. (File.h): New include.
  5286. (fileExists): New function.
  5287. * src/AbstractSingleDiskAdaptor.h
  5288. (getFilePath): Removed.
  5289. (fileExists): New function.
  5290. * src/SegmentMan.cc
  5291. (fileExists): New function.
  5292. (shouldCancelDownloadForSafety): New function.
  5293. To fix regression bug in torrent downloading:
  5294. * src/DefaultBtRequestFactory.cc
  5295. (doChokedAction): New function.
  5296. * src/DefaultBtRequestFactory.h
  5297. (doChokedAction): New function.
  5298. * src/DefaultBtMessageDispatcher.cc
  5299. (doChokedAction): Do not delete request if its target is in allowed
  5300. fast set.
  5301. * src/DefaultBtInteractive.cc
  5302. (doPostHandshakeProcessing): Added a call to sendPendingMessage().
  5303. (sendKeepAlive): Send keep alive message even if the outgoing message
  5304. queue is not empty.
  5305. (decideInterest): Simplified the code.
  5306. (fillPiece): Remove a call to dispatcher->doChokedAction() because
  5307. it is already called when BtChokeMessage is received from a peer.
  5308. * src/BtRequestFactory.h
  5309. (doChokedAction): New function.
  5310. To clean up code:
  5311. * src/PeerInteractionCommand.h
  5312. (executeInternal): Added virtual keyword explicitly.
  5313. (prepareForRetry): Added virtual keyword explicitly.
  5314. (prepareForNextPeer): Added virtual keyword explicitly.
  5315. (onAbort): Added virtual keyword explicitly.
  5316. * src/RequestSlot.cc
  5317. (isTimeout): Use Time::elapsed() instead of differenceInMillis().
  5318. * src/BtPieceMessage.cc
  5319. (doReceivedAction): Added a debug log of piece's bitfield.
  5320. * src/Piece.h
  5321. (getBitfieldLength): New function.
  5322. * src/ByteArrayDiskWriter.cc
  5323. (clear): Added buf = 0 to avoid double free corruption.
  5324. * src/FileAllocator.cc
  5325. (allocate): Fixed an assignment of fileAllocationMonitor->currentValue.
  5326. Added cp.reset().
  5327. * src/BitfieldMan.h
  5328. (operator=): Rewritten.
  5329. * src/BitfieldMan.cc
  5330. (BitfieldMan): Initialized bitfield, useBitfield.
  5331. * src/PeerConnection.cc
  5332. (receiveMessage): Added a call to socket->readable() after getting
  5333. message length to avoid possible EOF.
  5334. * src/Util.cc
  5335. (torrentUrlencode): Fixed an encodeing bug. BUG#1629912
  5336. 2007-01-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  5337. To add an ability to pre-allocate file space:
  5338. * src/DirectDiskAdaptor.h: Rewritten.
  5339. * src/PieceStorage.h: DiskAdaptor -> DiskAdaptorHandle
  5340. * src/MultiDiskAdaptor.h: Rewritten.
  5341. * src/DefaultPieceStorage.cc
  5342. (MultiDiskWriter.h): Removed include.
  5343. (PreAllocationDiskWriter.h): Removed include.
  5344. (FileAllocationMonitor.h): New include.
  5345. (~DefaultPieceStorage): Removed deletion of diskAdaptor.
  5346. (initStorage): Rewritten.
  5347. (getDiskAdaptor): DiskAdaptor -> DiskAdaptorHandle
  5348. * src/FileAllocator.h: New class.
  5349. * src/FileAllocator.cc: New class.
  5350. * src/FileAllocationMonitor.h: New class.
  5351. * src/FileAllocationMonitor.cc: New class.
  5352. * src/ConsoleFileAllocationMonitor.h: New class.
  5353. * src/ConsoleFileAllocationMonitor.cc: New class.
  5354. * src/AbstractSingleDiskAdaptor.h: New class.
  5355. * src/AbstractSingleDiskAdaptor.cc: New class.
  5356. * src/DiskAdaptor.h
  5357. (Directory.h): Removed include.
  5358. (DiskWriter.h): Removed include.
  5359. (FileEntry.h): Removed include.
  5360. (diskWriter): Removed.
  5361. (DiskAdaptor): Removed diskWriter.
  5362. (openFile): Made pure virtual.
  5363. (closeFile): Made pure virtual.
  5364. (openExistingFile): Made pure virtual.
  5365. (initAndOpenFile): Made pure virtual.
  5366. (writeData): Made pure virtual.
  5367. (readData): Made pure virtual.
  5368. (sha1Sum): Made pure virtual.
  5369. (getStoreDir): Returns const reference of storeDir.
  5370. (DiskAdaptorHandle): New type definition.
  5371. * src/main.cc
  5372. (ConsoleFileAllocationMonitor.h): New include.
  5373. (showUsage): Added default value description of -s option.
  5374. Added the description of --file-allocation option.
  5375. (main): Set default value of --file-allocation option to 'none'.
  5376. Added --file-allocation command-line option.
  5377. Setup FileAllocationMonitorFactory.
  5378. * src/FtpInitiateConnectionCommand.cc
  5379. (executeInternal): Removed diskWriter related processing, which was
  5380. moved to FtpNegotiationCommand.cc.
  5381. * src/DirectDiskAdaptor.cc
  5382. (getFilePath): Made non-const.
  5383. * src/CopyDiskAdaptor.h
  5384. (DiskAdaptor.h): Removed include.
  5385. (DiskWriter.h): Removed include.
  5386. (AbstractSingleDiskAdaptor.h): New include.
  5387. (getFilePath): Made non-const. Added virtual keyword.
  5388. (CopyDiskAdaptor): Removed diskWriter.
  5389. (getTempFile): Returns const reference.
  5390. (CopyDiskAdaptorHandle): New type definition.
  5391. * src/ByteArrayDiskWriter.cc
  5392. (clear): Simplified.
  5393. (initAndOpenFile): Rewritten.
  5394. (openFile): Call initAndOpenFile()
  5395. * src/MultiDiskAdaptor.cc: Rewritten.
  5396. * src/DownloadEngineFactory.cc
  5397. (FileAllocator.h): New include.
  5398. (FileAllocationMonitor.h): New include.
  5399. (newConsoleEngine): Call DefaultDiskWriter::createNewDiskWriter() to
  5400. create DefaultDiskWriter with file allocator.
  5401. * src/DiskWriter.h
  5402. (initAndOpenFile): Added totalLength argument.
  5403. (openFile): Added totalLength argument.
  5404. * src/prefs.h
  5405. (PREF_FILE_ALLOCATION): New definition.
  5406. (V_PREALLOC): New definition.
  5407. (V_NONE): New definition.
  5408. * src/HttpResponseCommand.cc
  5409. (handleDefaultEncoding): Call DefaultDiskWriter::initAndOpenFile with
  5410. size.
  5411. * src/FtpNegotiateCommand.cc
  5412. (Util.h): New include.
  5413. (recvSize): Open file here.
  5414. * src/Util.h
  5415. (ullitos): New function.
  5416. * src/CopyDiskWriter.h
  5417. (getFilePath): Made non-const.
  5418. * src/DefaultDiskWriter.h
  5419. (Option.h): New include.
  5420. (totalLength): Removed.
  5421. (DefaultDiskWriter): Removed totalLength.
  5422. (initAndOpenFile): Added totalLength argument.
  5423. (DefaultDiskWriterHandle): New type definition.
  5424. (createNewDiskWriter): New function.
  5425. * src/Util.cc
  5426. (ullitos): New function.
  5427. * src/DefaultDiskWriter.cc
  5428. (message.h): New include.
  5429. (FileAllocator.h): New include.
  5430. (prefs.h): New include.
  5431. (Util.h): New include.
  5432. (DefaultDiskWriter): Removed totalLength.
  5433. (initAndOpenFile): Added file allocation.
  5434. (createNewDiskWriter): New function. Just for temporary solution.
  5435. It will be rewritten later.
  5436. * src/DiskAdaptor.cc
  5437. (DiskAdaptor): Removed diskWriter.
  5438. * src/AbstractDiskWriter.cc
  5439. (LogFactory.h): New include.
  5440. (AbstractDiskWriter): Added fileAllocator, logger.
  5441. (openFile): Added totalLength argument.
  5442. * src/AbstractDiskWriter.h
  5443. (FileAllocator.h): New include.
  5444. (Logger.h): New include.
  5445. (fileAllocator): New variable.
  5446. (logger): New variable.
  5447. (openFile): Added totalLength argument. Added virtual keyword
  5448. explicitly.
  5449. (openExistingFile): Added totalLength argument. Added virtual keyword
  5450. explicitly.
  5451. (closeFile): Added virtual keyword explicitly.
  5452. (sha1Sum): Added virtual keyword explicitly.
  5453. (writeData): Added virtual keyword explicitly.
  5454. (readData): Added virtual keyword explicitly.
  5455. (setFileAllocator): New function.
  5456. * src/DefaultPieceStorage.h
  5457. (FileAllocator.h): New include.
  5458. (diskAdaptor): DiskAdaptor -> DiskAdaptorHandle
  5459. (getDiskAdaptor): DiskAdaptor -> DiskAdaptorHandle
  5460. * src/FileProgressMonitor.h: New class.
  5461. To compile aria2 on PC-BSD:
  5462. * src/DefaultBtContext.cc
  5463. (libgen.h): New include.
  5464. To fix memory leak:
  5465. * src/Exception.h
  5466. (~Exception): Delete cause. Fixed memory leak.
  5467. 2006-12-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  5468. Rewritten a portion of bittorrent implementation:
  5469. * src/BtMessageValidator.h: New class.
  5470. * src/BtBitfieldMessageValidator.h: New class.
  5471. * src/BtHandshakeMessageValidator.h: New class.
  5472. * src/BtRequestMessageValidator.h: New class.
  5473. * src/BtSuggestPieceMessageValidator.h: New class.
  5474. * src/BtAllowedFastMessageValidator.h: New class.
  5475. * src/BtRejectMessageValidator.h: New class.
  5476. * src/BtCancelMessageValidator.h: New class.
  5477. * src/BtPieceMessageValidator.h: New class.
  5478. * src/BtHaveMessageValidator.h: New class.
  5479. * src/BtEventListener.h: New class.
  5480. * src/AbstractBtEventListener.h: New class.
  5481. * src/BtEvent.h: New class.
  5482. * src/BtChokingEvent.h: New class.
  5483. * src/BtChokedEvent.h: New class.
  5484. * src/BtCancelSendingPieceEvent.h: New class.
  5485. * src/BtAbortOutstandingRequestEvent.h: New class.
  5486. * src/Randomizer.h: New class.
  5487. * src/SimpleRandomizer.h: New class.
  5488. * src/BtMessage.h: New class.
  5489. * src/AbstractBtMessage.h: New class.
  5490. * src/SimpleBtMessage.h: New class.
  5491. * src/BtHaveMessage.h: New class.
  5492. * src/BtInterestedMessage.h: New class.
  5493. * src/BtAllowedFastMessage.h: New class.
  5494. * src/BtUnchokeMessage.h: New class.
  5495. * src/BtCancelMessage.h: New class.
  5496. * src/BtNotInterestedMessage.h: New class.
  5497. * src/BtChokeMessage.h: New class.
  5498. * src/BtHaveNoneMessage.h: New class.
  5499. * src/BtHandshakeMessage.h: New class.
  5500. * src/BtSuggestPieceMessage.h: New class.
  5501. * src/BtHaveMessage.h: New class.
  5502. * src/BtPieceMessage.h: New class.
  5503. * src/BtHaveAllMessage.h: New class.
  5504. * src/BtKeepAliveMessage.h: New class.
  5505. * src/BtPortMessage.h: New class.
  5506. * src/BtRejectMessage.h: New class.
  5507. * src/BtBitfieldMessage.h: New class.
  5508. * src/BtRequestMessage.h: New class.
  5509. * src/DefaultBtRequestFactory.h: New class.
  5510. * src/DefaultBtMessageReceiver.h: New class.
  5511. * src/BtInteractive.h: New class.
  5512. * src/BtMessageDispatcher.h: New class.
  5513. * src/DefaultBtMessageDispatcher.h: New class.
  5514. * src/DefaultBtInteractive.h: New class.
  5515. * src/BitfieldManFactory.h: New class.
  5516. * src/HandleRegistry.h: New class.
  5517. * src/BtMessageFactory.h: New class.
  5518. * src/BtMessageReceiver.h: New class.
  5519. * src/DefaultBtMessageFactory.h: New class.
  5520. * src/PeerObject.h: New class.
  5521. * src/BtRequestFactory.h: New class.
  5522. * src/SuggestPieceMessage.h: Removed.
  5523. * src/PortMessage.h: Removed.
  5524. * src/SuggestPieceMessage.h: Removed.
  5525. * src/KeepAliveMessage.h: Removed.
  5526. * src/HandshakeMessage.h: Removed.
  5527. * src/PeerInteraction.h: Removed.
  5528. * src/UnchokeMessage.h: Removed.
  5529. * src/PieceMessage.h: Removed.
  5530. * src/RequestMessage.h: Removed.
  5531. * src/InterestedMessage.h: Removed.
  5532. * src/HaveMessage.h: Removed.
  5533. * src/CancelMessage.h: Removed.
  5534. * src/RejectMessage.h: Removed.
  5535. * src/AllowedFastMessage.h: Removed.
  5536. * src/HaveNoneMessage.h: Removed.
  5537. * src/SimplePeerMessage.h: Removed.
  5538. * src/HaveAllMessage.h: Removed.
  5539. * src/BitfieldMessage.h: Removed.
  5540. * src/PeerMessageFactory.h: Removed.
  5541. * src/NotInterestedMessage.h: Removed.
  5542. * src/ChokeMessage.h: Removed.
  5543. * src/PeerMessage.h: Removed.
  5544. 2006-12-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  5545. To know root cause of exception:
  5546. * src/Exception.h
  5547. (cause): New variable.
  5548. (Exception): Added a parameter.
  5549. (getMsg): Return const reference to msg.
  5550. (getCause): New function.
  5551. * src/DlRetryEx.h
  5552. (DlRetryEx): Added a parameter 'cause'.
  5553. Added an overloaded constructor.
  5554. (DlAbortEx): Added a parameter 'cause'.
  5555. Added an overloaded constructor.
  5556. * src/SimpleLogger.cc
  5557. (writeLog): Log nested exception messages recursively.
  5558. 2006-11-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  5559. * src/DefaultBtProgressInfoFile.cc
  5560. (load): Fixed memory leak when the infohash doesn't match.
  5561. 2006-11-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  5562. * src/DefaultPeerStorage.cc
  5563. (calculateStat): Simplified the code by combining 2 loops into 1.
  5564. 2006-11-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  5565. Introduce new preference PREF_BT_TIMEOUT. This is the timeout value
  5566. for BitTorrent download:
  5567. * src/PeerAbstractCommand.cc
  5568. (PeerAbstractCommand): PREF_TIMEOUT -> PREF_BT_TIMEOUT
  5569. * src/main.cc:
  5570. (timeoutSpecified): Removed.
  5571. (main): Set the initial value of PREF_BT_TIMEOUT to 180.
  5572. Removed timeoutSpecified. TODO: Add --bt-timeout command line option.
  5573. * src/TorrentRequestInfo.cc
  5574. (timeoutSpecified): Removed.
  5575. (torrentHandler): Removed timeoutSpecified and the adjustment of
  5576. timeout value.
  5577. * src/prefs.h
  5578. (PREF_BT_TIMEOUT): New definition.
  5579. Delete unused variables:
  5580. * src/TorrentRequestInfo.cc
  5581. (requestInfo): Removed.
  5582. Move setSignalHander to Util::setGlobalSignalHandler:
  5583. * src/TorrentRequestInfo.cc:
  5584. setSignalHander -> Util::setGlobalSignalHandler
  5585. * src/main.cc
  5586. (setSignalHander): Removed.
  5587. (main): setSignalHander -> Util::setGlobalSignalHandler
  5588. * src/Util.h
  5589. (setGlobalSignalHandler): New function.
  5590. * src/Util.cc
  5591. (setGlobalSignalHandler): New function.
  5592. * src/UrlRequestInfo.cc:
  5593. setSignalHander -> Util::setGlobalSignalHandler
  5594. Reset peer status in order to exit gracefully:
  5595. * src/PeerAbstractCommand.cc
  5596. (execute): Call peer->resetStatus() when btRuntime->isHalt() is true.
  5597. To fix the bug that causes the number of bytes uploaded is not saved
  5598. to .aria2 file:
  5599. * src/DefaultPeerStorage.h
  5600. (removedPeerSessionDownloadLength): New variable.
  5601. (removedPeerSessionUploadLength): New variable.
  5602. * src/DefaultPeerStorage.cc
  5603. (DefaultPieceStorage): Added removedPeerSessionDownloadLength(0),
  5604. removedPeerSessionUploadLength(0).
  5605. (calculateStat): Calculate the number of bytes downloaded(uploaded)
  5606. through all peers, and then add removedPeerSessionDownloadLength(
  5607. removedPeerSessionUploadLength) to it.
  5608. (deleteUnusedPeer): Add the number of bytes downloaded(uploaded) from
  5609. (to) the peer to removedPeerSessionDownloadLength
  5610. (removedPeerSessionUploadLength).
  5611. 2006-11-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  5612. To add Metalink location option:
  5613. * src/MetalinkRequestInfo.cc
  5614. (execute): Call MetalinkEntry::setLocationPreference()
  5615. * src/main.cc
  5616. (showUsage): Added the help message for --metalink-location option.
  5617. (main): Added --metalink-location option.
  5618. * src/prefs.h
  5619. (PREF_METALINK_LOCATION): New definition.
  5620. * src/MetalinkEntry.cc
  5621. (AddLocationPreference): New function object.
  5622. (setLocationPreference): New function.
  5623. * src/Xml2MetalinkProcessor.cc
  5624. (getResource): Set location attribute to MetalinkResource
  5625. To show URLs to download
  5626. * src/UrlRequestInfo.h
  5627. (printUrls): New function.
  5628. To add multiple <file> Metalink support:
  5629. * src/MetalinkEntry.h
  5630. (MetalinkResources): Removed.
  5631. (setLocationPreference): New function.
  5632. (MetalinkEntryHandle): New type definition.
  5633. (MetalinkEntries): New type definition.
  5634. * src/Xml2MetalinkProcessor.h
  5635. (getEntry): MetalinkEntry* -> MetalinkEntryHandle
  5636. (getResource): MetalinkResource* -> MetalinkResourceHandle
  5637. (parseFile): Metalinker* -> MetalinkerHandle
  5638. * src/UrlRequestInfo.h
  5639. (execute): RequestInfo* -> RequestInfos
  5640. * src/MetalinkRequestInfo.cc
  5641. (AccumulateNonP2PUrl): MetalinkResource* -> MetalinkResourceHandle
  5642. (FindBitTorrentUrl): MetalinkResource* -> MetalinkResourceHandle
  5643. (execute): RequestInfo* -> RequestInfos
  5644. Added multiple <file> support. Print filename when it is queued.
  5645. * src/MetalinkRequestInfo.h
  5646. (execute): RequestInfo* -> RequestInfos
  5647. (getDownloadEngine): Removed.
  5648. * src/RequestInfo.h
  5649. (RequestInfoHandle): New type definition.
  5650. (RequestInfos): New type definition.
  5651. (execute): RequestInfo* -> RequestInfos
  5652. (getDownloadEngine): Removed.
  5653. * src/MetalinkResource.h
  5654. (MetalinkResourceHandle): New type definition.
  5655. (MetalinkResources): New type definition.
  5656. * src/MetalinkEntry.cc
  5657. (~MetalinkEntry): Removed the deletion of the elements of resources,
  5658. because the element is now of type MetalinkResourceHandle.
  5659. (PrefOrder): MetalinkResource* -> MetalinkResourceHandle
  5660. (Supported): MetalinkResource* -> MetalinkResourceHandle
  5661. (dropUnsupportedResource): Removed the deletion of the elements of
  5662. resources because the element is now of type MetalinkResourceHandle.
  5663. * src/Xml2MetalinkProcessor.cc
  5664. (parseFile): Metalinker* -> MetalinkerHandle
  5665. MetalinkEntry* -> MetalinkEntryHandle
  5666. Removed try-catch block.
  5667. (getEntry): MetalinkEntry* -> MetalinkEntryHandle
  5668. MetalinkResource* -> MetalinkResourceHandle
  5669. Removed try-catch block.
  5670. (getResource): MetalinkResource* -> MetalinkResourceHandle
  5671. Free result by using xmlXPathFreeObject()
  5672. * src/Metalinker.cc
  5673. (~Metalinker): Removed the deletion of entries.
  5674. MetalinkEntry* -> MetalinkEntryHandle
  5675. (queryEntry): Add multiple <file> Metalink support.
  5676. * src/Metalinker.h
  5677. (MetalinkEntries): Removed.
  5678. (queryEntry): MetalinkEntry* -> MetalinkEntries
  5679. * src/MetalinkProcessor.h
  5680. (parseFile): Metalinker* -> MetalinkerHandle
  5681. Bug fixes:
  5682. * src/PeerChokeCommand.cc
  5683. (execute): cat01->cat02
  5684. * src/DefaultPieceStorage.cc
  5685. (DefaultPieceStorage): Added diskAdaptor(0)
  5686. * src/TrackerWatcherComand.cc:
  5687. (execute): Use btAnnounce->noMoreAnnounce()
  5688. to determin whether the function returns true or not.
  5689. * src/TrackerUpdateCommand.cc:
  5690. (execute): Use btAnnounce->noMoreAnnounce()
  5691. to determin whether the function returns true or not.
  5692. * src/FtpConnection.cc
  5693. (bulkReceiveResponse): Throw DlRetryEx if EOF got.
  5694. This is the fix of the busy loop bug.
  5695. * src/DownloadCommand.cc
  5696. (DownloadCommand): Reuse PeerStat. segmentMan->getPeerStat() returns
  5697. cached PeerStat.
  5698. The value of "name" entry in torrent file is now set by
  5699. *DiskAdaptor::setTopDir(...) methods.
  5700. * src/MultiDiskAdaptor.h
  5701. (topDir): New variable.
  5702. (setTopDir): New function.
  5703. (getTopDir): New function.
  5704. * src/MultiDiskAdaptor.cc
  5705. (getFilePath): Concat storDir, "/" and topDir.
  5706. (mkdir): Use getFilePath() to get the directory path for output.
  5707. * src/DefaultPieceStorage.cc
  5708. (initStorage): Set the value of "name" entry to MultiDiskAdaptor,
  5709. CopyDiskAdaptor.
  5710. * src/CopyDiskAdaptor.h
  5711. (topDir): New variable.
  5712. (setTopDir): New function.
  5713. (getTopDir): New function.
  5714. * src/CopyDiskAdaptor.cc
  5715. (fixFilename): Updated.
  5716. Misc
  5717. * src/UrlRequestInfo.h
  5718. (e): Removed.
  5719. (UrlRequestInfo): Removed e.
  5720. (getDownloadEngine): Removed.
  5721. * src/UrlRequestInfo.cc
  5722. (handler): Rewritten.
  5723. (printUrls): New function.
  5724. (execute): Call printUrls().
  5725. * src/HandshakeMessage.cc
  5726. (check): peerinteraction->getBtContext() -> btContext
  5727. * src/PeerInteraction.h
  5728. (getBtContext): Removed.
  5729. * src/TorrentRequestInfo.h
  5730. (execute): RequestInfo* -> RequestInfos
  5731. (getDownloadEngine): Removed.
  5732. * src/TorrentRequestInfo.cc
  5733. (haltRequested): Removed.
  5734. (btHaltRequested): New variable.
  5735. (torrentHandler): haltRequested -> btHaltRequested
  5736. (execute): RequestInfo* -> RequestInfos
  5737. * src/TorrentConsoleDownloadEngine.cc
  5738. (afterEachIteration): haltRequested -> btHaltRequested.
  5739. * src/ConsoleDownloadEngine.h
  5740. (initStatistics): Added virtual.
  5741. (calculateStatistics): Added virtual.
  5742. (onEndOfRun): Added virtual.
  5743. (afterEachIteration): Added virtual.
  5744. * src/ConsoleDownloadEngine.cc
  5745. (haltRequested): New variable.
  5746. (afterEachIteration): New function.
  5747. * src/main.cc
  5748. (requestInfo): Removed.
  5749. * src/SegmentMan.cc
  5750. (findSlowerSegmentEntry): Refactored.
  5751. * Release 0.9.0
  5752. 2006-11-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  5753. To divide TorrentMan into 6 classes: BtContext, BtRuntime,
  5754. PeerStorage, PieceStorage, BtAnnounce and BtProgressInfoFile
  5755. * src/TorrentMan.h: Removed.
  5756. * src/TorrentMan.cc: Removed.
  5757. * src/TrackerWatcherComand.h: Made subclass of BtContextAwareCommand.
  5758. * src/SeedCheckCommand.cc: Use pieceStorage, btRuntime
  5759. * src/PeerAbstractCommand.h: Made subclass of BtContextAwareCommand.
  5760. * src/PeerAbstractCommand.cc: Use btRuntime.
  5761. * src/BtContextAwareCommand.h: New class.
  5762. * src/FileEntry.h: Added accessor methods for following variables.
  5763. (path): Made private.
  5764. (length): Made private.
  5765. (offset): Made private.
  5766. (extracted): Made private.
  5767. (requested): Made private.
  5768. (FileEntries): New definition.
  5769. (FileEntryHandle): New definition.
  5770. * src/FileEntry.cc: New file.
  5771. * src/HaveEraseCommand.h: Made subclass of BtContextAwareCommand.
  5772. * src/HaveEraseCommand.cc: Use btRuntime, pieceStorage.
  5773. * src/PeerChokeCommand.h: Made subclass of BtContextAwareCommand.
  5774. * src/PeerChokeCommand.cc: Use btRuntime, peerStorage, pieceStorage.
  5775. * src/PieceStorage.h: New file.
  5776. * src/PeerInteractionCommand.h: Use btContext.
  5777. * src/PeerInteractionCommand.cc: Use pieceStorage, peerStorage,
  5778. btRuntime.
  5779. * src/DefaultBtProgressInfoFile.h: New file.
  5780. * src/DefaultBtProgressInfoFile.cc: New file.
  5781. * src/File.cc
  5782. (Util.h): New include.
  5783. (mkdirs): New function.
  5784. * src/MultiDiskAdaptor.h
  5785. (mkdir): New function.
  5786. * src/PeerListProcessor.h
  5787. (Peers): Removed.
  5788. * src/PeerInteraction.h
  5789. (torrentMan): Removed.
  5790. (btContext): New variable.
  5791. (peerStorage): New variable.
  5792. (pieceStorage): New variable.
  5793. (btAnnounce): New variable.
  5794. (getTorrentMan): Removed.
  5795. (getBtContext): New function.
  5796. * src/PeerInteraction.cc: Use btContext, peerStorage, pieceStorage,
  5797. btAnnounce.
  5798. * src/HandshakeMessage.h
  5799. (TorrentMan.h): Removed.
  5800. * src/HandshakeMessage.cc: Use btContext.
  5801. * src/DefaultBtAnnounce.cc: New file.
  5802. * src/MultiDiskWriter.cc: Use the accessor methods of FileEntry.
  5803. * src/DefaultPieceStorage.cc: New file.
  5804. * src/DefaultBtContext.h: New file.
  5805. * src/TorrentRequestInfo.cc: Use btContext, pieceStorage.
  5806. Use the accessor methods of FileEntry.
  5807. * src/CookieBox.cc: Updated to use Util::slice().
  5808. * src/PieceMessage.cc: Use btContext, pieceStorage.
  5809. * src/common.h (SharedHandle.h): New include.
  5810. * src/PeerMessage.cc (PeerMessage): Added btContext, peerStorage,
  5811. pieceStorage.
  5812. * src/TorrentAutoSaveCommand.h: Made subclass of BtContextAwareCommand.
  5813. * src/DiskAdaptor.h
  5814. (topDir): Removed.
  5815. (getFileEntryFromPath): Changed the return type to FileEntryHandle.
  5816. (setTopDir): Removed.
  5817. (getTopDir): Removed.
  5818. * src/BtContext.h: New file.
  5819. * src/DefaultPeerStorage.h: New file.
  5820. * src/PieceMessage.h (TorrentMan.h): Removed.
  5821. * src/RequestMessage.h (TorrentMan.h): Removed.
  5822. * src/TorrentDownloadEngine.h
  5823. (uploadLength): New variable.
  5824. (btContext): New variable.
  5825. (btRuntime): New variable.
  5826. (pieceStorage): New variable.
  5827. (peerStorage): New variable.
  5828. (btAnnounce): New variable.
  5829. (btProgressInfoFile): New variable.
  5830. (torrentMan): Removed.
  5831. (setBtContext): New function.
  5832. * src/TorrentDownloadEngine.cc: Use BtContext, BtRuntime, pieceStorage,
  5833. peerStorage, btAnnounce, btProgressInfoFile.
  5834. * src/Piece.h
  5835. (toString): New function.
  5836. (Pieces): New type definition.
  5837. * src/Peer.h
  5838. (active): New variable.
  5839. (Peer): Added active.
  5840. (activate): Set active to true.
  5841. (deactivate): Set active to false.
  5842. (isActive): New function.
  5843. (Peers): New type definition.
  5844. * src/DirectDiskAdaptor.cc
  5845. (getFilePath): Use the accessor methods of FileEntry.
  5846. * src/TorrentConsoleDownloadEngine.h
  5847. (afterEachIteration): New function.
  5848. * src/TorrentConsoleDownloadEngine.cc
  5849. (haltRequested): New variable.
  5850. (sendStatistics): Use pieceStorage, btRuntime.
  5851. (afterEachIteration): New function.
  5852. * src/AnnounceList: AnnounceTier->AnnounceTierHandle.
  5853. * src/Directry.h
  5854. (Directory): New function.
  5855. (DirectoryHandle): New type definition.
  5856. * src/BtProgressInfoFile.h: New file.
  5857. * src/RequestMessage.cc: Use pieceStorage.
  5858. * src/BtRuntime.h: New file.
  5859. * src/DefaultBtContext.cc: New file.
  5860. * src/BitfieldMan.h
  5861. (getCompletedLength): New function(private).
  5862. (getCompletedLength): New function.
  5863. (getFilteredCompletedLength): New function.
  5864. * src/BitfieldMan.h
  5865. (getCompletedLength): New function(private).
  5866. (getCompletedLength): New function.
  5867. (getFilteredCompletedLength): New function.
  5868. * src/MultiDiskAdaptor.cc
  5869. (mkdir): New function.
  5870. (openFile): Call mkdir().
  5871. (initAndOpenFile): Call mkdir().
  5872. * src/CancelMessage.h
  5873. (TorrentMan.h): Removed.
  5874. * src/RejectMessage.h
  5875. (TorrentMan.h): Removed.
  5876. * src/DownloadEngineFactory.cc
  5877. (DefaultPieceStorage.h): New include.
  5878. (DefaultPeerStorage.h): New include.
  5879. (DefaultBtAnnounce.h): New include.
  5880. (DefaultBtProgressInfoFile.h): New include.
  5881. (newTorrentConsoleEngine): Rewritten.
  5882. * src/ShareRatioSeedCriteria.h
  5883. (torrentMan): Removed.
  5884. (btContext): New variable.
  5885. (peerStorage): New variable.
  5886. (btRuntime): New variable.
  5887. (evaluate): Use btContext, btRuntime, peerStorage.
  5888. * src/AnnounceTier.h: New file.
  5889. * src/BtAnnounce.h: New file.
  5890. * src/BtRegistry.h: New file.
  5891. * src/PeerInitiateConnectionCommand.h: Added btContext.
  5892. * src/PeerConnection.h (TorrentMan.h): Removed.
  5893. * src/PeerMessageFactory.cc: Use btContext, pieceStorage.
  5894. * src/Util.h
  5895. (slice): Added an argument.
  5896. * src/Util.cc
  5897. (slice): Added an argument to control whether trim is made or not.
  5898. * src/PeerStorage.h: New file.
  5899. * src/BtRegistry.cc: New file.
  5900. * src/TrackerUpdateCommand.h: Made subclass of BtContextAwareCommand.
  5901. * src/CopyDiskAdaptor.cc: Use the accessor methods of FileEntry.
  5902. * src/MultiDiskWriter.h: FileEntry -> FileEntryHandle
  5903. * src/PeerListenCommand.cc: Use btRuntime, peerStorage, btContext.
  5904. * src/TorrentRequestInfo.h
  5905. (e): Removed.
  5906. (showFileEntry): Added an argument.
  5907. (getDownloadEngine): Return 0.
  5908. * src/DefaultBtAnnounce.h: New file.
  5909. * src/TorrentAutoSaveCommand.cc: Use btRuntime, btProgressInfoFile.
  5910. * src/TrackerWatcherComand.cc: Use btRuntime, btAnnounce,
  5911. * src/PeerMessageFactory.h
  5912. (btContext): New variable.
  5913. (pieceStorage): New variable.
  5914. * src/TrackerUpdateCommand.cc: Use btRuntime, peerStorage, btContext,
  5915. btAnnounce.
  5916. * src/DiskAdaptor.cc
  5917. (DiskAdaptor): Removed topDir.
  5918. (~DiskAdaptor): Removed topDir.
  5919. * src/PeerListenCommand.h: Made subclass of BtContextAwareCommand.
  5920. * src/SeedCheckCommand.h: Made subclass of BtContextAwareCommand.
  5921. * src/File.h (mkdirs): New function.
  5922. * src/DefaultPeerStorage): New file.
  5923. * src/DownloadEngineFactory.h
  5924. (newTorrentConsoleEngine): Use btContext.
  5925. * src/BtContextAwareCommand.cc: New file.
  5926. * src/PeerInitiateConnectionCommand.cc: Use btRuntime, peerStorage.
  5927. * src/PeerMessage.h
  5928. (btContext): New variable.
  5929. (peerStorage): New variable.
  5930. (pieceStorage): New variable.
  5931. (setBtContext): New function.
  5932. * src/Directry.cc
  5933. (Directory): New function.
  5934. (createDir): Do nothing if name.size() == 0.
  5935. * src/AnnounceList.h
  5936. (AnnounceTier): Removed.
  5937. (AnnounceTiers): Removed.
  5938. * src/DefaultPieceStorage.h: New file.
  5939. * src/Piece.cc (toString): New function.
  5940. To fix typo:
  5941. * src/main.cc (showVersion): Fixed typo.
  5942. To fix compile warning:
  5943. * src/DelegatingPeerListProcessor.cc
  5944. (canHandle): Added "return false".
  5945. 2006-10-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  5946. To simplify TrackerWatherCommand, TrackerUpdateCommand and
  5947. make the process of announce request testable.
  5948. * src/TrackerWatcherCommand.h
  5949. (TimeA2.h): Removed.
  5950. (interval): Removed.
  5951. (checkPoint): Removed.
  5952. (createRequestCommand): Added an argument 'url'.
  5953. (TrackerWatherCommand): Removed interval.
  5954. (createCommand): New function.
  5955. * src/DownloadEngineFactory.cc
  5956. (newTorrentConsoleEngine): Updated according to the changes in
  5957. TrackerWatherCommand.
  5958. * src/TorrentMan.cc
  5959. (DelegatingPeerListProcessor.h): New includes.
  5960. (TorrentMan): Added the initialization of announceInterval.
  5961. (isStoppedAnnounceReady): New function.
  5962. (isCompletedAnnounceReady): New function.
  5963. (isDefaultAnnounceReady): New function.
  5964. (isAnnounceReady): New function.
  5965. (getAnnounceUrl): New function.
  5966. (announceStart): New function.
  5967. (announceFailure): New function.
  5968. (announceSuccess): New function.
  5969. (isAllAnnounceFailed): New function.
  5970. (resetAnnounce): New function.
  5971. (processAnnounceResponse): New function.
  5972. (needMorePeerConnection): New function.
  5973. (noMoreAnnounce): New function.
  5974. * src/TrackerUpdateCommand.h
  5975. (getTrackerResponse): int->size_t
  5976. * src/TorrentMan.h
  5977. (isStoppedAnnounceReady): New function.
  5978. (isCompletedAnnounceReady): New function.
  5979. (isDefaultAnnounceReady): New function.
  5980. (announceInterval): New variable.
  5981. (isAnnounceReady): New function.
  5982. (getAnnounceUrl): New function.
  5983. (announceStart): New function.
  5984. (announceFailure): New function.
  5985. (announceSuccess): New function.
  5986. (isAllAnnounceFailed): New function.
  5987. (resetAnnounce): New function.
  5988. (processAnnounceResponse): New function.
  5989. (needMorePeerConnection): New function.
  5990. (noMoreAnnounce): New function.
  5991. * src/TrackerWatcherCommand.cc
  5992. (TrackerWatherCommand): Removed interval and checkPoint.
  5993. (execute): Rewritten.
  5994. (createCommand): New function.
  5995. (createRequestCommand): Rewritten.
  5996. * src/TrackerUpdateCommand.cc
  5997. (MetaFileUtil.h): Removed.
  5998. (DelegatingPeerListProcessor.h): Removed.
  5999. (getTrackerResponse): int->size_t. Use torrentMan's new functions.
  6000. 2006-10-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6001. Request -> RequestHandle:
  6002. * src/HttpResponseCommand.h: Request->RequestHandle
  6003. * src/AbstractCommand.cc: Request->RequestHandle
  6004. * src/HttpDownloadCommand.cc: Request->RequestHandle
  6005. * src/HttpRequestCommand.cc: Request->RequestHandle
  6006. * src/FtpInitiateConnectionCommand.h: Request->RequestHandle
  6007. * src/AbstractCommand.h: Request->RequestHandle
  6008. * src/HttpProxyRequestCommand.h: Request->RequestHandle
  6009. * src/HttpResponseCommand.cc: Request->RequestHandle
  6010. * src/HttpInitiateConnectionCommand.h: Request->RequestHandle
  6011. * src/FtpNegotiateCommand.cc: Request->RequestHandle
  6012. * src/FtpTunnelResponseCommand.h: Request->RequestHandle
  6013. * src/HttpConnection.h: Request->RequestHandle
  6014. * src/HttpProxyResponseCommand.cc: Request->RequestHandle
  6015. * src/InitiateConnectionCommandFactory.h: Request->RequestHandle
  6016. * src/FtpTunnelResponseCommand.cc: Request->RequestHandle
  6017. * src/DownloadCommand.h: Request->RequestHandle
  6018. * src/FtpDowndloadCommand.cc: Request->RequestHandle
  6019. * src/HttpInitiateConnectionCommand.cc: Request->RequestHandle
  6020. * src/HttpRequestCommand.h: Request->RequestHandle
  6021. * src/FtpNegotiateCommand.h: Request->RequestHandle
  6022. * src/FtpTunnelResponseCommand.cc: Request->RequestHandle
  6023. * src/FtpInitiateConnectionCommand.cc: Request->RequestHandle
  6024. * src/HttpDownloadCommand.h: Request->RequestHandle
  6025. * src/FtpConnection.cc: Request->RequestHandle
  6026. * src/InitiateConnectionCommandFactory.cc: Request->RequestHandle
  6027. * src/UrlRequestInfo.cc: Request->RequestHandle
  6028. * src/HttpProxyResponseCommand.h: Request->RequestHandle
  6029. * src/HttpConnection.h: Request->RequestHandle
  6030. * src/DownloadCommand.cc: Request->RequestHandle
  6031. * src/FtpConnection.h: Request->RequestHandle
  6032. * src/FtpDowndloadCommand.h: Request->RequestHandle
  6033. * src/HttpProxyRequestCommand.cc: Request->RequestHandle
  6034. * src/FtpTunnelRequestCommand.h: Request->RequestHandle
  6035. * src/Request.h
  6036. (SharedHandle.h): New include.
  6037. (RequestHandle): New type definition.
  6038. (Requests): Redefined.
  6039. To add MULTITRACKER support:
  6040. * src/TrackerWatcherCommand.h
  6041. (createRequestCommand): New function.
  6042. * src/DownloadEngineFactory.cc
  6043. (newTorrentConsoleEngine): Removed req.
  6044. * src/prefs.h
  6045. (PREF_TRACKER_MAX_TRIES): New definition.
  6046. * src/TorrentMan.cc
  6047. (TorrentMan): Removed req. Added trackerNumTry.
  6048. (~TorrentMan): Removed req.
  6049. (setupInternal1): Added announceList.
  6050. * src/TorrentRequestInfo.cc
  6051. (execute): Set PREF_MAX_TIRES to 1. The max number of tries for
  6052. announces is now specified by PREF_TRACKER_MAX_TRIES.
  6053. * src/main.cc
  6054. (main): Added PREF_TRACKER_MAX_TRIES.
  6055. * src/TorrentMan.h
  6056. (Request.h): Removed.
  6057. (AnnounceList.h): New include.
  6058. (trackerNumTry): New variable.
  6059. (req): Removed.
  6060. (announceList): New variable.
  6061. * src/TrackerWatcherCommand.cc
  6062. (execute): Rewritten.
  6063. (createRequestCommand): New function.
  6064. * src/TrackerUpdateCommand.cc
  6065. (execute): Updated with the use of AnnounceList.
  6066. * src/AnnounceList.cc: New class.
  6067. * src/AnnounceList.h: New class.
  6068. To fix typo:
  6069. * src/prefs.h
  6070. (PREF_MAX_TRIES): max_try->max_tries
  6071. To not to decode "+" as space in URL decode:
  6072. * src/Util.cc
  6073. (urldecode): Removed "+"->space decoding rule. Test case was updated.
  6074. 2006-10-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6075. To add timeout to async name resolution:
  6076. * src/AbstractCommand.h
  6077. (nameResolveFinished): New function. This is not elegant way. It needs
  6078. to be more refined.
  6079. (nameResolverCheck): New variable.
  6080. * src/AbstractCommand.cc
  6081. (AbstractCommand): Added nameResolverCheck.
  6082. (execute): Added the check whether the name resolution has finished.
  6083. (setNameResolverCheck): Set nameResolverCheck to true.
  6084. (disableNameResolverCheck): Set nameResolverCheck to false.
  6085. (nameResolverFinished): New function.
  6086. * src/FtpInitiateConnectionCommand.h
  6087. (nameResolverFinished): New function.
  6088. * src/FtpInitiateConnectionCommand.cc
  6089. (FtpInitiateConnectionCommand): Set timeout to PREF_DNS_TIMEOUT.
  6090. * src/HttpInitiateConnectionCommand.h
  6091. (nameResolverFinished): New function.
  6092. * src/HttpInitiateConnectionCommand.cc
  6093. (HttpInitiateConnectionCommand): Set timeout to PREF_DNS_TIMEOUT.
  6094. * src/prefs.h
  6095. (PREF_DNS_TIMEOUT): New definition.
  6096. * src/main.cc
  6097. (main): Added PREF_DNS_TIMEOUT.
  6098. To add the support for a non-compact response from a tracker:
  6099. * src/PeerListProcessor.h: New class.
  6100. * src/DefaultPeerListProcessor.h: New class.
  6101. * src/DefaultPeerListProcessor.cc: New class.
  6102. * src/CompactPeerListProcessor.h: New class.
  6103. * src/CompactPeerListProcessor.cc: New class.
  6104. * src/DelegatingPeerListProcessor.h: New class.
  6105. * src/DelegatingPeerListProcessor.cc: New class.
  6106. * src/TorrentMan.cc
  6107. (addPeer): New function(overload).
  6108. (addPeer): Delete unused peers only when new peer is added.
  6109. * src/TorrentMan.h
  6110. (PeerListProcessor.h): Included.
  6111. (Peers): Removed.
  6112. (addPeer): New function(overload).
  6113. * src/TrackerUpdateCommand.cc
  6114. (netinet/in.h): Removed.
  6115. (DelegatingPeerListProcessor.h): Included.
  6116. (execute): Updated to use DelegatingPeerListProcessor.
  6117. To fix the memory leak in TorrentMan::peers:
  6118. * src/PeerAbstractCommand.cc
  6119. (onAbort): Added peer->resetStatus().
  6120. * src/Peer.h
  6121. (resetStatus): Made public.
  6122. To improve the precision of the speed calculation:
  6123. * src/SpeedCalc.h
  6124. (nextInterval): New variable.
  6125. * src/SpeedCalc.cc
  6126. (reset): Added nextInterval.
  6127. (isIntervalOver): Use nextInterval instead of CHANGE_INTERVAL_SEC.
  6128. (changeSw): Set nextInterval to 15 seconds relative to the current
  6129. instant time.
  6130. * src/main.cc
  6131. (showVersion): Updated.
  6132. (showUsage): Updated.
  6133. * Release 0.8.1
  6134. 2006-09-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6135. * src/main.cc
  6136. (showUsage): Commented out --min-segment-size option.
  6137. (main): Commented out --min-segment-size option.
  6138. * Release 0.8.0
  6139. 2006-09-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6140. * src/*.{h,cc}:
  6141. Added an exception to the license which allows linking with OpenSSL.
  6142. 2006-09-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6143. * src/AbstractCommand.cc
  6144. (execute): Check whether the download has finished before checking
  6145. socket status.
  6146. Return true if peerStat->getStatus() == REQUEST_IDLE.
  6147. Do not exit even if no segment is available.
  6148. * src/prefs.h
  6149. (PREF_STARTUP_IDLE_TIME): New definition.
  6150. * src/PeerInteractionCommand.cc
  6151. (executeInternal): Removed max speed limit. Because it performs bad.
  6152. (receiveMessages): Added max speed limit. This was better than above,
  6153. but still a little bit to be desired. Sometimes the download speed
  6154. became much faster than I specified.
  6155. * src/SpeedCalc.h
  6156. (start): New variable.
  6157. (accumulatedLength): New variable.
  6158. (getAvgSpeed): New function.
  6159. * src/SpeedCalc.cc
  6160. (reset): Added start, accumulatedLength.
  6161. (update): Added calculation of an average speed.
  6162. (getAvgSpeed): New function.
  6163. * src/DownloadCommand.h
  6164. (sw): Removed.
  6165. * src/main.cc
  6166. (main): Added PREF_STARTUP_IDLE_TIME.
  6167. * src/PeerStat.h
  6168. (STATUS): Added REQUEST_IDLE.
  6169. (getMaxSpeed): Renamed as getMaxDownloadSpeed().
  6170. (getAvgDownloadSpeed): New function
  6171. (requestIdle): New function.
  6172. * src/SegmentMan.h
  6173. (SegmentEntryHandle): New type definition.
  6174. (SegmentEntries): Now holds SegmentEntryHandle.
  6175. (findSlowerSegmentEntry): New funtion.
  6176. * src/SegmentMan.cc
  6177. (save): Updated according to the changes in SegmentEntries.
  6178. (read): Updated according to the changes in SegmentEntries.
  6179. (FindSegmentEntryByIndex): Updated according to the changes in
  6180. SegmentEntries.
  6181. (FindSegmentEntryByCuid): Updated according to the changes in
  6182. SegmentEntries.
  6183. (checkoutSegment): Updated according to the changes in SegmentEntries.
  6184. (onNullBitfield): Updated according to the changes in SegmentEntries.
  6185. Renamed uitr as itr.
  6186. (findSlowerSegmentEntry): New function.
  6187. (getSegment): Updated according to the changes in SegmentEntries.
  6188. Added the feature that cancels the segment with slow server and fast
  6189. one takes it over.
  6190. (cancelSegment): Updated according to the changes in SegmentEntries.
  6191. (getDownloadLength): Updated according to the changes in
  6192. SegmentEntries.
  6193. (init): Assigned 0 to bitfield after deleting it.
  6194. * src/DownloadCommand.cc
  6195. (STARTUP_IDLE_TIME): Removed.
  6196. (executeInternal): Use PREF_STARTUP_IDLE_TIME.
  6197. * src/PeerChokeCommand.cc
  6198. (optUnchokingPeer): Updated according to the changes in Peer.
  6199. (ResetDelta): Removed.
  6200. (UploadFaster): Updated according to the changes in Peer.
  6201. (DownloadFaster): Updated according to the changes in Peer.
  6202. (execute): I clarify the meaning of "upload" and "download" here.
  6203. "upload" means the transfer from localhost to remote host.
  6204. "download" means the transfer from remote host to localhost.
  6205. Based on this rule, I swapped orderByUploadRate and
  6206. orderByDownloadRate.
  6207. * src/PeerInteractionCommand.cc
  6208. (PeerInteraction): Removed peerInteraction->setUploadLImit().
  6209. (executeInternal): Removed the argument of
  6210. peerInteraction->sendMessages().
  6211. (receiveMessages): Rewritten download speed limit.
  6212. (sendKeepAlive): Removed peerInteraction->sendMessages().
  6213. * src/HttpResponseCommand.cc
  6214. (handleDefaultEncoding): If file size is unknown in torrent request,
  6215. do not call segmentMan->initBitfield() here.
  6216. Disabled persistent connection feature in torrent request.
  6217. * src/UrlRequestInfo.h
  6218. (UrlRequestInfo): Removed const qualifier from option.
  6219. * src/TorrentMan.h
  6220. (TransferStat): New class.
  6221. (deltaDownloadLength): Removed.
  6222. (deltaUploadLength): Removed.
  6223. (addDeltaDownloadLength): Removed.
  6224. (getDeltaDownloadLength): Removed.
  6225. (resetDeltaDownloadLength): Removed.
  6226. (addDeltaUploadLength): Removed.
  6227. (getDeltaUploadLength): Removed.
  6228. (resetDeltaUploadLength): Removed.
  6229. (addActivePeer): Added peer->activate().
  6230. (deleteActivePeer): Added peer->deactivate().
  6231. (calculateStat): New function.
  6232. * src/TorrentMan.cc
  6233. (TorrentMan): Removed deltaDownloadLength and deltaUploadLength.
  6234. (calculateStat): New function.
  6235. * src/PeerInteraction.h
  6236. (uploadLimit): Removed.
  6237. (option): New variable.
  6238. (setUploadLimit): Removed.
  6239. (getUploadSpeed): Removed.
  6240. (sendMessages): Removed the argument "currentUploadSpeed".
  6241. * src/PeerInteraction.cc
  6242. (prefs.h): Included.
  6243. (PeerInteraction): Removed uploadLimit. Added option.
  6244. (sendMessages): Rewritten upload speed limit.
  6245. (sendHandshake): Removed the argument from sendMessages().
  6246. (sendBitfield): Removed the argument from sendMessages().
  6247. * src/PeerAbstractCommand.cc
  6248. (execute): Commented out the portion of upload limit.
  6249. (onAbort): Removed peer->resetStatus().
  6250. * src/TorrentRequestInfo.cc
  6251. (timeoutSpecified): Declared extern.
  6252. (execute): Set timeout to 180 if timeout is not specified by.
  6253. command-line.
  6254. * src/PieceMessage.cc
  6255. (receivedAction): Added peer->updateDownloadLength().
  6256. Removed peer->addPeerUpload().
  6257. Removed torrentMan->addDeltaDownloadLength().
  6258. (send): Added peer->updateUploadLength().
  6259. Removed peer->addPeerDownload().
  6260. Removed torrentMan->addDeltaUploadLength().
  6261. * src/main.cc
  6262. (timeoutSpecified): New variable.
  6263. (main): Set timeoutSpecified to false.
  6264. If the command-line option "--upload-limit" is specified, then
  6265. timeoutSpecified is set to true. This option will remain in the next
  6266. release, but be deprecated in the future release.
  6267. * src/TorrentRequestInfo.h
  6268. (TorrentRequestInfo): Removed const qualifier from op.
  6269. * src/PeerStat.h
  6270. (uploadSpeed): New variable.
  6271. (PeerStat): Added default value to cuid.
  6272. (calculateUploadSpeed): New function.
  6273. (updateUploadLength): New function.
  6274. (getMaxUploadSpeed): New function.
  6275. (getAvgUploadSpeed): New function.
  6276. (reset): Added uploadSpeed. Set status to IDLE.
  6277. * src/TorrentDownloadEngine.h
  6278. (cp): Declared as Time.
  6279. (sessionDownloadLengthArray): Removed.
  6280. (sessionUploadLengthArray): Removed.
  6281. (currentCp): Removed.
  6282. (lastCalcStat): New variable
  6283. (lastElapsed): Removed.
  6284. (sessionDownloadLength): Removed.
  6285. (calculateStat): New function.
  6286. * src/TorrentDownloadEngine.cc
  6287. (initStatistics): Removed lastElapsed, cp[],
  6288. sessionDownloadLengthArray[], sessionUploadLengthArray[],
  6289. currentCp, sessionDownloadLength.
  6290. Added cp.reset() and lastCalcStat.reset().
  6291. (calculateSpeed): Changed the name of the argument.
  6292. (calculateStatistics): Rewritten.
  6293. (calculateStat): New function.
  6294. * src/Peer.h
  6295. (PeerStat.h): Included.
  6296. (peerUpload): Removed.
  6297. (peerDownload): Removed.
  6298. (peerStat): New variable.
  6299. (sessionUploadLength): New variable.
  6300. (sessionDownloadLength): New variable.
  6301. (deltaUpload): Removed.
  6302. (deltaDownload): Removed.
  6303. (resetStatus): Made private.
  6304. (Peer): Added sessionUploadLength, sessionDownloadLength.
  6305. Removed peerUpload, peerDownload.
  6306. (updateUploadLength): New function.
  6307. (addDeltaUpload): Removed.
  6308. (updateDownloadLength): New function.
  6309. (resetDeltaUpload): Removed.
  6310. (getDeltaUpload): Removed.
  6311. (addDeltaDownload): Removed.
  6312. (calculateUploadSpeed): New function.
  6313. (resetDeltaDownload): Removed.
  6314. (getDeltaDownload): Removed.
  6315. (calculateDownloadSpeed): New function.
  6316. (getSessionUploadLength): New function.
  6317. (getSessionDownloadLength): New function.
  6318. (activate): New function.
  6319. (deactivate): New function.
  6320. (addPeerUpload): Removed.
  6321. (setPeerUpload): Removed.
  6322. (getPeerUpload): Removed.
  6323. (addPeerDownload): Removed.
  6324. (setPeerDownload): Removed.
  6325. (getPeerDownload): Removed.
  6326. * src/Peer.cc
  6327. (resetStatus): Removed resetDeltaUpload() and resetDeltaDownload().
  6328. * src/MetalinkRequestInfo.h
  6329. (MetalinkRequestInfo): Removed const qualifier from op.
  6330. * src/RequestInfo.h
  6331. (op): Removed const qualifier.
  6332. (RequestInfo): Removed const qualifier from op.
  6333. * src/prefs.h
  6334. (PREF_MAX_SPEED_LIMIT): Renamed as PREF_MAX_DOWNLOAD_LIMIT.
  6335. (PREF_UPLOAD_LIMIT): Renamed as PREF_MAX_UPLOAD_LIMIT.
  6336. * src/PeerInteractionCommand.cc
  6337. (PeerInteractionCommand): Use PREF_MAX_UPLOAD_LIMIT.
  6338. (receiveMessages): Use PREF_MAX_DOWNLOAD_LIMIT.
  6339. * src/PeerInteraction.cc
  6340. (sendMessages): Use PREF_MAX_UPLOAD_LIMIT.
  6341. * src/main.cc
  6342. (showUsage): Updated the description of "--lowest-speed-limit" option.
  6343. Added the description of "--max-download-limit" option.
  6344. Removed the description of "--upload-limit" option.
  6345. Added the description of "--max-upload-limit" option.
  6346. (main): Use PREF_MAX_UPLOAD_LIMIT, PREF_MAX_DOWNLOAD_LIMIT.
  6347. Added "--max-download-limit" option and "--max-upload-limit" option.
  6348. Added the warning message if "--upload-limit" option is used.
  6349. * src/DownloadCommand.cc
  6350. (executeInternal): Use PREF_MAX_DOWNLOAD_LIMIT.
  6351. 2006-09-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6352. To rewrite segment download mechanism for HTTP/FTP download.
  6353. Use BitfieldMan to manage segment download.
  6354. * src/HttpResponseCommand.h
  6355. (executeInternal): Pass the reference of segment.
  6356. * src/AbstractCommand.cc
  6357. (prepareForRetry): Call segmentMan->cancelSegment here.
  6358. (onAbort): Call segmentMan->cancelSegment here.
  6359. * src/HttpDownloadCommand.cc
  6360. (prepareForNextSegment): New function.
  6361. * src/DownloadEngineFactory.cc
  6362. (newConsoleEngine): Removed splitter.
  6363. (newTorrentConsoleEngine): Removed splitter.
  6364. * src/Request.h
  6365. (segment): Renamed from seg.
  6366. * src/FtpInitiateConnectionCommand.h
  6367. (executeInternal): Pass the reference of segment.
  6368. * src/AbstractCommand.h
  6369. (executeInternal): Pass the reference of segment.
  6370. * src/pref.h
  6371. (PREF_SEGMENT_SIZE): New definition.
  6372. * src/HttpProxyRequestCommand.h
  6373. (executeInternal): Pass the reference of segment.
  6374. * src/HttpResponseCommand.cc
  6375. (checkResponse): Allowed status 206 when a request range starts 0.
  6376. (handleDefaultEncoding): Rewritten the code related to Segment.
  6377. (handleOtherEncoding): Rewritten the code related to Segment.
  6378. * src/SegmentMan.h
  6379. (SegmentEntry): New class.
  6380. (SegmentEntries): New type definition.
  6381. (bitfield): New variable.
  6382. (usedSegmentEntries): New variable.
  6383. (onNullBitfield): New function.
  6384. (checkoutSegment): New function.
  6385. (segments): Removed.
  6386. (splitter): Removed.
  6387. (unregisterId): Removed.
  6388. (getSegment): New function(overload)
  6389. (getDownloadedSize): Removed.
  6390. (cancelSegment): New function.
  6391. (completeSegment): New function.
  6392. (initBitfield): New function.
  6393. (hasSegment): New function.
  6394. (getDownloadLength): New function.
  6395. * src/BitfieldMan.h
  6396. (getStartIndex): New function.
  6397. (getEndIndex): New function.
  6398. (getMissingUnusedIndex): New function(overload).
  6399. (getSparseMissingUnusedIndex): New function.
  6400. * src/BitfieldMan.cc
  6401. (getMissingIndexRandomly): Handle the last byte of bitfield properly.
  6402. (getMissingUnusedIndex): New function(overload).
  6403. (Range): New class.
  6404. (getStartIndex): New function.
  6405. (getEndIndex): New function.
  6406. (getSparseMissingUnusedIndex): New function.
  6407. (isBitSetInternal): Return false if the given index is less than 0.
  6408. * src/HttpInitiateConnectionCommand.h
  6409. (executeInternal): Pass the reference of segment.
  6410. * src/FtpNegotiateCommand.h
  6411. (executeInternal): Pass the reference of segment.
  6412. * src/FtpNegotiateCommand.cc
  6413. (recvSize): Initialize bitfield here.
  6414. * src/FtpTunnelResponseCommand.h
  6415. (executeInternal): Pass the reference of segment.
  6416. * src/HttpConnection.cc
  6417. (createRequest): Rewritten range header processing.
  6418. * src/DownloadCommand.h
  6419. (executeInternal): Pass the reference of segment.
  6420. (prepareForRetry): Removed.
  6421. (prepareForNextSegment): Added an argument segment. Made it a virtual
  6422. function.
  6423. * src/main.cc
  6424. (main): Set the initial value of PREF_SEGMENT_SIZE to 1MB.
  6425. * src/SegmentMan.cc
  6426. (SegmentMan): Added bitfield. Removed splitter.
  6427. (~SegmentMan): Added bitfield. Removed splitter.
  6428. (unregisterId): Removed.
  6429. (getSegment): Rewritten.
  6430. (updateSegment): Rewritten.
  6431. (save): Rewritten.
  6432. (read): Rewritten.
  6433. (finished): Rewritten.
  6434. (getDownloadedSize): Removed.
  6435. (initBitfield): New function.
  6436. (FindSegmentEntryByIndex): New function object.
  6437. (FindSegmentEntryByCuid): New function object.
  6438. (checkoutSegment): New function.
  6439. (onNullBitfield): New function.
  6440. (getSegment): New function(overload).
  6441. (CancelSegment): New function object.
  6442. (cancelSegment): New function.
  6443. (completeSegment): New function.
  6444. (hasSegment): New function.
  6445. (getDownloadLength): New function.
  6446. * src/FtpInitiateConnectionCommand.cc
  6447. (executeInternal): Load .aria2 file after hostname resolution finishes.
  6448. * src/Segment.h: Rewritten.
  6449. * src/Segment.cc (operator<<): New function.
  6450. * src/HttpDownloadCommand.h
  6451. (prepareForNextSegment): New function.
  6452. * src/Request.cc
  6453. (resetUrl): Made segment null.
  6454. * src/DownloadEngine.cc
  6455. (~DownloadEngine): Call cleanQueue before deleting segmentMan.
  6456. * src/HttpProxyRequestCommand.h
  6457. (executeInternal): Pass the reference of segment.
  6458. * src/DownloadCommand.cc
  6459. (executeInternal): Rewritten the code related to Segment.
  6460. (prepareForRetry): Removed.
  6461. (prepareForNextSegment): Rewritten.
  6462. * src/FtpTunnelResponseCommand.h
  6463. (executeInternal): Pass the reference of segment.
  6464. To add HTTP 1.1 persistent connection support(experimental)
  6465. * src/HttpRequestCommand.cc
  6466. (executeInternal): Disable keep alive if it is disabled by
  6467. configuration.
  6468. * src/Request.h
  6469. (keepAlive): New variable.
  6470. (isKeepAlive): New function.
  6471. (setKeepAlive): New function.
  6472. * src/pref.h
  6473. (PREF_HTTP_KEEP_ALIVE): New definition.
  6474. * src/HttpResponseCommand.cc
  6475. (executeInternal): Check the remote server supports keep alive.
  6476. * src/HttpConnection.cc
  6477. (createRequest): Send "Connection: close" only if keep alive is
  6478. disabled.
  6479. * src/main.cc
  6480. (main):
  6481. Set the initial value(false) of PREF_KEEP_ALIVE to false.
  6482. To add max download speed limit:
  6483. * src/pref.h
  6484. (PREF_MAX_SPEED_LIMIT): New definition.
  6485. * src/PeerInteractionCommand.cc
  6486. (executeInternal): Added max download speed limit. Not tested yet.
  6487. * src/SegmentMan.h
  6488. (PeerStats): New type definition.
  6489. (peerStats): New variable.
  6490. (registerPeerStat): New function.
  6491. (FindPeerStat): New function object.
  6492. (getPeerStat): New function.
  6493. (calculateDownloadSpeed): New function.
  6494. * src/SpeedCalc.h: New class.
  6495. * src/SpeedCalc.cc: New class.
  6496. * src/main.cc
  6497. (main):
  6498. Set the initial value of PREF_MAX_SPEED_LIMIT to 0(which means the
  6499. download speed is not restricted).
  6500. * src/PeerStat.h: New class.
  6501. * src/SegmentMan.cc
  6502. (registerPeerStat): New function.
  6503. (calculateDownloadSpeed): New function.
  6504. * src/DownloadCommand.cc
  6505. (STARTUP_IDLE_TIME): New definition.
  6506. (DownloadCommand): Register peerStat to segmentMan. Call peerStat->
  6507. downloadStart.
  6508. (~DownloadCommand): Call peerStat->downloadStop.
  6509. (executeInternal): Added download speed limitter. Rewritten lowest
  6510. speed limitter.
  6511. * src/HttpConnection.cc
  6512. (receiveResponse): Fixed: eohIndex[headerBuf] -> headerBuf[eohIndex].
  6513. * src/AbstractCommand.cc
  6514. (resolveHostname): Throw DlAbortEx if a name resolution failes.
  6515. Added hostname to the error message.
  6516. * src/ConsoleDownloadEngine.cc
  6517. (calculateStatistics): Initialize psize with dlSize.
  6518. * src/PieceMessage.cc
  6519. (receivedAction): Do not call peerInteraction->abortPiece here.
  6520. (onGotWrongPiece): Call peerInteraction->abortPiece here.
  6521. * src/BitfieldMan.h
  6522. (clearAllUseBit): New function.
  6523. (setAllUseBit): New function.
  6524. * src/BitfieldMan.cc
  6525. (clearAllBit): Do not clear useBitfield here.
  6526. (clearAllUseBit): New function.
  6527. (setAllUseBit): New function.
  6528. * src/Piece.cc
  6529. (clearAllBlock): Call bitfield->clearAllUseBit().
  6530. 2006-08-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6531. To make filename URL-decoded:
  6532. * src/HttpResponseCommand.h: Updated doc.
  6533. * src/HttpResponseCommand.cc
  6534. (determinFilename): Made filename URL-decoded.
  6535. * src/FtpInitiateConnectionCommand.cc
  6536. (executeInternal): Made filename URL-decoded.
  6537. * src/Util.h (urldecode): New function.
  6538. * src/Util.cc (urldecode): New function.
  6539. To fix a bug that caused assertion failure in ares_strerror:
  6540. * src/NameResolver.cc (callback): Fixed the bug.
  6541. * Release 0.7.3
  6542. 2006-08-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6543. To add --seed-time and --seed-ratio command-line option:
  6544. * src/Option.h (getAsDouble): New function.
  6545. * src/Option.cc (getAsDouble): New function.
  6546. * src/SeedCheckCommand.h: New class.
  6547. * src/SeedCheckCommand.cc: New class.
  6548. * src/DownloadEngineFactory.cc
  6549. (SeedCheckCommand.h): Included.
  6550. (UnionSeedCriteria.h): Included.
  6551. (TimeSeedCriteria.h): Included.
  6552. (ShareRatioSeedCriteria.h): Included.
  6553. (newTorrentConsoleEngine): Added the processing of seed option.
  6554. * src/SeedCriteria.h: New class.
  6555. * src/ShareRatioSeedCriteria.h: New class.
  6556. * src/TimeSeedCriteria.h: New class.
  6557. * src/UnionSeedCriteria.h: New class.
  6558. * src/prefs.h
  6559. (PREF_SEED_TIME): New definition.
  6560. (PREF_SEED_RATIO): New definition.
  6561. * src/main.cc
  6562. (showUsage): Added --seed-time and --seed-ratio option.
  6563. (main): Added --seed-time and --seed-ratio option.
  6564. Made default log file name "/dev/null".
  6565. * src/SharedHandle.h
  6566. (SharedHandle): Copy constructor. Made it assignable from the
  6567. SharedHandle of the subclasses.
  6568. (operator=): Made it assignable from the SharedHandle of the
  6569. subclasses.
  6570. (getRefCount): New function.
  6571. To add notice log level and the switch to write log to stdout. This
  6572. switch is configurable per log level.
  6573. * src/Logger.h
  6574. (notice): New function.
  6575. (LEVEL): Added NOTICE. Assigned an explicit value to each log level
  6576. constant.
  6577. * src/LogFactory.cc
  6578. (getInstance): The use of NullLogger was removed. A log message with
  6579. notice log level was made written to stdout along with log file.
  6580. * src/NullLogger.h
  6581. (notice): New function.
  6582. * src/SimpleLogger.h
  6583. (writeHeader): Added the 'file' argument.
  6584. (writeLog): Added the 'file' argument.
  6585. (writeFile): New function.
  6586. (stdoutField): New variable.
  6587. (SimpleLogger): Removed the default constructor.
  6588. (SimpleLogger): Made the default value of logfile 0.
  6589. (debug): Added 'virtual' keyword.
  6590. (info): Added 'virtual' keyword.
  6591. (warn): Added 'virtual' keyword.
  6592. (error): Added 'virtual' keyword.
  6593. (notice): New function.
  6594. (setStdout): New function.
  6595. * src/SimpleLogger.cc
  6596. (WRITE_LOG): Replaced writeLog with writeFile.
  6597. (WRITE_LOG_EX): Replaced writeLog with writeFile.
  6598. (SimpleLogger): Removed the default constructor.
  6599. (setStdout): New function.
  6600. (writeLog): Added the handling of NOTICE log level.
  6601. (writeFile): New function.
  6602. (notice): New function.
  6603. * src/TorrentMan.h: Updated doc.
  6604. * src/BitfieldMan.h: Updated doc.
  6605. * src/TrackerWatcherCommand.cc
  6606. (execute): Return true if error occurred in the request to the tracker
  6607. and halt is requested.
  6608. * src/TrackerUpdateCommand.cc
  6609. (execute): Return true if error occurred in the request to the tracker
  6610. and halt is requested.
  6611. To call onDownloadComplete from TorrentMan::completePiece(), not from
  6612. DownloadEngine:
  6613. * src/TorrentConsoleDownloadEngine.h
  6614. (onSelectiveDownloadingCompletes): Removed.
  6615. * src/TorrentConsoleDownloadEngine.cc
  6616. (onSelectiveDownloadingCompletes): Removed.
  6617. * src/TorrentDownloadEngine.h
  6618. (onEndOfRun): Added 'virtual' keyword.
  6619. (afterEachIteration): Removed.
  6620. (onSelectiveDownloadingCompletes): Removed.
  6621. * src/TorrentDownloadEngine.cc
  6622. (onEndOfRun): Removed filenameFixed.
  6623. (afterEachIteration): Removed.
  6624. * src/TorrentMan.cc
  6625. (completePiece): Call onDownloadComplete here.
  6626. (onDownloadComplete): Added 2 log messages.
  6627. 2006-08-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6628. To fix compilation problem on gcc4.1.1(patch#1542283 by tizianomueller)
  6629. * src/NameResolver.h: Added the prototype declaration of callback().
  6630. To support c-ares library:
  6631. * src/AbstractCommand.cc: Replaced HAVE_LIBARES with ENABLE_ASYNC_DNS
  6632. * src/FeatureConfig.cc: Replaced HAVE_LIBARES with ENABLE_ASYNC_DNS
  6633. * src/FtpInitiateConnectionCommand.h:
  6634. Replaced HAVE_LIBARES with ENABLE_ASYNC_DNS
  6635. * src/AbstractCommand.h: Replaced HAVE_LIBARES with ENABLE_ASYNC_DNS
  6636. * src/HttpInitiateConnectionCommand.h:
  6637. Replaced HAVE_LIBARES with ENABLE_ASYNC_DNS
  6638. * src/NameResolver.cc: Replaced HAVE_LIBARES with ENABLE_ASYNC_DNS.
  6639. Added thes upport of c-ares's ares_strerror(the idea came from patch
  6640. #1542285 by tizianomueller)
  6641. * src/HttpInitiateConnectionCommand.cc:
  6642. Replaced HAVE_LIBARES with ENABLE_ASYNC_DNS
  6643. * src/FtpInitiateConnectionCommand.cc:
  6644. Replaced HAVE_LIBARES with ENABLE_ASYNC_DNS
  6645. * src/DownloadEngine.h:
  6646. Replaced HAVE_LIBARES with ENABLE_ASYNC_DNS
  6647. * src/DownloadEngine.cc:
  6648. Replaced HAVE_LIBARES with ENABLE_ASYNC_DNS
  6649. To fix the bug that causes compilation failure with metalink-support
  6650. disabled(bug#1543587):
  6651. * src/main.cc: Fixed with the patch by tizianomueller.
  6652. * Release 0.7.2
  6653. 2006-08-14 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6654. * src/main.cc
  6655. (main): Added a message to inform users that aria2 is starting to
  6656. verify checksum.
  6657. * src/RequestInfo.cc
  6658. (printDownloadAbortMessage): Added a message to inform users that
  6659. transfer can be resumed.
  6660. * src/FeatureConfig.cc
  6661. (FEATURE_ASYNC_DNS): New definition.
  6662. (FeatureConfig): Added aysnc DNS entry.
  6663. To replace CommandUuid with Command* in SocketEntry and
  6664. NameResolverEntry:
  6665. * src/DownloadEngine.h
  6666. (CommandUuids): Removed.
  6667. (SocketEntry::commandUuid): Removed.
  6668. (SocketEntry::command): New variable.
  6669. (SocketEntry::SocketEntry): Updated.
  6670. (SocketEntry::operator==): Updated.
  6671. (NameResolverEntry::commandUuid): Removed.
  6672. (NameResolverEntry::command): New variable.
  6673. (NameResolverEntry::NameResolverEntry): Updated.
  6674. (NameResolverEntry::operator==): Updated.
  6675. (waitData): Changed the argument type.
  6676. (addSocketForReadCheck): Changed the argument type.
  6677. (deleteSocketForReadCheck): Changed the argument type.
  6678. (addSocketForWriteCheck): Changed the argument type.
  6679. (deleteSocketForWriteCheck): Changed the argument type.
  6680. (addNameResolverCheck): Changed the argument type.
  6681. (deleteNameResolverCheck): Changed the argument type.
  6682. * src/DownloadEngine.cc
  6683. (FindCommand): Removed.
  6684. (run): Removed activeUuid. Added activeCommands instead.
  6685. (AccumulateActiveUuid): Renamed as AccumulateActiveCommand.
  6686. (AccumulateActiveCommand): New function object.
  6687. (waitData): Use AccumulateActiveCommand.
  6688. (addSocketForReadCheck): Use Command instead of CommandUuid.
  6689. (deleteSocketForReadCheck): Use Command instead of CommandUuid.
  6690. (addSocketForWriteCheck): Use Command instead of CommandUuid.
  6691. (deleteSocketForWriteCheck): Use Command instead of CommandUuid.
  6692. (addNameResolverCheck): Use Command instead of CommandUuid.
  6693. (deleteNameResolverCheck): Use Command instead of CommandUuid.
  6694. * src/AbstractCommand.cc
  6695. (disableReadCheckSocket): Updated according to the changes in
  6696. DownloadEngine.
  6697. (setReadCheckSocket): Updated according to the changes in
  6698. DownloadEngine.
  6699. (disableWriteCheckSocket): Updated according to the changes in
  6700. DownloadEngine.
  6701. (setWriteCheckSocket): Updated according to the changes in
  6702. DownloadEngine.
  6703. (setNameResolverCheck): Updated according to the changes in
  6704. DownloadEngine.
  6705. (disableNameResolverCheck): Updated according to the changes in
  6706. DownloadEngine.
  6707. * src/AbstractCommand.cc
  6708. (disableReadCheckSocket): Updated according to the changes in
  6709. DownloadEngine.
  6710. (setReadCheckSocket): Updated according to the changes in
  6711. DownloadEngine.
  6712. (disableWriteCheckSocket): Updated according to the changes in
  6713. DownloadEngine.
  6714. (setWriteCheckSocket): Updated according to the changes in
  6715. DownloadEngine.
  6716. * release 0.7.1
  6717. 2006-08-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6718. To handle the case where some BitTorrent tracker requires all letters
  6719. except for [A-Za-z0-9] is URL encoded.
  6720. * src/Util.h
  6721. (torrentUrlencode): New function.
  6722. * src/Util.cc
  6723. (ctype.h): Included.
  6724. (torrentUrlencode): New function.
  6725. * src/TrackerWatcherCommand.cc
  6726. (execute): Use Util::torrentUrlencode() instead of Util::urlencode().
  6727. 2006-08-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6728. To add asynchronous DNS support(libares):
  6729. * src/AbstractCommand.h
  6730. (setNameResolverCheck): New function.
  6731. (disableNameResolverCheck): New function
  6732. (resolveHostname): New function.
  6733. * src/AbstractCommand.cc
  6734. (setNameResolverCheck): New function.
  6735. (disableNameResolverCheck): New function
  6736. (resolveHostname): New function.
  6737. * src/FtpInitiateConnectionCommand.h
  6738. (nameResolver): New function.
  6739. * src/FtpInitiateConnectionCommand.cc
  6740. (Util.h): Included.
  6741. (FtpInitiateConnectionCommand): Call disableReadCheckSocket,
  6742. disableWriteCheckSocket.
  6743. (~FtpInitiateConnectionCommand): Call disableNameResolverCheck.
  6744. (executeInternal): Added async DNS support.
  6745. * src/HttpInitiateConnectionCommand.h
  6746. (nameResolver): New function.
  6747. * src/HttpInitiateConnectionCommand.cc
  6748. (DlRetryEx.h): Included.
  6749. (HttpInitiateConnectionCommand): Call disableReadCheckSocket,
  6750. disableWriteCheckSocket.
  6751. (~HttpInitiateConnectionCommand): Call disableNameResolverCheck.
  6752. (executeInternal): Added async DNS support.
  6753. * src/NameResolver.h: New class. Note: #include <ares.h> is surrounded
  6754. by extern "C" declaration.
  6755. * src/NameResolver.cc: New class.
  6756. * src/Util.h:
  6757. (isNumberAndDotsNotation): New function
  6758. * src/Util.cc
  6759. (isNumberAndDotsNotation): New function.
  6760. * src/DownloadEngine.h
  6761. (NameResolver.h): Included.
  6762. (NameResolverEntry): New class.
  6763. (NameResolverEntries): New type definition.
  6764. (addNameResolverCheck): New function.
  6765. (deleteNameResolverCheck): New function.
  6766. * src/DownloadEngine.cc
  6767. (run): Initialize cp with 0.
  6768. (SetDescriptor::operator()): Added for NameResolverEntry.
  6769. (AccumulateActiveUuid::operator()): Added for NameResolverEntry.
  6770. (waitData): Check nameResolver entries.
  6771. (updateFdSet): Update fds in nameResolver entries.
  6772. (addNameResolverCheck): New function.
  6773. (deleteNameResolverCheck): new function.
  6774. * src/PeerInteractionCommand.cc
  6775. (executeInternal): Fixed wrong socket handling.
  6776. * src/main.cc
  6777. (main): Fixed the initial value of PREF_LOWEST_SPEED_LIMIT option to 0.
  6778. * src/Util.cc
  6779. (fileChecksum): Removed the call to ctx.digestReset().
  6780. 2006-08-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6781. * po/ru.po: Azamat sent me Russian translation.
  6782. * src/FtpNegotiateCommand.cc
  6783. (recvGreeting): Call disableWriteCheckSocket just after
  6784. socket->setBlockingMode(). This avoids unnecessary CPU-hog loop.
  6785. (recvRetr): Recognized status code 125 as a acceptable response code.
  6786. Rename Time.h to TimeA2.h to avoid compilation ploblem on
  6787. case-insesitive filesystem(BUG#1531057).
  6788. * src/Time.h: Renamed as TimeA2.h.
  6789. * src/Time.cc: Renamed as TimeA2.cc.
  6790. * src/TimeA2.h: New class.
  6791. * src/TimeA2.cc: New class.
  6792. * src/PeerChokeCommand.h: Replaced Time.h with TimeA2.h.
  6793. * src/TrackerWatcherCommand.h: Replaced Time.h with TimeA2.h.
  6794. * src/PeerAbstractCommand.h: Replaced Time.h with TimeA2.h.
  6795. * src/AbstractCommand.h: Replaced Time.h with TimeA2.h.
  6796. * src/PeerInteractionCommand.h: Replaced Time.h with TimeA2.h.
  6797. * src/ConsoleDownloadEngine.h: Replaced Time.h with TimeA2.h.
  6798. * src/TorrentAutoSaveCommand.h: Replaced Time.h with TimeA2.h.
  6799. * src/DownloadCommand.h: Replaced Time.h with TimeA2.h.
  6800. * src/TorrentMan.h: Replaced Time.h with TimeA2.h.
  6801. * src/TorrentDownloadEngine.h: Replaced Time.h with TimeA2.h.
  6802. * src/RequestSlot.h: Replaced Time.h with TimeA2.h.
  6803. * src/SleepCommand.h: Replaced Time.h with TimeA2.h.
  6804. * src/DownloadEngine.cc: Replaced Time.h with TimeA2.h.
  6805. * release 0.7.0
  6806. 2006-08-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6807. * src/PeerChokeCommand.h
  6808. (PeerChokeCommand): Rearranged the arguments.
  6809. * src/PeerChokeCommand.cc
  6810. (PeerChokeCommand): Rearranged the arguments.
  6811. * src/MetalinkEntry.h
  6812. (Checksum.h): Included.
  6813. (md5): Removed.
  6814. (sha1): Removed.
  6815. (checksum): New variable.
  6816. (operator=): Updated.
  6817. (check): Removed.
  6818. * src/prefs.h
  6819. (PREF_LOWEST_SPEED_LIMIT): New definition.
  6820. (PREF_FOLLOW_TORRENT): New definition.
  6821. (PREF_SELECT_FILE): New definition.
  6822. (PREF_FOLLOW_METALINK): New definition.
  6823. * src/MetalinkResource.h
  6824. (TYPE_HTTPS): Added to enum TYPE.
  6825. * src/TorrentMan.cc
  6826. (~TorrentMan): Rewritten.
  6827. * src/MultiDiskWriter.cc
  6828. (MultiDiskAdaptor): Updated according to the changes in
  6829. MessageDigestContext.
  6830. (~MultiDiskAdaptor): Updated according to the changes in
  6831. MessageDigestContext.
  6832. (hashUpdate): Updated according to the changes in MessageDigestContext.
  6833. (sha1Sum): Updated according to the changes in MessageDigestContext.
  6834. * src/Util.h
  6835. (fileChecksum): Updated according to the changes in
  6836. MessageDigestContext.
  6837. * src/Util.cc
  6838. (sha1Sum): Updated according to the changes in MessageDigestContext.
  6839. (fileChecksum): Updated according to the changes in
  6840. MessageDigestContext.
  6841. * src/messageDigest.h: Rewritten.
  6842. * src/MetalinkEntry.cc
  6843. (check): Removed.
  6844. (Supported): Updated.
  6845. (dropUnsupportedResource): Fixed a memory leak.
  6846. * src/ShaVisitor.cc
  6847. (ShaVisitor): Updated according to the changes in MessageDigestContext.
  6848. (~ShaVisitor): Updated according to the changes in
  6849. MessageDigestContext.
  6850. (visit): Updated according to the changes in MessageDigestContext.
  6851. * src/main.cc
  6852. (main): Rewritten the portion of download loop. --lowest-speed-limit
  6853. command-line option added.
  6854. * src/DownloadEngine.h
  6855. (SocketEntry): New class.
  6856. (SocketEntries): New definition.
  6857. (PairFind): Removed.
  6858. (SockCmdMap): Removed.
  6859. * src/DownloadEngine.cc
  6860. (DownloadEngine): Rewritten.
  6861. (~DownloadEngine): Rewritten.
  6862. (run): Renamed activeCommandUuids as activeUuids.
  6863. (SetDescriptor): Rewritten.
  6864. (AccumulateActiveCommandUuid): Removed.
  6865. (AccumulateActiveUuid): New function object.
  6866. (waitData): Rewritten.
  6867. (updateFdSet): Rewritten.
  6868. (addSocket): Rewritten.
  6869. (deleteSocket): Rewritten.
  6870. (addSocketForReadCheck): Rewritten.
  6871. (deleteSocketForReadCheck): Rewritten.
  6872. (addSocketForWriteCheck): Rewritten.
  6873. (deleteSocketForWriteCheck): Rewritten.
  6874. * src/Xml2MetalinkProcessor.cc
  6875. (getEntry): Rewritten the portion of MetalinkEntry creation.
  6876. * src/DownloadCommand.cc
  6877. (executeInternal): Added the check routine for lowest speed limit.
  6878. * src/AbstractDiskWriter.cc
  6879. (AbstractDiskWriter): Updated according to the changes in
  6880. MessageDigestContext.
  6881. (~AbstractDiskWriter): Updated according to the changes in
  6882. MessageDigestContext.
  6883. (sha1Sum): Updated according to the changes in MessageDigestContext.
  6884. * src/RequestInfo.h: New class.
  6885. * src/UrlRequestInfo.h: New class.
  6886. * src/UrlRequestInfo.cc: New class.
  6887. * src/TorrentRequestInfo.h: New class.
  6888. * src/TorrentRequestInfo.cc: New class.
  6889. * src/MetalinkRequestInfo.h: New class.
  6890. * src/MetalinkRequestInfo.cc: New class.
  6891. * src/Checksum.h: New class.
  6892. * src/DownloadEngineFactory.h: New class.
  6893. * src/DownloadEngineFactory.cc: New class.
  6894. 2006-08-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6895. * src/Option.h
  6896. (getAsBool): New function.
  6897. * src/Option.cc
  6898. (prefs.h): Included.
  6899. (defined): 0-length value is now recognized as undefined.
  6900. (getAsInt): Rewritten.
  6901. (getAsLLInt): Rewritten.
  6902. (getAsBool): New function.
  6903. * src/FeatureConfig.h: Rewritten.
  6904. * src/FeatureConfig.cc: Rewritten.
  6905. * src/prefs.h
  6906. (PREF_STDOUT_LOG): New definition.
  6907. (PREF_LOG): New definition.
  6908. (PREF_DIR): New definition.
  6909. (PREF_OUT): New definition.
  6910. (PREF_SPLIT): New definition.
  6911. (PREF_DAEMON): New definition.
  6912. (PREF_REFERER): New definition.
  6913. (PREF_TORRENT_FILE): New definition.
  6914. (PREF_LISTEN_PORT): New definition.
  6915. (PREF_METALINK_FILE): New definition.
  6916. (PREF_METALINK_VERSION): New definition.
  6917. (PREF_METALINK_LANGUAGE): New definition.
  6918. (PREF_METALINK_OS): New definition.
  6919. (PREF_METALINK_SERVERS): New definition.
  6920. * src/main.cc
  6921. (main): Following command-line parameters are now put into Option
  6922. class: stdoutLog, logfile, dir, ufilename, split, daemonMode,
  6923. referer, torrentFile, metalinkFile, listenPort, metalinkVersion,
  6924. metalinkLanguage, metalinkOs, metalinkServers
  6925. To fix the bug that aria2 can not handle http response header properly.
  6926. * src/HttpHeader.cc
  6927. (put): Made name lowercased.
  6928. (defined): Made name lowercased.
  6929. (getFirst): Made name lowercased.
  6930. (get): Made name lowercased.
  6931. (getFirstAsInt): Rewritten.
  6932. (getFirstAsLLInt): Rewritten.
  6933. 2006-07-30 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6934. * src/TorrentMan.h:
  6935. (advertisePiece): Updated doc.
  6936. (getAdvertisedPieceIndexes): Updated doc.
  6937. (removeAdvertisedPiece); New function.
  6938. * src/TorrentMan.cc
  6939. (FindElapsedHave): New function object.
  6940. (removeAdvertisedPiece): New function.
  6941. * src/HaveEraseCommand.h: New class.
  6942. * src/HaveEraseCommand.cc: New class.
  6943. * src/FeatureConfig.h: New class.
  6944. * src/FeatureConfig.cc: New class.
  6945. * src/Request.h
  6946. (defaultPorts): Removed.
  6947. * src/Request.cc
  6948. (FeatureConfig.h): Included.
  6949. (Request): Removed the statements related to defaultPorts.
  6950. (parseUrl): Removed metalinkEnabled. Use FeatureConfig instead.
  6951. A default port number is now retrieved from FeatureConfig.
  6952. * src/main.cc
  6953. (HaveEraseCommand.h): Included.
  6954. (showVersion): Added the output of feature list.
  6955. (main): Added HaveEraseCommand to command queue in BitTorrent
  6956. downloading.
  6957. * src/PeerInteractionCommand.h
  6958. (chokeCheckPoint): Commented out.
  6959. (periodicExecPoint): New variable.
  6960. * src/PeerInteractionCommand.cc
  6961. (executeInternal): Following methods are now called in at least every
  6962. 0.5 seconds to reduce CPU usage:
  6963. detectMessageFlooding(), peerInteraction->checkRequestSlot(),
  6964. checkHave(), sendKeepAlive().
  6965. (checkLongTimePeerChoking): Commented out.
  6966. * src/BitfieldMan.h
  6967. (getNthBitIndex): Changed the method signature.
  6968. (getMissingIndexRandomly): Changed the method signature.
  6969. * src/BitfieldMan.cc
  6970. (getNthBitIndex): Rewritten
  6971. (getMissingIndexRandomly): Rewritten.
  6972. (hasMissingPiece): Rewritten.
  6973. (getMissingIndex): Refactored.
  6974. (getMissingUnusedIndex); Refactored.
  6975. (getMissingIndex): Refactored.
  6976. 2006-07-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  6977. * src/PeerMessage.h
  6978. (Piece.h): Included.
  6979. (SharedHandle.h): Included.
  6980. (invalidate): New variable.
  6981. (uploading): New variable.
  6982. (isInvalidate): New function.
  6983. (isUploading): New function.
  6984. (onPush): New function.
  6985. (onChoked): New function.
  6986. (onCanceled): New function.
  6987. (onAbortPiece): New function.
  6988. (PeerMessageHandle): New type definition.
  6989. * src/PeerMessage.cc
  6990. (PeerMessage): Added the initialization for invalidate and uploading.
  6991. * src/CancelMessage.h
  6992. (CancelMessage): Rewritten.
  6993. * src/RejectMessage.h
  6994. (RejectMessage): Rewritten.
  6995. * src/Metalinker.h
  6996. (operator=): Defined.
  6997. * src/MetaEntry.h
  6998. (operator=): Defined.
  6999. * src/MetalinkResource.h
  7000. (operator=): Defined.
  7001. * src/AllowedFastMessage.h
  7002. (AllowedFastMessage): Rewritten.
  7003. * src/HandshakeMessage.h
  7004. (HandshakeMessage): New function(overload).
  7005. * src/HandshakeMessage.cc
  7006. (HandshakeMessage): Rewritten.
  7007. (init): New function.
  7008. * src/HaveMessage.h
  7009. (HaveMessage): Rewritten.
  7010. * src/Time.h
  7011. (operator=): Defined the function body here.
  7012. * src/Time.cc
  7013. (operator=): Removed.
  7014. * src/SocketCore.h
  7015. (operator==): Defined here.
  7016. (operator!=): Defined here.
  7017. (operator<): Defined here.
  7018. * src/SocketCore.cc
  7019. (operator==): Removed.
  7020. (operator<): Removed.
  7021. * src/BitfieldMan.h
  7022. (operator=): Defined the function body here.
  7023. * src/BitfieldMan.cc
  7024. (operator=): Removed.
  7025. * src/TorrentMan.h
  7026. (deleteErrorPeer): Removed.
  7027. (deleteUnusedPeer); New function.
  7028. * src/TorrentMan.cc
  7029. (addPeer): Call deleteUnusedPeer.
  7030. (deleteErrorPeer): Removed.
  7031. (deleteUnusedPeer): New function.
  7032. * src/PeerAbstractCommand.h
  7033. (setNoCheck): New function.
  7034. (noCheck): New variable.
  7035. * src/PeerAbstractCommand.cc
  7036. (PeerAbstractCommand): Added the initialization of noCheck.
  7037. (execute): Added a check for noCheck.
  7038. (setNoCheck): New function.
  7039. * src/Util.h
  7040. (stdio.h): Included.
  7041. * src/Util.cc
  7042. (unistd.h): Included.
  7043. * src/DefaultDiskWriter.cc
  7044. (unistd.h): Included.
  7045. * src/Peer.h
  7046. (operator==): Defined the function body here.
  7047. (operator!=): Defined the function body here.
  7048. * src/Peer.cc
  7049. (operator==): Removed.
  7050. (operator!=): Removed.
  7051. * src/Piece.h
  7052. (Piece): Defined the function body here(copy constructor).
  7053. (operator=): Defined the function body here.
  7054. (operator==): Defined the function body here.
  7055. * src/Piece.cc
  7056. (Piece): Removed(copy constructor).
  7057. (operator=): Removed.
  7058. (operator==): Removed.
  7059. * src/PeerMessageUtil.h
  7060. (ChokeMessage.h): Removed.
  7061. (UnchokeMessage.h): Removed.
  7062. (InterestedMessage.h): Removed.
  7063. (NotInterestedMessage.h): Removed.
  7064. (HaveMessage.h): Removed.
  7065. (BitfieldMessage.h): Removed.
  7066. (RequestMessage.h): Removed.
  7067. (CancelMessage.h): Removed.
  7068. (PieceMessage.h): Removed.
  7069. (HandshakeMessage.h): Removed.
  7070. (KeepAliveMessage.h): Removed.
  7071. (PortMessage.h): Removed.
  7072. (HaveAllMessage.h): Removed.
  7073. (HaveNoneMessage.h): Removed.
  7074. (PeerConnection.h): Removed.
  7075. (HandshakeMessage.h): Included.
  7076. * src/BitfieldMessage.h
  7077. (init): New function.
  7078. (BitfieldMessage): Rewritten.
  7079. (BitfieldMessage): New function(overload).
  7080. * src/RequestSlot.h
  7081. (operator=): Defined the function body here.
  7082. (operator==): Defined the function body here.
  7083. * src/RequestSlot.cc
  7084. (operator=): Removed.
  7085. (operator==): Removed.
  7086. To remove the dependency on the PeerMessage subclass from
  7087. PeerInteraction:
  7088. * src/PeerMessageFactory.h: New class.
  7089. * src/PeerMessageFactory.cc: New class.
  7090. * src/SimplePeerMessage.cc
  7091. (send): If invalidate is true then do nothing.
  7092. * src/PeerInteractionCommand.cc
  7093. (HandshakeMessage.h): Included.
  7094. (KeepAliveMessage.h): Included.
  7095. (ChokeMessage.h): Included.
  7096. (UnchokeMessage.h): Included.
  7097. (HaveMessage.h): Included.
  7098. (executeInternal): Call setNoCheck().
  7099. Removed setWriteCheckSocket(socket).
  7100. * src/PeerInteraction.h
  7101. (ChokeMessage.h): Removed.
  7102. (UnchokeMessage.h): Removed.
  7103. (InterestedMessage.h): Removed.
  7104. (NotInterestedMessage.h): Removed.
  7105. (HaveMessage.h): Removed.
  7106. (BitfieldMessage.h): Removed.
  7107. (RequestMessage.h): Removed.
  7108. (CancelMessage.h): Removed.
  7109. (PieceMessage.h): Removed.
  7110. (HandshakeMessage.h): Removed.
  7111. (KeepAliveMessage.h): Removed.
  7112. (PortMessage.h): Removed.
  7113. (HaveAllMessage.h): Removed.
  7114. (HaveNoneMessage.h): Removed.
  7115. (RejectMessage.h): Removed.
  7116. (AllowedFastMessage.h): Removed.
  7117. (SuggestPieceMessage.h): Removed.
  7118. (PeerMessageFactory.h): Included.
  7119. (PeerMessageHandle): Removed typedef of PeerMessageHandle.
  7120. (HandshakeMessageHandle): Removed typedef of HandshakeMessageHandle.
  7121. (PeerMessageFactory): New variable.
  7122. (createPeerMessage): Removed.
  7123. (createHandshakeMessage): Removed.
  7124. (setPeerMessageCommonProperty): Removed.
  7125. (addRequestSlot): New function.
  7126. (receiveHandshake): Changed the return value type to PeerMessageHandle.
  7127. (getPeerMessageFactory): New function.
  7128. (createRequestMessage): Removed.
  7129. (createCancelMessage): Removed.
  7130. (createPieceMessage): Removed.
  7131. (createHaveMessage): Removed.
  7132. (createChokeMessage): Removed.
  7133. (createUnchokeMessage): Removed.
  7134. (createInterestedMessage): Removed.
  7135. (createNotInterestedMessage): Removed.
  7136. (createBitfieldMessage): Removed.
  7137. (createKeepAliveMessage): Removed.
  7138. (createHaveAllMessage): Removed.
  7139. (createHaveNoneMessage): Removed.
  7140. (createRejectMessage): Removed.
  7141. (createAllowedFastMessage): Removed.
  7142. * src/PeerInteraction.cc
  7143. (PeerInteraction): Allocate PeerMessageFactory here.
  7144. (~PeerInteraction): Deallocate PeerMessageFactory here.
  7145. (sendMessages): Use msg->isUploading() instead of msg->getId() ==
  7146. PieceMessage::ID.
  7147. (addMessage): Simplified by using PeerMessage::onPush().
  7148. (addRequestSlot): New function.
  7149. (rejectAllPieceMessageInQueue): Simplified by using
  7150. PeerMessage::onChoked().
  7151. (rejectPieceMessageInQueue): Simplified by using
  7152. PeerMessage::onCanceled().
  7153. (abortPiece): Simplified by using PeerMessage::abortPiece().
  7154. (receiveHandshake): Changed the return value type to PeerMessageHandle.
  7155. (createHandshakeMessage): Removed.
  7156. (createPeerMessage): Removed.
  7157. (sendHandshake): Call PeerMessageFactory::createHandshakeMessage().
  7158. (setPeerMessageCommonProperty): Removed.
  7159. (createRequestMessage): Removed.
  7160. (createCancelMessage): Removed.
  7161. (createPieceMessage): Removed.
  7162. (createHaveMessage): Removed.
  7163. (createChokeMessage): Removed.
  7164. (createUnchokeMessage): Removed.
  7165. (createInterestedMessage): Removed.
  7166. (createNotInterestedMessage): Removed.
  7167. (createBitfieldMessage): Removed.
  7168. (createKeepAliveMessage): Removed.
  7169. (createHaveAllMessage): Removed.
  7170. (createHaveNoneMessage): Removed.
  7171. (createRejectMessage): Removed.
  7172. (createAllowedFastMessage): Removed.
  7173. * src/PieceMessage.h
  7174. (createRejectMessage): New function.
  7175. (PieceMessage): Rewritten.
  7176. (onChoked): New function.
  7177. (onCanceled): New function.
  7178. * src/PieceMessage.cc
  7179. (send): If invalidate is true then do nothing, just return.
  7180. (createRejectMessage): New function.
  7181. (onChoked): New function.
  7182. (onCanceled): New function.
  7183. * src/RequestMessage.h
  7184. (RequestMessage): Rewritten.
  7185. (onPush): New function.
  7186. (onAbortPiece): New function.
  7187. * src/RequestMessage.cc
  7188. (onPush): New function.
  7189. (onAbortPiece): New function.
  7190. Update fd_set when a socket is added or deleted in order to improve
  7191. performance:
  7192. * src/DownloadEngine.h
  7193. (rfdset): New variable.
  7194. (wfdset): New variable.
  7195. (updateFdSet): New function.
  7196. * src/DownloadEngine.cc
  7197. (SetDescriptor::operator()): Use SockCmdMap::value_type.
  7198. (AccumulateActiveCommandUuid::operator()): Use SockCmdMap::value_type.
  7199. (waitData): Copy rfdset and wfdset.
  7200. (updateFdSet): New function.
  7201. (addSocket): Call updateFdSet.
  7202. (deleteSocket): Call updateFdSet.
  7203. 2006-07-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7204. To add the support for Metalink3.0 backward compatible links:
  7205. * src/Request.h
  7206. (SAFE_CHARS): Added '#'.
  7207. (METALINK_MARK): New definition.
  7208. * src/Request.cc
  7209. (parseUrl): Added the support for Metalink3.0 backward compatible
  7210. links.
  7211. etc
  7212. * src/PeerInteraction.cc
  7213. (MsgPushBack): Removed.
  7214. (sendMessages): Use STL copy and back_inserter.
  7215. (rejectAllPieceMessageInQueue): Use STL copy and back_inserter.
  7216. (rejectPieceMessageInQueue): Use STL copy and back_inserter.
  7217. * src/TorrentMan.h
  7218. (MAX_PEER_LIST_SIZE): Changed to 100 from 250.
  7219. 2006-07-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7220. * src/SharedHandle.h: New class.
  7221. To wrap Socket, Command, PeerMessage and Peer with SharedHandle:
  7222. * src/HttpResponseCommand.h
  7223. (HttpResponseCommand): Wrapped Socket.
  7224. * src/SocketCore.h
  7225. (operator==): New function.
  7226. (operator!=): New function.
  7227. (operator<): New function.
  7228. (getSockfd): New function.
  7229. (isOpen): New function.
  7230. (writeData): New function.
  7231. * src/SocketCore.cc
  7232. (operator==): New function.
  7233. (operator!=): New function.
  7234. (operator<): New function.
  7235. * src/AbstractCommand.h
  7236. (socket): Changed its type to SocketHandle.
  7237. (setReadCheckSocket): Replaced Socket with SocketHandle.
  7238. (setWriteCheckSocket): Replaced Socket with SocketHandle.
  7239. (disableReadCheckSocket): New function.
  7240. (disableWriteCheckSocket): New function.
  7241. (readCheckTarget): Changed its type to SocketHandle.
  7242. (writeCheckTarget): Changed its type to SocketHandle.
  7243. (AbstractCommand): Replaced Socket with SocketHandle.
  7244. * src/AbstractCommand.cc
  7245. (AbstractCommand): Replaced Socket with SocketHandle.
  7246. (~AbstractCommand): Removed the deallocation for Socket object.
  7247. (disableReadCheckSocket): New function.
  7248. (setReadCheckSocket): Replaced Socket with SocketHandle.
  7249. (disableWriteCheckSocket): New function.
  7250. (setWriteCheckSocket): Replaced Socket with SocketHandle.
  7251. * src/HttpDownloadCommand.cc
  7252. (DownloadCommand): Replaced Socket with SocketHandle.
  7253. * src/PeerAbstractCommand.h
  7254. (socket): Changed its type to SocketHandle.
  7255. (peer): Changed its type to PeerHandle.
  7256. (setReadCheckSocket): Replaced Socket with SocketHandle.
  7257. (setWriteCheckSocket): Replaced Socket with SocketHandle.
  7258. (disableReadCheckSocket): New function.
  7259. (disableWriteCheckSocket): New function.
  7260. (readCheckTarget): Changed its type to SocketHandle.
  7261. (writeCheckTarget): Changed its type to SocketHandle.
  7262. (PeerAbstractCommand): Replaced Socket with SocketHandle.
  7263. Replaced Peer with PeerHandle.
  7264. * src/HttpRequestCommand.cc
  7265. (HttpRequestCommand): Replaced Socket with SocketHandle.
  7266. Use disableReadCheckSocket.
  7267. * src/PeerInitiateConnectionCommand.h
  7268. (PeerInitiateConnectionCommand): Replaced Peer with PeerHandle.
  7269. * src/PeerChokeCommand.cc
  7270. (UploadFaster::operator()): Replaced Peer with PeerHandle.
  7271. (DownloadFaster::operator()): Replaced Peer with PeerHandle.
  7272. (execute): Use PeerHandle.
  7273. * src/PeerConnection.h
  7274. (HandshakeMessage.h): Removed include of HandshakeMessage.h.
  7275. (socket): Changed its type to SocketHandle.
  7276. (PeerConnection): Replaced Socket with SocketHandle.
  7277. * src/PeerConnection.cc
  7278. (PeerConnection): Replaced Socket with SocketHandle.
  7279. * src/PeerInteractionCommand.h
  7280. (PeerInteractionCommand): Replaced socket with SocketHandle.
  7281. Replaced Peer with PeerHandle.
  7282. * src/PeerInteractionCommand.cc
  7283. (PeerInteractionCommand): Replaced Socket with SocketHandle.
  7284. Replaced Peer with PeerHandle.
  7285. (executeInternal): Use disableWriteCheckSocket.
  7286. Use HandshakeMessageHandle.
  7287. (receiveMessages): Use PeerMessageHandle.
  7288. (prepareForNextPeer): Use PeerHandle.
  7289. * src/HttpProxyRequestCommand.h
  7290. (HttpProxyRequestCommand): Replaced Socket with SocketHandle.
  7291. * src/HttpResponseCommand.cc
  7292. (HttpResponseCommand): Replaced Socket with SocketHandle.
  7293. * src/TorrentMan.cc
  7294. (nullPeer): Added external reference.
  7295. (~TorrentMan): Removed the deallocation of the elements of peers.
  7296. (addPeer): Rewritten.
  7297. (isPeerAvailable): Use nullPeer.
  7298. (deleteOldpeers): Replaced with deleteErrorPeer.
  7299. (deleteErrorPeer): New function.
  7300. (getPeer): Use PeerHandle and nullPeer.
  7301. (hasMissingPiece): Replaced Peer with PeerHandle.
  7302. (getMissingPieceIndex): Replaced Peer with PeerHandle.
  7303. (getMissingFastPieceIndex): Replaced Peer with PeerHandle.
  7304. (getMissingFastPiece): Replaced Peer with PeerHandle.
  7305. (getMissingPiece): Replaced Peer with PeerHandle.
  7306. * src/FtpNegotiateCommand.cc
  7307. (FtpNegotiationCommand): Replaced Peer with PeerHandle.
  7308. (~FtpNegotiationCommand): Removed the deallocation of Sockets.
  7309. (recvGreeting): Use disableWriteCheckSocket.
  7310. (recvPasv): Removed the allocation of Socket.
  7311. Use disableReadCheckSocket.
  7312. (sendRestPasv): Use disableWriteCheckSocket.
  7313. (recvRetr): Changed assertion.
  7314. * src/PeerInteraction.h
  7315. (SharedHandle.h): Included SharedHandle.h.
  7316. (PeerMessageHandle): New type definition.
  7317. (HandshakeMessageHandle): New type definition.
  7318. (MessageQueue): Changed. Now its element is of type PeerMessageHandle.
  7319. (peer): Changed its type to PeerHandle.
  7320. (createHandshakeMessage): Replaced HandshakeMessage with
  7321. HandshakeMessageHandle.
  7322. (createPeerMessage): Replaced PeerMessageHandle with PeerMessage.
  7323. (PeerInteraction): Replaced Peer with PeerHandle.
  7324. Replaced Socket with SocketHandle.
  7325. (addMessage): Replaced PeerMessage with PeerMessageHandle.
  7326. (receiveMessage): Replaced PeerMessage with PeerMessageHandle.
  7327. (receiveHandshake): Replaced HandshakeMessage with
  7328. HandshakeMessageHandle.
  7329. * src/PeerInteraction.cc
  7330. (PeerInteraction): Replaced Peer with PeerHandle.
  7331. Replaced Socket with SocketHandle.
  7332. (~PeerInteraction): Removed the deallocation of the elements of
  7333. messageQueue.
  7334. (MsgPushBack::operator()): Replaced PeerMessage with PeerMessageHandle.
  7335. (isSendingMessageInProgress): Replaced PeerMessage with
  7336. PeerMessageHandle.
  7337. (sendMessages): Use PeerMessageHandle. Removed try-catch block.
  7338. (addMessage): Replaced PeerMessage with PeerMessageHandle.
  7339. (rejectAllPieceMessageInQueue): Use PeerMessageHandle.
  7340. (rejectPieceMessageInQueue): Use PeerMessageHandle.
  7341. (abortPiece): Use PeerMessageHandle.
  7342. (receiveHandshake): Replaced HandshakeMessage with
  7343. HandshakeMessageHandle. Removed try-catch block.
  7344. (createHandshakeMessage): Replaced HandshakeMessage with
  7345. HandshakeMessageHandle.
  7346. (receiveMessage): Replaced PeerMessage with PeerMessageHandle.
  7347. Removed try-catch block.
  7348. (createPeerMessage): Replaced PeerMessage with PeerMessageHandle.
  7349. * src/HttpProxyResponseCommand.cc
  7350. (HttpProxyRequestCommand): Replaced Socket with SocketHandle.
  7351. * src/FtpTunnelResponseCommand.h
  7352. (FtpTunnelResponseCommand): Replaced Socket with SocketHandle.
  7353. * src/HttpConnection.cc
  7354. (HttpConnection): Replaced Socket with SocketHandle.
  7355. * src/PeerAbstractCommand.cc
  7356. (PeerAbstractCommand): Replaced Socket with SocketHandle.
  7357. (~PeerAbstractCommand): Removed the deallocation of socket.
  7358. Use disableReadCheckSocket, disableWriteCheckSocket.
  7359. (disableReadCheckSocket): New function.
  7360. (setReadCheckSocket): Replaced Socket with SocketHandle.
  7361. (disableWriteCheckSocket): New function.
  7362. (setWriteCheckSocket): Replaced Socket with SocketHandle.
  7363. * src/InitiateConnectionCommandFactory.h: Corrected indentation.
  7364. * src/FtpTunnelRequestCommand.cc
  7365. (FtpTunnelRequestCommand): Replaced Socket with SocketHandle.
  7366. (~FtpTunnelRequestCommand): Corrected indentation.
  7367. * src/DownloadCommand.h
  7368. (DownloadCommand): Replaced Socket with SocketHandle.
  7369. * src/PeerListenCommand.cc
  7370. (PeerListenCommand): Removed the initialization of socket.
  7371. (~PeerListenCommand): Removed the deallocation of socket.
  7372. (bindPort): Use SocketHandle.
  7373. (execute): Use SocketHandle and PeerHandle.
  7374. * src/FtpDowndloadCommand.cc
  7375. (FtpDownloadCommand): Replaced Socket with SocketHandle.
  7376. (~FtpDownloadCommand): Removed the deallocation of ctrlSocket.
  7377. * src/main.cc
  7378. (main): Corrected indentation.
  7379. * src/HttpInitiateConnectionCommand.cc
  7380. (HttpInitiateConnectionCommand): Replaced Socket with SocketHandle.
  7381. (executeInternal): Removed the allocation of socket.
  7382. * src/HttpRequestCommand.h
  7383. (HttpRequestCommand): Replaced Socket with SocketHandle.
  7384. * src/FtpNegotiationCommand.h
  7385. (dataSocket): Changed its type to SocketHandle.
  7386. (serverSocket): Changed its type to SocketHandle.
  7387. (FtpNegotiationCommand): Replaced Socket with SocketHandle.
  7388. * src/TorrentMan.h
  7389. (MAX_PEER_UPDATE): Removed.
  7390. (MAX_PEERS): New definition.
  7391. (Peers): The element is now of type PeerHandle.
  7392. (addPeer): Replaced Peer with PeerHandle. Removed 'duplicate' argument.
  7393. (getPeer): Replaced Peer with PeerHandle.
  7394. (deleteOldErrorPeers): Removed.
  7395. (deleteErrorPeer): New function.
  7396. (hasMissingPiece): Replaced Peer with PeerHandle.
  7397. (getMissingPieceIndex): Replaced Peer with PeerHandle.
  7398. (getMissingPiece): Replaced Peer with PeerHandle.
  7399. (getMissingFastPieceIndex): Replaced Peer with PeerHandle.
  7400. (getMissingFastPiece): Replaced Peer with PeerHandle.
  7401. (addActivePeer): Replaced Peer with PeerHandle.
  7402. (deleteActivePeer): Replaced Peer with PeerHandle.
  7403. Added a check for the return value of find.
  7404. * src/FtpTunnelResponseCommand.cc
  7405. (FtpTunnelResponseCommand): Replaced Socket with SocketHandle.
  7406. * src/FtpInitiateConnectionCommand.cc
  7407. (executeInternal): Removed the allocation of socket.
  7408. * src/DownloadEngine.h
  7409. (Sockets): An element is now of type SocketHandle.
  7410. (SockCmdMap): A key is of type SocketHandle, a value is of type int.
  7411. (CommandUuids): New type definition.
  7412. (rsockets): Changed its type to SockCmdMap.
  7413. (wsockets): Changed its type to SockCmdMap.
  7414. (addSocket): Rewritten.
  7415. (deleteSocket): Rewritten.
  7416. (addSocketForReadCheck): Rewritten.
  7417. (deleteSocketForReadCheck): Rewritten.
  7418. (addSocketForWriteCheck): Rewritten.
  7419. (deleteSocketForWriteCheck): Rewritten.
  7420. (PairFind): New template class.
  7421. * src/HttpDownloadCommand.h
  7422. (HttpDownloadCommand): Replaced Socket with SocketHandle.
  7423. * src/FtpConnection.cc
  7424. (FtpConnection): Replaced Socket with SocketHandle.
  7425. (sendPort): Removed the allocation of serverSocket. Removed try-catch
  7426. block.
  7427. * src/InitiateConnectionCommandFactory.cc
  7428. (DlAbortEx.h): Included DlAbortEx.h.
  7429. (createInitiateConnectionCommand): Throw exception if the protocol of
  7430. requested URI is not supported.
  7431. * src/Peer.cc
  7432. (nullPeer): Changed its type to PeerHandle.
  7433. (operator==): New function.
  7434. (operator!=): New function.
  7435. * src/Peer.h
  7436. (SharedHandle.h): Included SharedHandle.h.
  7437. (operator==): New function.
  7438. (operator!=): New function.
  7439. (Peer): Added the default constructor.
  7440. Use resetStatus() to initialize member variables.
  7441. (nullPeer): Removed.
  7442. * src/TrackerUpdateCommand.cc
  7443. (execute): Brushed up using SharedHandle. Replaced MAX_PEER_UPDATE
  7444. with MIN_PEERS.
  7445. * src/PeerListenCommand.h
  7446. (socket): Changed its type to SocketHandle.
  7447. * src/Command.h
  7448. (CommandUuid): New type definition.
  7449. (uuid): New variable.
  7450. (uuidGen): New variable.
  7451. (Command): Added the initialization of uuid.
  7452. (getUuid): New function.
  7453. * src/Socket.h
  7454. (Socket): Removed.
  7455. (SocketHandle): New type definition.
  7456. * src/DownloadEngine.h
  7457. (FindCommand): New function object.
  7458. (run): The portion of socket check was rewritten.
  7459. (SetDescriptor): New function object.
  7460. (AccumulateActiveCommandUuid): New function object.
  7461. (waitData): Rewritten.
  7462. (addSocket): Rewritten.
  7463. (deleteSocket): Rewritten.
  7464. (addSocketForReadCheck): Rewritten.
  7465. (addSocketForWriteCheck): Rewritten.
  7466. (deleteSocketForReadCheck): Rewritten.
  7467. (deleteSocketForWriteCheck): Rewritten.
  7468. * src/HttpProxyResponseCommand.h
  7469. (HttpProxyResponseCommand): Replaced Socket with SocketHandle.
  7470. * src/HttpConnection.h
  7471. (socket): Changed its type to SocketHandle.
  7472. (HttpConnection): Replaced Socket with SocketHandle.
  7473. * src/PeerInitiateConnectionCommand.cc
  7474. (PeerInitiateConnectionCommand): Replaced Peer with PeerHandle.
  7475. (executeInternal): Removed the allocation of socket.
  7476. (prepareForNextPeer): Use PeerHandle.
  7477. * src/PeerMessage.h
  7478. (peer): Changed its type to PeerHandle.
  7479. (getPeer): Replaced Peer with PeerHandle.
  7480. (setPeer): Replaced Peer with PeerHandle.
  7481. * src/DownloadCommand.cc
  7482. (DownloadCommand): Replaced Socket with SocketHandle.
  7483. * src/FtpConnection.h
  7484. (socket): Changed its type to SocketHandle.
  7485. (FtpConnection): Replaced Socket with SocketHandle.
  7486. (sendPort); Replaced Socket with SocketHandle.
  7487. * src/FtpDowndloadCommand.h
  7488. (ctrlSocket): Changed its type to SocketHandle.
  7489. (FtpDownloadCommand): Replaced Socket with SocketHandle.
  7490. * src/HttpProxyRequestCommand.cc
  7491. (HttpProxyRequestCommand): Replaced Socket with SocketHandle.
  7492. * src/FtpTunnelRequestCommand.h
  7493. (FtpTunnelRequestCommand): Replaced Socket with SocketHandle.
  7494. etc
  7495. * src/PeerChokeCommand.h
  7496. (setAllPeerChoked): Removed.
  7497. (setAllPeerResetDelta): Removed.
  7498. * src/PeerChokeCommand.cc
  7499. (setAllPeerChoked): Removed.
  7500. (ChokePeer): New function object.
  7501. (setAllPeerResetDelta): Removed.
  7502. (ResetDelta): New function object.
  7503. (orderByDownloadRate): Fixed a bug: use DowloadFaster, not UploadFaster
  7504. (execute): Show download speed when the local node is a seeder.
  7505. setAllPeerChoked and setAllPeerResetDelta were rewritten
  7506. using STL.
  7507. * src/TrackerWatcherCommand.h
  7508. (MIN_PEERS): Removed.
  7509. * src/TorrentMan.cc
  7510. (getPeer): Replaced MAX_PEER_UPDATE with MIN_PEERS.
  7511. 2006-07-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7512. To fix the bug that .aria2 file is not saved if downloading is stopped
  7513. by the errors:it results that aria2 can not resume downloading:
  7514. * src/main.cc
  7515. (normalDownload): Added the call to save().
  7516. (main): Added the deletion of the elements in 'reserved'.
  7517. To fix log:
  7518. * src/PeerInteraction.cc
  7519. (receiveHandshake): Fixed log.
  7520. 2006-07-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7521. To improve download performance in BitTorrent:
  7522. * src/TorrentMan.cc
  7523. (getPeer): Check the number of connections. Return nullPeer if
  7524. it is greater than MAX_PEER_UPDATE.
  7525. This code was originally here, but was removed in 0.5.1.
  7526. 2006-07-04 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7527. To improve the conditional compilation:
  7528. * src/MultiDiskWriter.h:
  7529. Replaced ENABLE_SHA1DIGEST with ENABLE_MESSAGE_DIGEST.
  7530. * src/MultiDiskWriter.cc:
  7531. Replaced ENABLE_SHA1DIGEST with ENABLE_MESSAGE_DIGEST.
  7532. * src/Util.h:
  7533. Replaced ENABLE_SHA1DIGEST with ENABLE_MESSAGE_DIGEST.
  7534. Added ENABLE_BITTORRENT around computeFastSet().
  7535. * src/Util.cc:
  7536. Replaced ENABLE_SHA1DIGEST with ENABLE_MESSAGE_DIGEST.
  7537. Added ENABLE_BITTORRENT around computeFastSet().
  7538. * src/messageDigest.h:
  7539. Replaced ENABLE_BITTORRENT with ENABLE_SSL.
  7540. * src/ShaVisitor.h:
  7541. Replaced ENABLE_SHA1DIGEST with ENABLE_MESSAGE_DIGEST.
  7542. * src/ShaVisitor.cc:
  7543. Replaced ENABLE_SHA1DIGEST with ENABLE_MESSAGE_DIGEST.
  7544. * src/main.cc:
  7545. Added ENABLE_BITTORRENT around includes and blocks related to
  7546. BitTorrent.
  7547. Added ENABLE_MESSAGE_DIGEST to skip checksum checking when the message
  7548. digest support is not available.
  7549. * src/AbstractDiskWriter.h:
  7550. Replaced ENABLE_SHA1DIGEST with ENABLE_MESSAGE_DIGEST.
  7551. * src/AbstractDiskWriter.cc:
  7552. Replaced ENABLE_SHA1DIGEST with ENABLE_MESSAGE_DIGEST.
  7553. * src/MetalinkEntry.cc
  7554. (check): Added ENABLE_MESSAGE_DIGEST. Return true if the message digest
  7555. support is not available.
  7556. To add command-line options for Metalink:
  7557. * src/main.cc:
  7558. Added metalink-version, metalink-language, metalink-os,
  7559. follow-metalink.
  7560. To use EXIT_SUCCESS and EXIT_FAILURE with exit():
  7561. * src/main.cc: Use these definition.
  7562. * Release 0.6.0
  7563. 2006-07-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7564. To add Metalink support(http/ftp only):
  7565. * src/AbstractCommand.h
  7566. (tryReserved): New function.
  7567. * src/AbstractCommand.cc
  7568. (execute): Call tryReserved().
  7569. (tryReserved): New function.
  7570. * src/Request.h
  7571. (Requests): New type definition.
  7572. * src/SegmentMan.h
  7573. (reserved): New variable.
  7574. * src/Util.h
  7575. (fileChecksum): New function.
  7576. (toUpper): New function.
  7577. (toLower): New function.
  7578. * src/Util.cc
  7579. (messageDigest.h): Included.
  7580. (trim): Trim \r\n\t.
  7581. (fileChecksum): New function.
  7582. (toUpper): New function.
  7583. (toLower): New function.
  7584. * src/main.cc
  7585. (normalDownload): New function.
  7586. (main): Added 2 command-line options: metalink-file,
  7587. metalink-connection. Their usage has not been written yet.
  7588. * src/MetalinkProcessor.h: New class.
  7589. * src/Xml2MetalinkProcessor.h: New class.
  7590. * src/Xml2MetalinkProcessor.cc: New class.
  7591. * src/MetalinkEntry.h: New class.
  7592. * src/MetalinkEntry.cc: New class.
  7593. * src/MetalinkResource.h: New class.
  7594. * src/MetalinkResource.cc: New class.
  7595. To add md5 message digest checking:
  7596. * src/messageDigest.h: Rewritten.
  7597. * src/MultiDiskWriter.cc: Updated according to the changes in
  7598. messageDigest.h.
  7599. * src/ShaVisitor.cc: Updated according to the changes in
  7600. messageDigest.h.
  7601. * src/Util.cc: Updated according to the changes in messageDigest.h.
  7602. * src/AbstractDiskWriter.cc: Updated according to the changes in
  7603. messageDigest.h.
  7604. To fix a bug that causes segfault when the payload length in peer
  7605. message is less than 0:
  7606. * src/PeerConnection.cc:
  7607. (receiveMessage): Fixed the bug.
  7608. * src/PeerMessageUtil.cc
  7609. (checkLength): Throw an exception if length is less than or equals to
  7610. 0.
  7611. To add new interfaces to Base64 encoding/decoding:
  7612. * src/Base64.h
  7613. (part_encode): Changed the method signature.
  7614. (encode): New function(overload).
  7615. (decode): New function(overload).
  7616. * src/Base64.cc
  7617. (part_encode): Rewritten.
  7618. (encode): Rewritten.
  7619. (encode): New function(overload).
  7620. To prevent a peer to download same piece if there is an error in
  7621. checksum:
  7622. * src/PieceMessage.cc
  7623. (receivedAction): Call peerInteraction->abortPiece().
  7624. 2006-06-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7625. To fix the bug that causes same have message is sent many times to
  7626. a single peer.
  7627. * src/Time.cc
  7628. (isNewer): Use Util::difftv().
  7629. * src/Util.cc
  7630. (difftv): Added a cast to (long long int).
  7631. * src/TorrentMan.cc
  7632. (advertisePiece): Use push_front.
  7633. (getAdvertisedPieceIndexes): A performance improvement was made.
  7634. To fix the bug that sends tracker requests without a sleep interval
  7635. when the number of connections is less than 15.
  7636. * src/TrackerWatcherCommand.cc
  7637. (execute): Now the number of connections is not a factor to decide
  7638. whether or not a tracker request should be sent or not.
  7639. * src/Time.h
  7640. (setTimeInSec): New function.
  7641. * src/Time.cc
  7642. (setTimeInSec): New function.
  7643. etc.
  7644. * src/ChokeMessage.cc
  7645. (receivedAction): Removed peer->snubbing = false
  7646. * src/PeerConnection.h
  7647. (receiveHandshake): Updated doc.
  7648. * src/TorrentMan.h
  7649. (getAdvertisedPieceIndexes): Updated the method signature.
  7650. * src/TorrentMan.cc
  7651. (getAdvertisedPieceIndexes): Updated the method signature.
  7652. * src/Time.h
  7653. (getTimeInMicros): Added a cast to (long long int).
  7654. (getTimeInMillis): Added a cast to (long long int).
  7655. * Release 0.5.2
  7656. 2006-06-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7657. To make a listening socket non-block:
  7658. * src/SocketCore.h
  7659. (setNonBlockingMode): New function.
  7660. * src/SocketCore.cc
  7661. (setNonBlockingMode): New function.
  7662. (beginListen): Added a call to setNonBlockingMode().
  7663. (acceptConnection): Call setNonBlockingMode().
  7664. (setBlockingMode): Updated.
  7665. To handle tracker's NAT-checking:
  7666. * src/PeerConnection.cc
  7667. (receiveHandshake): 'msg' param is filled with received data and
  7668. its length is assigned to 'length' param, even if all handshake
  7669. message is not yet received.
  7670. * src/PeerInteractionCommand.cc
  7671. (executeInternal): Use peerInteraction->receiveHandshake(true) when
  7672. a new peer connects to localhost.
  7673. A call to peerInteraction->sendHandshake() was removed because
  7674. it is called from peerInteraction->receiveHandshake(true).
  7675. * src/PeerInteraction.h
  7676. (quickReplied): New variable.
  7677. (receiveHandshake): Added an argument.
  7678. * src/PeerInteraction.cc
  7679. (PeerInteraction): Added the initialization of quickReplied.
  7680. (receiveHandshake): Send handshake message as soon as the info hash
  7681. in a handshake message from a peer is correct.
  7682. To change the random part of peer id and key parameter:
  7683. * src/TorrentMan.h
  7684. (key): New variable.
  7685. * src/TorrentMan.cc
  7686. (setupInternal1): Use Util::randomAlpha() to generate random part
  7687. of peer id, which is now "-aria2-"+13 alphabet characters([A-Za-z]).
  7688. key is also generated by Util::randomAlpha() and it is now 8 character
  7689. long.
  7690. * src/Util.h
  7691. (randomAlpha): New function.
  7692. * src/Util.cc
  7693. (randomAlpha): New function.
  7694. * src/TrackerWatcherCommand.cc
  7695. (execute): In a tracker request: Use torrentMan->key as key parameter.
  7696. Added no_peer_id=1.
  7697. Set snubbing flag to false when a choke message is received from a
  7698. snubbed peer.
  7699. * src/ChokeMessage.cc
  7700. (receivedAction): Set snubbing flag to false.
  7701. 2006-06-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7702. * src/TorrentMan.cc (setupInternal1): Fixed peerId generation bug.
  7703. * src/SimpleLogger.h (writeHeader): New function.
  7704. * src/SimpleLogger.cc (writeHeader): New function.
  7705. (writeLog): Fixed the bug that causes segfaults if exception message
  7706. contains an unescaped "%" character.
  7707. * src/TrackerWatcherCommand.cc (execute): Added a short sleep
  7708. when a tracker request fails.
  7709. * src/Request.cc (parseUrl): Query string is now handled properly.
  7710. * Release 0.5.1
  7711. 2006-06-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7712. To add Time class which represents a specific instant in time and
  7713. its precision is microseconds. Time checking procedures were rewritten
  7714. using this object.
  7715. * src/Time.h: New class.
  7716. * src/Time.cc: New class.
  7717. * src/AbstractCommand.h
  7718. (updateCheckPoint): Removed.
  7719. (isTimeoutDetected): Removed.
  7720. (checkPoint): Changed the type to Time.
  7721. (timeout): New variable.
  7722. (setTimeout): New function.
  7723. * src/AbstractCommand.cc
  7724. (AbstractCommand): Removed the initialization of checkPoint.
  7725. Added the initialization of timeout.
  7726. (updateCheckPoint): Removed.
  7727. (isTimeoutDetected): Removed.
  7728. (execute): Use checkPoint.reset() and checkPoint.elapsed().
  7729. * src/PeerChokeCommand.h
  7730. (checkPoint): Changed the type to Time.
  7731. * src/PeerChokeCommand.cc
  7732. (PeerChokeCommand): Removed the initialization of checkPoint.
  7733. (execute): Rewritten using Time object.
  7734. * src/TrackerWatcherCommand.h
  7735. (checkPoint): Changed the type to Time.
  7736. * src/TrackerWatcherCommand.cc
  7737. (TrackerWatcherCommand): Removed the initialization of checkPoint.
  7738. (execute): Rewritten.
  7739. * src/ConsoleDownloadEngine.h
  7740. (cp): Changed the type to Time.
  7741. (startup): Changed the type to Time.
  7742. * src/ConsoleDownloadEngine.cc
  7743. (initStatistics): Use cp.reset(), startup.reset().
  7744. (calculateStatistics): Rewritten using Time object.
  7745. * src/PeerAbstractCommand.h
  7746. (updateCheckPoint): Removed.
  7747. (isTimeoutDetected): Removed.
  7748. (checkPoint): Changed the type to Time.
  7749. * src/PeerAbstractCommand.cc
  7750. (PeerAbstractCommand): Removed the initialization of checkPoint.
  7751. (updateCheckPoint): Removed.
  7752. (isTimeoutDetected): Removed.
  7753. (execute): Use checkPoint.reset() and checkPoint.elapsed().
  7754. * src/PeerInteractionCommand.cc
  7755. (PeerInteractionCommand): Removed the initializations of struct
  7756. timeval variables.
  7757. * src/PeerInteractionCommand.h
  7758. (keepAliveCheckPoint): Changed the type to Time.
  7759. (chokeCheckPoint): Changed the type to Time.
  7760. (freqCheckPoint): Changed the type to Time.
  7761. (haveCheckTime): Changed the type to Time.
  7762. * src/PeerInteractionCommand.cc
  7763. (executeInternal): Rewritten using Time object.
  7764. (detectMessageFlooding): Rewritten using Time object.
  7765. (checkLongTimePeerChoking): Rewritten using Time object.
  7766. (sendKeepAlive): Rewritten using Time object.
  7767. (checkHave): Rewritten using Time object.
  7768. * src/SleepCommand.h
  7769. (checkPoint): Changed the type to Time.
  7770. * src/SleepCommand.cc
  7771. (SleepCommand): Removed the initialization of checkPoint.
  7772. (execute): Rewritten using Time object.
  7773. * src/TorrentAutoSaveCommand.h
  7774. (checkPoint): Changed the type to Time.
  7775. * src/TorrentAutoSaveCommand.cc
  7776. (TorrentAutoSaveCommand): Removed the initialization of checkPoint.
  7777. (execute): Rewritten.
  7778. * src/DownloadCommand.h
  7779. (sw): Changed the type to Time.
  7780. * src/DownloadCommand.cc
  7781. (DownloadCommand): Removed the initialization of sw.
  7782. (executeInternal): Rewritten.
  7783. * src/RequestSlot.h
  7784. (dispatchedTime): Changed the type to Time.
  7785. * src/RequestSlot.cc
  7786. (RequestSlot): Removed the call to setDispatchedTime().
  7787. (setDispatchedTime): Rewirtten.
  7788. (isTimeout): Rewritten.
  7789. (getLatencyInMillis): Rewritten.
  7790. * src/TorrentDownloadEngine.h
  7791. (cp): Changed the type to Time[2].
  7792. (startup): Changed the type to Time.
  7793. * src/TorrentDownloadEngine.cc
  7794. (initStatistics): Rewritten.
  7795. (calculateStatistics): Rewritten.
  7796. * src/DownloadEngine.cc
  7797. (run): Rewritten.
  7798. To detect all attempts to connect to the tracker are failed:
  7799. * src/AbstractCommand.cc
  7800. (execute): Increment e->segmentMan->errors if a command aborted.
  7801. * src/SegmentMan.h
  7802. (errors): New variable.
  7803. * src/SegmentMan.cc
  7804. (SegmentMan): Added the initialization of errors.
  7805. (init): Added the initialization of errors.
  7806. * src/TrackerWatcherCommand.cc
  7807. (execute): If e->segmentMan->errors > 0 then assume that the tracker
  7808. request was failed.
  7809. To handle snubbed peers:
  7810. * src/PeerChokeCommand.cc
  7811. (optUnchokingPeer): Snubbed peers don't get unchoked.
  7812. (execute): Snubbed peers don't get unchoked.
  7813. * src/PeerInteraction.h
  7814. (REQUEST_TIME_OUT): Changed the value from 120 to 60.
  7815. * src/PeerInteraction.cc
  7816. (checkRequestSlot): A peer get marked as "snubbed" if it doesn't send
  7817. back the requested 16k block in 60 seconds.
  7818. * src/PieceMessage.cc
  7819. (receivedAction): A peer's snubbed state is cleard if it sends
  7820. the requested 16k block in 60 seconds.
  7821. * src/Peer.h
  7822. (snubbing): New variable.
  7823. * src/Peer.cc
  7824. (resetStatus): Added snubbed = false.
  7825. To fix the bug that causes have message is not sent:
  7826. * src/PeerInteractionCommand.cc
  7827. (~PeerInteractionCommand): Removed e->torrentMan->unadvertisePiece().
  7828. (FLOODING_CHECK_INTERVAL): New definition(temporal).
  7829. (detectMessageFlooding): Use FLOODING_CHECK_INTERVAL.
  7830. * src/TorrentMan.h
  7831. (HaveEntry): New class.
  7832. (advertisePiece): Rewritten.
  7833. (getAdvertisedPieceIndexes): Rewritten.
  7834. (Haves): Changed the type.
  7835. (getAdvertisedPieceIndexes): Added an argument.
  7836. Others:
  7837. * src/TorrentMan.h
  7838. (DEFAULT_ANNOUNCE_INTERVAL): Changed the value to 1800.
  7839. (DEFAULT_ANNOUNCE_MIN_INTERVAL): Changed the value to 1800.
  7840. * src/TorrentMan.cc
  7841. (getPeer): Don't check the number of connections here.
  7842. (setupInternal1): Changed peerId.
  7843. * src/PeerInteractionCommand.h
  7844. (KEEP_ALIVE_INTERVAL): New definition.
  7845. (sendKeepAlive): Use KEEP_ALIVE_INTERVAL.
  7846. * src/main.cc
  7847. (main): SA_ONESHOT was replaced with SA_RESETHAND.
  7848. * src/DownloadEngine.h: Removed unnecessary header includes.
  7849. 2006-05-29 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7850. To fix the bug that causes segfaults if a tracker returns a zero-length
  7851. list as "peers":
  7852. * src/TrackerUpdateCommand.cc
  7853. (execute): Added a check to see wether the type of peers is Data*.
  7854. 2006-05-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7855. * Release 0.5.0
  7856. To fix compile issue with gcc3:
  7857. * src/CancelMessage.h
  7858. (ID): Renamed as ID_t
  7859. (ID_t): New enum.
  7860. * src/RejectMessage.h
  7861. (ID): Renamed as ID_t
  7862. (ID_t): New enum.
  7863. * src/SuggestPieceMessage.h
  7864. (ID): Renamed as ID_t
  7865. (ID_t): New enum.
  7866. * src/AllowedFastMessage.h
  7867. (ID): Renamed as ID_t
  7868. (ID_t): New enum.
  7869. * src/PortMessage.h
  7870. (ID): Renamed as ID_t
  7871. (ID_t): New enum.
  7872. * src/HaveNoneMessage.h
  7873. (ID): Renamed as ID_t
  7874. (ID_t): New enum.
  7875. * src/KeepAliveMessage.h
  7876. (ID): Renamed as ID_t
  7877. (ID_t): New enum.
  7878. * src/HaveAllMessage.h
  7879. (ID): Renamed as ID_t
  7880. (ID_t): New enum.
  7881. * src/UnchokeMessage.h
  7882. (ID): Renamed as ID_t
  7883. (ID_t): New enum.
  7884. * src/BitfieldMessage.h
  7885. (ID): Renamed as ID_t
  7886. (ID_t): New enum.
  7887. * src/PieceMessage.h
  7888. (ID): Renamed as ID_t
  7889. (ID_t): New enum.
  7890. * src/RequestMessage.h
  7891. (ID): Renamed as ID_t
  7892. (ID_t): New enum.
  7893. * src/NotInterestedMessage.h
  7894. (ID): Renamed as ID_t
  7895. (ID_t): New enum.
  7896. * src/ChokeMessage.h
  7897. (ID): Renamed as ID_t
  7898. (ID_t): New enum.
  7899. * src/InterestedMessage.h
  7900. (ID): Renamed as ID_t
  7901. (ID_t): New enum.
  7902. * src/HaveMessage.h
  7903. (ID): Renamed as ID_t
  7904. (ID_t): New enum.
  7905. 2006-05-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7906. * src/PeerAbstractCommand.h
  7907. (beforeSocketCheck): Removed.
  7908. * src/PeerAbstractCommand.cc
  7909. Modified in order to call executeInternal() even if socket check
  7910. and upload limit check fail.
  7911. * src/PeerInteractionCommand.h
  7912. (keepAlive): Removed.
  7913. (sendKeepAlive): New function.
  7914. (checkHave): New function.
  7915. (beforeSocketCheck): Removed.
  7916. * src/PeerInteractionCommand.cc
  7917. (executeInternal): Use peerInteraction->checkRequestSlot(). Added
  7918. calls to checkHave() and sendKeepAlive().
  7919. (keepAlive): Renamed to sendKeepAlive().
  7920. (sendKeepAlive): New function.
  7921. (beforeSocketCheck): Removed.
  7922. (checkHave): New function.
  7923. * src/BitfieldMan.cc
  7924. (getMissingIndex): Don't call getMissingIndexRandomly() if max is 0.
  7925. (getMissingUnusedIndex): Don't call getMissingIndexRandomly() if max is
  7926. 0.
  7927. (getMissingIndex): Dont't call getMissingIndexRandomly() if max is 0.
  7928. * src/TorrentMan.h
  7929. (UsedPieces): Removed.
  7930. (Pieces): New type definition.
  7931. * src/Piece.h: Updated doc.
  7932. * src/Peer.h
  7933. (totalLength): Removed.
  7934. * src/Peer.cc
  7935. (updateLatency): Fixed the latency calculation.
  7936. * src/TorrentMan.cc
  7937. (addPeer): Call deleteOldErrorPeers() only if peers.size() is higher
  7938. than or equal to MAX_PEER_LIST_SIZE.
  7939. If duplicate is false and peer.size() >= MAX_PEER_LIST_SIZE,
  7940. then return false.
  7941. (deleteOldErrorPeers): Rewritten.
  7942. (deleteUsedPiece): Fixed the miss use of STL remove.
  7943. * src/PeerInteraction.h
  7944. (Pieces): Removed.
  7945. (deleteTimeoutRequestSlot): Removed.
  7946. (deleteCompletedRequestSlot): Removed.
  7947. (checkRequestSlot): New function.
  7948. * src/PeerInteraction.cc
  7949. (deleteTimeoutRequestSlot): Merged to checkRequestSlot().
  7950. (deleteCompletedRequestSlot): Merged to checkRequestSlot().
  7951. (checkRequestSlot): New function.
  7952. * src/DownloadEngine.cc
  7953. (run): Clear activeSockets before calling waitData().
  7954. (waitData): Removed a call to activeSockets.clear().
  7955. 2006-05-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  7956. To attempt to handle EINTR:
  7957. * src/SocketCore.cc
  7958. (isReadable): Added EINTR handling.
  7959. (isWritable): Added EINTR handling.
  7960. To improve the performance:
  7961. * src/AbstractCommand.cc
  7962. (isTimeoutDetected): Use Util::difftvsec() instead of Util::difftv().
  7963. * src/PeerInteractionCommand.h
  7964. (receiveMessage): Renamed as receiveMessages().
  7965. (receiveMessages): New function.
  7966. * src/PeerInteractionCommand.cc
  7967. (executeInternal): receiveMessage loop is moved to new receiveMessages
  7968. () function. detectMessageFlooding() is moved here.
  7969. (detectMessageFlooding): Use Util::difftvsec() instead of Util::difftv
  7970. (). The flooding detection for have message is comment out.
  7971. (checkLongTimePeerChoking): Use Util::difftvsec() instead of
  7972. Util::difftv().
  7973. (receiveMessage): Renamed as receiveMessages().
  7974. (receiveMessages): New function.
  7975. (keepAlive): Use Util::difftvsec() instead of Util::difftv().
  7976. (beforeSocketCheck): Commented out checkLongTimePeerChoking().
  7977. * src/SleepCommand.cc
  7978. (execute): Use Util::difftvsec() instead of Util::difftv().
  7979. * src/BitfieldMan.h
  7980. (getNthBitIndex): New function.
  7981. (hasMissingPiece): New function.
  7982. (getAllMissingIndexes): New function.
  7983. * src/BitfieldMan.cc
  7984. (countSetBit): Rewritten.
  7985. (getNthBitIndex): New function.
  7986. (getMissingIndexRandomly): Rewritten.
  7987. (hasMissingPiece): New function.
  7988. (getAllMissingIndexes): New function.
  7989. * src/TorrentMan.cc
  7990. (hasMissingPiece): New function.
  7991. (deleteUsedPiece): Rewritten using STL.
  7992. * src/PeerInteraction.cc
  7993. (getNewPieceAndSendInterest): Use TorrentMan::hasMissingPiece(), which
  7994. is a little bit faster then TorrentMan::getMissingPieceIndex().
  7995. (addRequests): Updated the number of pending requests.
  7996. * src/PeerAbstractCommand.cc
  7997. (isTimeoutDetected): Use Util::difftvsec() instead of Util::difftv().
  7998. (execute): Returns true if TorrentMan::isHalt() is true.
  7999. Corrected the condition of upload limit checking.
  8000. * src/Util.h
  8001. (countBit): New function.
  8002. * src/Util.cc
  8003. (nbits): New variable.
  8004. (countBit): New function.
  8005. * src/DownloadEngine.h
  8006. (SockCmdMap): New type definition.
  8007. (waitData): Added an argument.
  8008. (addSocket): Added an argument.
  8009. (addSocketForReadCheck): Added an argument.
  8010. (addSocketForWriteCheck): Added an argument.
  8011. * src/DownloadEngine.cc
  8012. (run): Executes only commands whose sockets are ready to read or write.
  8013. All commands are executed in every 1 second.
  8014. (waitData): Calls select() again if it returned
  8015. EINTR.
  8016. (addSocket): Saves socket and command object pair to the map.
  8017. (deleteSocket): Deletes socket and command object pair from the map.
  8018. (addSocketForReadCheck): Added an argument.
  8019. (addSocketForWriteCheck): Added an argument.
  8020. * src/DownloadCommand.cc
  8021. (executeInternal): Use Util::difftvsec() instead of Util::difftv().
  8022. To send "event=stopped" to the tracker when the application finishes:
  8023. * src/PeerChokeCommand.h
  8024. (checkPoint): New variable.
  8025. * src/PeerChokeCommand.cc
  8026. (PeerChokeCommand): Added the initialization of checkPoint.
  8027. (execute): The interval check is now done by checkPoint, not
  8028. SleepCommand. Return true if TorrentMan::isHalt() is true.
  8029. * src/TorrentMan.h
  8030. (halt): New function.
  8031. (hasMissingPiece): New function.
  8032. (isHalt): New function.
  8033. (setHalt): New function.
  8034. * src/TorrentMan.cc
  8035. (TorrentMan): Added the initialization of halt.
  8036. * src/TorrentAutoSaveCommand.h
  8037. (checkPoint): New variable.
  8038. * src/PeerListenCommand.cc
  8039. (execute): Returns true if TorrentMan::isHalt() is true.
  8040. * src/main.cc
  8041. (setSignalHander): Added flags argument.
  8042. (torrentHandler): Just calls TorrentMan::setHalt(true) and returns.
  8043. (main): Set SA_ONESHOT flag of the signal hander of SIGINT and SIGTERM.
  8044. Removed printDownloadAbortMessage() after torrent downloading loop.
  8045. * src/TorrentAutoSaveCommand.cc
  8046. (TorrentAutoSaveCommand): Added the initialization of checkPoint.
  8047. (execute): Returns true if TorrentMan::isHalt() is true.
  8048. The interval check is now done by checkPoint, not SleepCommand.
  8049. * src/TrackerWatcherCommand.cc
  8050. (execute): If TorrentMan::isHalt(), then create a tracker request with
  8051. event=stopped.
  8052. * src/TrackerUpdateCommand.cc
  8053. (prepareForRetry): Do not use SleepCommand here.
  8054. (execute): Returns true if TorrentMan::isHalt() is true.
  8055. Others:
  8056. * src/TorrentMan.cc
  8057. (getMissingPieceIndex): Updated log message.
  8058. * src/PeerInteraction.cc
  8059. (createPeerMessag): Updated log message.
  8060. 2006-05-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  8061. To add the ability to download several pieces in mix in a command and
  8062. increase the number of request slots according to request-cancel
  8063. latency:
  8064. * src/PeerInteractionCommand.cc
  8065. (executeInternal): The number of messages to be received at a time
  8066. is increased from 10 to 50.
  8067. * src/LogFactory
  8068. (getInstance): Added NullLogger.
  8069. * src/NullLogger.h: New class.
  8070. * src/BitfieldMan.h
  8071. (getMissingIndex): New function.
  8072. * src/BitfieldMan.cc
  8073. (getMissingIndex): New function.
  8074. * src/TorrentMan.h
  8075. (checkOutPiece): New function.
  8076. (getMissingPieceIndex): New function.
  8077. (getMissingFastPieceIndex): New function.
  8078. (getMissingFastPiece): New function.
  8079. * src/TorrentMan.cc
  8080. (updatePiece): Rewritten using STL.
  8081. (syncPiece): Rewritten using STL.
  8082. (getMissingPiece): Rewritten using getMissingPieceIndex() and
  8083. checkOutPiece().
  8084. (getMissingPieceIndex): New function.
  8085. (getMissingFastPieceIndex): New function.
  8086. (getMissingFastPiece): New function.
  8087. (checkOutPiece): New function.
  8088. * src/PeerInteraction.h
  8089. (Pieces): New type definition.
  8090. (piece): Removed.
  8091. (pieces): New variable.
  8092. (getNewPieceAndSendInterest): Added the "piece" argument.
  8093. (abortPiece): Added the "piece" argument.
  8094. (abortAllPieces): New function.
  8095. (isInRequestSlot): New function.
  8096. (hasDownloadPiece): Added the "index" argument.
  8097. (setDownloadPiece): Removed.
  8098. (getDownloadPiece): Added the "index" argument.
  8099. (updatePiece): New function.
  8100. (createRequestMessage): Added the "index" argument.
  8101. * src/PeerInteraction.cc
  8102. (onChoked): Rewritten.
  8103. (abortPiece): Rewirtten.
  8104. (abortAllPieces): New function.
  8105. (deleteTimeoutRequestSlot): Rewritten.
  8106. Clarified code a little bit.
  8107. (deleteCompletedRequestSlot): Rewritten.
  8108. (isInRequestSlot): New function.
  8109. (syncPiece): Rewritten.
  8110. (updatePiece): New function.
  8111. (getNewPieceAndSendInterest): Rewritten.
  8112. (addRequests): Rewritten.
  8113. (getDownloadPiece): Rewritten.
  8114. (hasDownloadPiece): Rewritten.
  8115. (createRequestMessage): Added the "index" argument.
  8116. * src/common.h
  8117. (BITFIELD_LEN_FROM_PIECES): Enclosed the variable in parentheses.
  8118. (DIV_FLOOR): New definition.
  8119. * src/PieceMessage.cc
  8120. (receivedAction): Update request-piece latency here.
  8121. * src/RequestSlot.h
  8122. (getLatencyInMillis): New function.
  8123. * src/RequestSlot.cc
  8124. (isTimeout): Rewritten using getLatencyInMillis.
  8125. (getLatencyInMillis): New function.
  8126. * src/Piece.h
  8127. (operator==): New function.
  8128. (getMissingBlockIndex): New function.
  8129. * src/Piece.cc
  8130. (operator==): New function.
  8131. (getMissingBlockIndex): New function.
  8132. * src/Peer.h
  8133. (DEFAULT_LATENCY): New definition.
  8134. (latency): New variable.
  8135. (updateLatency): New function.
  8136. (getLatency): New function.
  8137. * src/Peer.cc
  8138. (resetStatus): Reset latecy.
  8139. (updateLatency): New function.
  8140. 2006-05-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  8141. * src/SocketCore.cc
  8142. (isReadable): Added secure to the condition.
  8143. * src/HttpConnection.cc
  8144. (receiveResponse): Fixed a bug that causes no response header
  8145. exception.
  8146. * src/Peer.h
  8147. (getFastSet): Fixed the return value type.
  8148. 2006-05-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  8149. To remove a wait from download loop:
  8150. * src/DownloadEngine.cc
  8151. (run): Comment out shortSleep.
  8152. To rewrite the message handling:
  8153. * src/SimplePeerMessage.h: New class.
  8154. * src/SimplePeerMessage.cc: New class.
  8155. * src/CancelMessage.h: Derived from SimplePeerMessage.
  8156. (msg): New variable.
  8157. (create): New function.
  8158. (send): Removed.
  8159. (getMessage): New function.
  8160. (getMessageLength): New function.
  8161. * src/CancelMessage.cc
  8162. (create): New function.
  8163. (receivedAction): Replaced deleteRequestMessageInQueue with
  8164. rejectPieceMessageInQueue.
  8165. (send): Removed.
  8166. (getMessage): New function.
  8167. (getMessageLength): New function.
  8168. * src/BitfieldMessage.h: Derived from SimplePeerMessage.
  8169. (msg): New variable.
  8170. (msgLength): New variable.
  8171. (~BitfieldMessage): Deleted msg.
  8172. (send): Removed.
  8173. (getMessage): New function.
  8174. (getMessageLength): New function.
  8175. * src/BitfieldMessage.cc
  8176. (create): New function.
  8177. (send): Removed.
  8178. (getMessage): New function.
  8179. (getMessageLength): New function.
  8180. * src/ChokeMessage.h: Derived from SimplePeerMessage.
  8181. (msg): New variable.
  8182. (sendPredicate): New function.
  8183. (onSendComplete): New function.
  8184. (send): Removed.
  8185. (getMessage): New function.
  8186. (getMessageLength): New function.
  8187. (create): New function.
  8188. * src/ChokeMessage.cc
  8189. (create): New function.
  8190. (send): Removed.
  8191. (sendPredicate): New function.
  8192. (getMessage): New function.
  8193. (getMessageLength): New function.
  8194. (onSendComplete): New function.
  8195. * src/KeepAliveMessage.h: Derived from SimplePeerMessage.
  8196. (msg): New variable.
  8197. (send): Removed.
  8198. (getMessage): New function.
  8199. (getMessageLength): New function.
  8200. * src/KeepAliveMessage.cc
  8201. (send): Removed.
  8202. (getMessage): New function.
  8203. (getMessageLength): New function.
  8204. * src/PortMessage.h
  8205. (create): New function.
  8206. (receivedAction): Updated log message.
  8207. * src/PortMessage.cc: New file.
  8208. * src/UnchokeMessage.h: Derived from SimplePeerMessage.
  8209. (msg): New variable.
  8210. (sendPredicate): New function.
  8211. (onSendComplete): New function.
  8212. (create): New function.
  8213. (send): Removed.
  8214. (getMessage): New function.
  8215. (getMessageLength): New function.
  8216. * src/UnchokeMessage.cc
  8217. (create): New function.
  8218. (send): Removed.
  8219. (sendPredicate): New function.
  8220. (getMessage): New function.
  8221. (getMessageLength): New function.
  8222. (onSendComplete): New function.
  8223. * src/PieceMessage.h
  8224. (leftPieceDataLength): Removed.
  8225. (leftDataLength): New variable.
  8226. (headerSend): New variable.
  8227. (pendingCount): New variable.
  8228. (msgHeader): New variable.
  8229. (sendPieceData): New function.
  8230. (incrementPendingCount): New function.
  8231. (isPendingCountMax): New function.
  8232. (create): New function.
  8233. (getMessageHeader): New function.
  8234. (getMessageHeaderLength): New function.
  8235. * src/PieceMessage.cc
  8236. (create): New function.
  8237. (getMessageHeader): New function.
  8238. (getMessageHeaderLength): New function.
  8239. (send): Rewritten.
  8240. (sendPieceData): New function.
  8241. * src/HaveMessage.h: Derived from SimplePeerMessage.
  8242. (msg): New variable.
  8243. (create): New function.
  8244. (getMessage): New function.
  8245. (getMessageLength): New function.
  8246. * src/HaveMessage.cc
  8247. (create): New function.
  8248. (send): Removed.
  8249. (sendPieceData): New function.
  8250. (getMessage): New function.
  8251. (getMessageLength): New function.
  8252. * src/RequestMessage.h: Derived from SimplePeerMessage.
  8253. (msg): New variable.
  8254. (create): New function.
  8255. (send): Removed.
  8256. (getMessage): New function.
  8257. (getMessageLength): New function.
  8258. * src/RequestMessage.cc
  8259. (create): New function.
  8260. (receivedAction): Added the handling of fast extension.
  8261. Deleted torrentMan->addUploadLength, torrentMan->addDeltaUploadLength.
  8262. (send): Removed.
  8263. (getMessage): New function.
  8264. (getMessageLength): New function.
  8265. * src/InterestedMessage.h: Derived from SimplePeerMessage.
  8266. (msg): New variable.
  8267. (sendPredicate): New function.
  8268. (onSendComplete): New function.
  8269. (create): New function.
  8270. (getMessage): New function.
  8271. (getMessageLength): New function.
  8272. * src/InterestedMessage.cc
  8273. (create): New function.
  8274. (send): Removed.
  8275. (sendPieceData): New function.
  8276. (getMessage): New function.
  8277. (getMessageLength): New function.
  8278. (onSendComplete): New function.
  8279. * src/NotInterestedMessage.h: Derived from SimplePeerMessage.
  8280. (msg): New variable.
  8281. (sendPieceData): New function.
  8282. (onSendComplete): New function.
  8283. (create): New function.
  8284. (send): Removed.
  8285. (getMessage): New function.
  8286. (getMessageLength): New function.
  8287. * src/NotInterestedMessage.cc
  8288. (create): New function.
  8289. (send): Removed.
  8290. (sendPredicate): New function.
  8291. (getMessage): New function.
  8292. (getMessageLength): New function.
  8293. (onSendComplete): New function.
  8294. * src/AllowedFastMessage.h: New class.
  8295. * src/AllowedFastMessage.cc: New class.
  8296. * src/RejectMessage.h: New class.
  8297. * src/RejectMessage.cc: New class.
  8298. * src/SuggestPieceMessage.h: New class.
  8299. * src/SuggestPieceMessage.cc: New class.
  8300. * src/HaveAllMessage.h: New class.
  8301. * src/HaveAllMessage.cc: New class.
  8302. * src/HaveNoneMessage.h: New class.
  8303. * src/HaveNoneMessage.cc: New class.
  8304. * src/HandshakeMessage.h: Derived from SimplePeerMessage.
  8305. (msg): New variable.
  8306. (reserved): New variable.
  8307. (create): New function.
  8308. (getId): New function.
  8309. (receivedAction): New function.
  8310. (getMessage): New function.
  8311. (getMessageLength): New function.
  8312. (isFastExtensionSupported): New function.
  8313. * src/HandshakeMessage.cc
  8314. (HandshakeMessage): Moved here from HandshakeMessage.h.
  8315. (create): New function.
  8316. (getMessage): New function.
  8317. (getMessageLength): New function.
  8318. (toString): Added the output of reserved field.
  8319. (check): Added const qualifier.
  8320. (isFastExtensionSupported): New function.
  8321. * src/PeerMessageUtil.h
  8322. (createChokeMessage): Removed.
  8323. (createUnchokeMessage): Removed.
  8324. (createInterestedMessage): Removed.
  8325. (createNotInterestedMessage): Removed.
  8326. (createHaveMessage): Removed.
  8327. (createBitfieldMessage): Removed.
  8328. (createRequestMessage): Removed.
  8329. (createCancelMessage): Removed.
  8330. (createPieceMessage): Removed.
  8331. (createPortMessage): Removed.
  8332. (createChokeMessage): Removed.
  8333. (createUnchokeMessage): Removed.
  8334. (createInterestedMessage): Removed.
  8335. (createNotInterestedMessage): Removed.
  8336. (createHaveMessage): Removed.
  8337. (createBitfieldMessage): Removed.
  8338. (createRequestMessage): Removed.
  8339. (createCancelMessage): Removed.
  8340. (createPieceMessage): Removed.
  8341. (createKeepAliveMessage): Removed.
  8342. (createHandshakeMessage): Removed.
  8343. (setIntParam): New function.
  8344. (createPeerMessageString): New function.
  8345. * src/PeerMessageUtil.cc
  8346. (createChokeMessage): Removed.
  8347. (createUnchokeMessage): Removed.
  8348. (createInterestedMessage): Removed.
  8349. (createNotInterestedMessage): Removed.
  8350. (createHaveMessage): Removed.
  8351. (createBitfieldMessage): Removed.
  8352. (createRequestMessage): Removed.
  8353. (createCancelMessage): Removed.
  8354. (createPieceMessage): Removed.
  8355. (createPortMessage): Removed.
  8356. (createRequestMessage): Removed.
  8357. (createCancelMessage): Removed.
  8358. (createPieceMessage): Removed.
  8359. (createHaveMessage): Removed.
  8360. (createChokeMessage): Removed.
  8361. (createUnchokeMessage): Removed.
  8362. (createInterestedMessage): Removed.
  8363. (createNotInterestedMessage): Removed.
  8364. (createBitfieldMessage): Removed.
  8365. (createKeepAliveMessage): Removed.
  8366. (createHandshakeMessage): Removed.
  8367. (setIntParam): New function.
  8368. (createPeerMessageString): New function.
  8369. * src/PeerConnection.h
  8370. (peer): Removed.
  8371. (torrentMan): Removed.
  8372. (createNLengthMessage): Removed.
  8373. (setIntParam): Removed.
  8374. (writeOutgoingMessageLog): Removed all overloaded functions.
  8375. (PeerConnection): Deleted peer and torrentMan from its arguments.
  8376. (sendMessage): New function.
  8377. (sendHandshake): Removed.
  8378. (sendKeepAlive): Removed.
  8379. (sendChoke): Removed.
  8380. (sendUnchoke): Removed.
  8381. (sendInterested): Removed.
  8382. (sendNotInterested): Removed.
  8383. (sendHave): Removed.
  8384. (sendBitfield): Removed.
  8385. (sendRequest): Removed.
  8386. (sendPiece): Removed.
  8387. (sendPieceHeader): Removed.
  8388. (sendPieceData): Removed.
  8389. (sendCancel): Removed.
  8390. (getPeer): Removed.
  8391. * src/PeerConnection.cc
  8392. (PeerConnection): Deleted peer and torrentMan from its arguments.
  8393. (sendHandshake): Removed.
  8394. (sendKeepAlive): Removed.
  8395. (createNLengthMessage): Removed.
  8396. (setIntParam): Removed.
  8397. (writeOutgoingMessageLog): Removed all overloaded functions.
  8398. (sendChoke): Removed.
  8399. (sendUnchoke): Removed.
  8400. (sendInterested): Removed.
  8401. (sendNotInterested): Removed.
  8402. (sendHave): Removed.
  8403. (sendBitfield): Removed.
  8404. (sendRequest): Removed.
  8405. (sendPiece): Removed.
  8406. (sendPieceHeader): Removed.
  8407. (sendPieceData): Removed.
  8408. (sendMessage): New function.
  8409. (sendCancel): Removed.
  8410. * src/PeerInteractionCommand.cc
  8411. (PeerInteractionCommand): Call setUploadLimit.
  8412. (executeInternal): Call setUploadLimit.
  8413. Added the handling of "inProgress" state of handshake message.
  8414. Call sendBitfield() or sendAllowdFast() instead of deprecated
  8415. sendNow().
  8416. (keepAlive): Call addMessage and sendMessage instead of deprecated
  8417. sendNow().
  8418. (beforeSocketCheck): Call addMessage instead of deprecated trySendNow()
  8419. * src/TorrentMan.h
  8420. (PEER_ID_LENGTH): New definition.
  8421. (hasAllPieces): New function.
  8422. * src/TorrentMan.cc
  8423. (getMissingPiece): Added the handling of fast extension.
  8424. (cancelPiece): Call updatePiece().
  8425. (hasAllPieces): New function.
  8426. * src/PeerInteraction.h
  8427. (fastSet): New variable.
  8428. (getNewPieceAndSendInterest): Changed the return type to void.
  8429. (send): Renamed as sendMessages.
  8430. (deleteAllRequestSlot): Removed.
  8431. (deleteRequestMessageInQueue): Renamed as rejectPieceMessageInQueue.
  8432. (cancelAllRequest): Removed all overloaded functions.
  8433. (deleteAllRequestSlot): Removed.
  8434. (deletePieceMessageInQueue): Renamed as rejectAllPieceMessageInQueue.
  8435. (rejectPieceMessageInQueue): New function.
  8436. (rejectAllPieceMessageInQueue): New function.
  8437. (onChoked): New function.
  8438. (isSendingMessageInProgress): New function.
  8439. (getCorrespondingRequestSlot): Changed its arguments.
  8440. (isInFastSet): New function.
  8441. (addFastSetIndex): New function.
  8442. (addRequests): New function.
  8443. (sendNow): Removed.
  8444. (trySendNow): Removed.
  8445. (sendBitfield): New function.
  8446. (sendAllowdFast): New function.
  8447. (createHaveAllMessage): New function.
  8448. (createHaveNoneMessage): New function.
  8449. (createRejectMessage): New function.
  8450. (createAllowedFastMessage): New function.
  8451. * src/PeerInteraction.cc
  8452. (send): Renamed as sendMessages.
  8453. (sendMessages): New function.
  8454. (MsgPushBack): New class.
  8455. (isSendingMessageInProgress): New function.
  8456. (deletePieceMessageInQueue): Renamed as rejectAllPieceMessageInQueue.
  8457. (rejectAllPieceMessageInQueue): New function.
  8458. Added the handling of fast extension.
  8459. (deleteRequestMessageInQueue): Renamed as rejectPieceMessageInQueue.
  8460. (rejectPieceMessageInQueue): New function.
  8461. Added the handling of fast extension.
  8462. (deleteRequestSlot): Replaced for loop with std::find.
  8463. (onChoked): New function.
  8464. (deleteAllRequestSlot): Removed.
  8465. (abortPiece): Rewirtten.
  8466. (deleteTimeoutRequestSlot): Updated log messages.
  8467. (getCorrespondingRequestSlot): Changed its arguments.
  8468. (cancelAllRequest): Removed all overloaded functions.
  8469. (receiveHandshake): Added the check to see whether an incoming peer
  8470. supports fast extension.
  8471. (createHandshakeMessage): Use HandshakeMessage::create instead of
  8472. PeerMessageUtil.
  8473. (createPeerMessage): Use create() of each message class instead of
  8474. PeerMessageUtil.
  8475. HaveAllMessage, HaveNoneMessage, RejectMessage, SuggestPieceMessage,
  8476. AllowedFastMessage were added.
  8477. (getNewPieceAndSendInterest): Changed its return value type to void.
  8478. Added the handling of fast extension.
  8479. (addRequests): New function.
  8480. (sendNow): Removed.
  8481. (sendHandshake): Rewritten.
  8482. (trySendNow): Removed.
  8483. (sendBitfield): New function.
  8484. (sendAllowdFast): New function.
  8485. (isInFastSet): New function.
  8486. (addFastSetIndex): New function.
  8487. (createRequestMessage): Use RequestMessage::create instead of
  8488. PeerMessageUtil.
  8489. (createCancelMessage): Use CancelMessage::create instead of
  8490. PeerMessageUtil.
  8491. (createPieceMessage): Use PieceMessage::create instead of
  8492. PeerMessageUtil.
  8493. (createHaveMessage): Use HaveMessage::create instead of
  8494. PeerMessageUtil.
  8495. (createChokeMessage): Use ChokeMessage::create instead of
  8496. PeerMessageUtil.
  8497. (createUnchokeMessage): Use UnchokeMessage::create instead of
  8498. PeerMessageUtil.
  8499. (createInterestedMessage): Use InterestedMessage::create instead of
  8500. PeerMessageUtil.
  8501. (createNotInterestedMessage): Use NotInterestedMessage::create instead
  8502. of PeerMessageUtil.
  8503. (createBitfieldMessage): Use BitfieldMessage::create instead of
  8504. PeerMessageUtil.
  8505. (createKeepAliveMessage): Use KeepAliveMessage::create instead of
  8506. PeerMessageUtil.
  8507. (createHaveAllMessage): New function.
  8508. (createHaveNoneMessage): New function.
  8509. (createRejectMessage): New function.
  8510. (createAllowedFastMessage: New function.
  8511. * src/Util.h
  8512. (sha1Sum): New function.
  8513. (computeFastSet): New function.
  8514. * src/Util.cc
  8515. (sha1Sum): New function.
  8516. (computeFastSet): New function.
  8517. * src/Peer.h
  8518. (fastExtensionEnabled): New variable.
  8519. (fastSet): New variable.
  8520. (setAllBitfield): New function.
  8521. (setFastExtensionEnabled): New function.
  8522. (isFastExtensionEnabled): New function.
  8523. (addFastSetIndex): New function.
  8524. (getFastSet): New function.
  8525. (isInFastSet): New function.
  8526. (countFastSet): New function.
  8527. * src/Peer.cc
  8528. (isInFastSet): New function.
  8529. (addFastSetIndex): New function.
  8530. (setAllBitfield): New function.
  8531. * src/AbstractCommand.cc (execute): Changed the procedure of checking
  8532. sockets.
  8533. * src/PeerAbstractCommand.cc
  8534. (PeerAbstractCommand): Added the initialization for uploadLimitCheck
  8535. and uploadLimit.
  8536. (execute): Changed the procedure of checking sockets. The upload speed
  8537. checking were added.
  8538. (setUploadLimit): New function.
  8539. (setUploadLimitCheck): New function.
  8540. * src/PeerAbstractCommand.h
  8541. (setUploadLimit): New function.
  8542. (setUploadLimitCheck): New function.
  8543. (uploadLimit): New variable.
  8544. (uploadLimitCheck): New variable.
  8545. To contact a tracker regularly:
  8546. * src/TrackerWatcherCommand.h (interval): New variable.
  8547. (checkPoint): New variable.
  8548. (TrackerWatcherCommand): Added interval argument.
  8549. * src/TrackerWatcherCommand.cc
  8550. (TrackerWatcherCommand): Initialized checkPoint.
  8551. (execute): Now a tracker is contacted in every specified period.
  8552. If peer list is not needed, send request with numwant=0.
  8553. * src/TrackerUpdateCommand.cc
  8554. (execute): Updated log messages.
  8555. * src/DownloadEngine.cc
  8556. (~DownloadEngine): Removed two asserts.
  8557. (waitData): Uncommented wfds. May be a bug fix.
  8558. 2006-05-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  8559. * src/PeerInteractionCommand.h
  8560. (checkInactiveConnection): Removed.
  8561. * src/PeerInteractionCommand.cc
  8562. (executeInternal): Removed following function calls:
  8563. detectMessageFlooding(), checkLongTimePeerChoking and
  8564. checkInactiveConnection().
  8565. (checkInactiveConnection): Removed.
  8566. (detectMessageFlooding): Removed function call to
  8567. checkInactiveConnection().
  8568. * src/PeerMessageUtil.h
  8569. (createChokeMessage): New function. Overload.
  8570. (createUnchokeMessage): New function. Overload.
  8571. (createInterestedMessage): New function. Overload.
  8572. (createNotInterestedMessage): New function. Overload.
  8573. (createHaveMessage): New function. Overload.
  8574. (createBitfieldMessage): New function. Overload.
  8575. (createRequestMessage): New function. Overload.
  8576. (createCancelMessage): New function. Overload.
  8577. (createPieceMessage): New function. Overload.
  8578. (createKeepAliveMessage): New function. Overload.
  8579. * src/PeerMessageUtil.cc
  8580. (createChokeMessage): New function. Overload.
  8581. (createUnchokeMessage): New function. Overload.
  8582. (createInterestedMessage): New function. Overload.
  8583. (createNotInterestedMessage): New function. Overload.
  8584. (createHaveMessage): New function. Overload.
  8585. (createBitfieldMessage): New function. Overload.
  8586. (createRequestMessage): New function. Overload.
  8587. (createCancelMessage): New function. Overload.
  8588. (createPieceMessage): New function. Overload.
  8589. (createKeepAliveMessage): New function. Overload.
  8590. * src/SendMessageQueue.cc
  8591. (createRequestMessage): Use PeerMessageUtil.
  8592. (createCancelMessage): Use PeerMessageUtil.
  8593. (createPieceMessage): Use PeerMessageUtil.
  8594. (createHaveMessage): Use PeerMessageUtil.
  8595. (createChokeMessage): Use PeerMessageUtil.
  8596. (createUnchokeMessage): Use PeerMessageUtil.
  8597. (createInterestedMessage): Use PeerMessageUtil.
  8598. (createNotInterestedMessage): Use PeerMessageUtil.
  8599. (createBitfieldMessage): Use PeerMessageUtil.
  8600. (createKeepAliveMessage): Use PeerMessageUtil.
  8601. * src/SendMessageQueue.h: Renamed to PeerInteraction.h
  8602. * src/SendMessageQueue.cc: Renamed to PeerInteraction.cc
  8603. * src/PeerInteraction.h: New class.
  8604. * src/PeerInteraction.cc: New class.
  8605. 2006-05-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  8606. Each peer message has its own class.
  8607. * src/PendingMessages.h: Removed.
  8608. * src/PendingMessages.cc: Removed. The sending process was moved to
  8609. each message class.
  8610. * src/RequestSlotMan.h: Removed.
  8611. * src/RequestSlotMan.cc: Removed. All functionarities were moved to
  8612. SendMessageQueue.
  8613. * src/RequestMessage.h: New class.
  8614. * src/RequestMessage.cc: New class.
  8615. * src/CancelMessage.h: New class.
  8616. * src/CancelMessage.cc: New class.
  8617. * src/BitfieldMessage.h: New class.
  8618. * src/BitfieldMessage.cc: New class.
  8619. * src/ChokeMessage.h: New class.
  8620. * src/ChokeMessage.cc: New class.
  8621. * src/KeepAliveMessage.h: New class.
  8622. * src/KeepAliveMessage.cc: New class.
  8623. * src/PortMessage.h: New class.
  8624. * src/UnchokeMessage.h: New class.
  8625. * src/UnchokeMessage.cc: New class.
  8626. * src/PieceMessage.h: New class.
  8627. * src/PieceMessage.cc: New class.
  8628. * src/HaveMessage.h: New class.
  8629. * src/HaveMessage.cc: New class.
  8630. * src/BitfieldMessage.h: New class.
  8631. * src/BitfieldMessage.cc: New class.
  8632. * src/NotInterestedMessage.h: New class.
  8633. * src/NotInterestedMessage.cc: New class.
  8634. * src/InterestedMessage.h: New class.
  8635. * src/InterestedMessage.cc: New class.
  8636. * src/HandshakeMessage.h (sendMessageQueue): New variable.
  8637. (getSendMessageQueue): New function.
  8638. (setSendMessageQueue): New function.
  8639. * src/HandshakeMessage.cc: New class.
  8640. * src/PeerConnection.h (receiveMessage): Changed return value and
  8641. arguments.
  8642. (receiveHandshake): Changed return value and arguments.
  8643. * src/PeerConnection.cc (receiveMessage): Do not create message class
  8644. here.
  8645. (receiveHandshake): Do not create handshake class here.
  8646. * src/PeerInteractionCommand.h (peerConnection): Removed.
  8647. (piece): Removed.
  8648. (syncPiece): Removed.
  8649. (sendInterest): Removed.
  8650. (sendMessages): Removed.
  8651. (createRequestPendingMessage): Removed.
  8652. (checkPieceHash): Removed.
  8653. (erasePieceOnDisk): Removed.
  8654. (getNewPieceAndSendInterest): Removed.
  8655. (onGotNewPice): Removed.
  8656. (onGotWrongPiece): Removed.
  8657. * src/PeerInteractionCommand.cc (PeerInteractionCommand):
  8658. Removed peerConnection, piece.
  8659. (~PeerInteractionCommand): Removed peerConnection.
  8660. (executeInternal): Use sendMessageQueue instead of peerConnection.
  8661. (syncPiece): Moved to SendMessageQueue.
  8662. (decideChoking): Removed PendingMessage.
  8663. (receiveMessage): Use sendMessageQueue instead of peerConnection.
  8664. The action after receiving peer message was moved to each message
  8665. class.
  8666. (onGotNewPice): Moved to SendMessageQueue.
  8667. (onGotWrongPiece): Moved to SendMessageQueue.
  8668. (getNewPieceAndSendInterest): Moved to SendMessageQueue.
  8669. (sendInterest): Moved to SendMessageQueue.
  8670. (createRequestPendingMessage): Removed.
  8671. (sendMessages): Moved to SendMessageQueue.
  8672. (onAbort): Use SendMessageQueue::abortPiece()
  8673. (keepAlive): Use sendMessageQueue instead of peerConnection.
  8674. (beforeSocketCheck): Use sendMessageQueue instead of peerConnection.
  8675. (checkPieceHash): Moved to SendMessageQueue.
  8676. (erasePieceOnDisk): Moved to SendMessageQueue.
  8677. * src/PeerMessageUtil.h
  8678. (createBitfieldMessage): Removed.
  8679. (createHaveMessage): Changed return value and arguments.
  8680. (createBitfieldMessage): Changed return value and arguments.
  8681. (createRequestCancelMessage): Removed.
  8682. (createPieceMessage): Changed return value and arguments.
  8683. (getShortIntParam): New function.
  8684. (checkIndex): Changed arguments.
  8685. (checkBegin): Changed arguments.
  8686. (checkLength): Changed arguments.
  8687. (checkPieceOffset): Removed.
  8688. (checkRange): New function.
  8689. (checkBitfield): Changed arguments.
  8690. (createPeerMessage): Removed.
  8691. (checkIntegrity): Removed.
  8692. (createHandshakeMessage): Changed arguments.
  8693. (createChokeMessage): New function.
  8694. (createUnchokeMessage): New function.
  8695. (createInterestedMessage): New function.
  8696. (createNotInterestedMessage): New function.
  8697. (createRequestMessage): New function.
  8698. (createCancelMessage): New function.
  8699. (createPortMessage): New function.
  8700. * src/PeerMessageUtil.cc
  8701. (createBitfieldMessage): Removed.
  8702. (createHaveMessage): Changed return value and arguments.
  8703. (createBitfieldMessage): Changed return value and arguments.
  8704. (createRequestCancelMessage): Removed.
  8705. (createPieceMessage): Changed return value and arguments.
  8706. (getShortIntParam): New function.
  8707. (checkIndex): Changed arguments.
  8708. (checkBegin): Changed arguments.
  8709. (checkLength): Changed arguments.
  8710. (checkPieceOffset): Removed.
  8711. (checkRange): New function.
  8712. (checkBitfield): Changed arguments.
  8713. (createPeerMessage): Removed.
  8714. (checkIntegrity): Removed.
  8715. (createHandshakeMessage): Changed arguments.
  8716. (createChokeMessage): New function.
  8717. (createUnchokeMessage): New function.
  8718. (createInterestedMessage): New function.
  8719. (createNotInterestedMessage): New function.
  8720. (createRequestMessage): New function.
  8721. (createCancelMessage): New function.
  8722. (createPortMessage): New function.
  8723. * src/PeerMessage.h
  8724. (id): Removed.
  8725. (index): Removed.
  8726. (begin): Removed.
  8727. (length): Removed.
  8728. (bitfield): Removed.
  8729. (bitfieldLength): Removed.
  8730. (block): Removed.
  8731. (blockLength): Removed.
  8732. (inProgress): New variable.
  8733. (cuid): New variable.
  8734. (peer): New variable.
  8735. (sendMessageQueue): New variable.
  8736. (logger): New variable.
  8737. (setBitfield): Removed.
  8738. (getBitfield): Removed.
  8739. (setBlock): Removed.
  8740. (getBlock): Removed.
  8741. (getBitfieldLength): Removed.
  8742. (getBlockLength): Removed.
  8743. (isInProgress): New function.
  8744. (toString): Made pure virtual.
  8745. (check): New function.
  8746. (send): New function.
  8747. (receivedAction): New function.
  8748. (getId): Made pure virtual.
  8749. (setId): Removed.
  8750. (getIndex): Removed.
  8751. (setIndex): Removed.
  8752. (getBegin): Removed.
  8753. (setBegin): Removed.
  8754. (getLength): Removed.
  8755. (setLength): Removed.
  8756. (getCuid): New function.
  8757. (setCuid): New function.
  8758. (getPeer): New function.
  8759. (setPeer): New function.
  8760. (getSendMessageQueue): New function.
  8761. (setSendMessageQueue): New function.
  8762. (ID): Removed.
  8763. * src/PeerMessage.cc
  8764. (setBitfield): Removed.
  8765. (setBlock): Removed.
  8766. (toString): Removed.
  8767. * src/TorrentMan.h
  8768. (getPieceLength): New function.
  8769. (getPieceLength): New function.
  8770. * src/SendMessageQueue.h
  8771. (REQUEST_TIME_OUT): New definition.
  8772. (RequestSlots): New definition.
  8773. (MessageQueue): New definition.
  8774. (requestSlotMan): Removed.
  8775. (pendingMessages): Removed.
  8776. (requestSlots): New variable.
  8777. (messageQueue): New variable.
  8778. (torrentMan): New variable.
  8779. (peerConnection): New variable.
  8780. (peer): New variable.
  8781. (piece): New variable.
  8782. (getNewPieceAndSendInterest): New function.
  8783. (createPeerMessage): New function.
  8784. (createHandshakeMessage): New function.
  8785. (send): Made private.
  8786. (setPeerMessageCommonProperty): New function.
  8787. (deleteAllRequestSlot): New function.
  8788. (deleteRequestMessageInQueue): New function.
  8789. (cancelAllRequest): Made private.
  8790. (cancelAllRequest): Made private.
  8791. (countRequestSlot): Made private.
  8792. (addPendingMessage): Removed.
  8793. (deletePendingPieceMessage): Removed.
  8794. (deletePendingRequestMessage): Removed.
  8795. (addMessage): New function.
  8796. (deletePieceMessageInQueue): New function.
  8797. (deleteTimeoutRequestSlot): Changed argument.
  8798. (deleteCompletedRequestSlot): Changed argument.
  8799. (getCorrespoindingRequestSlot): Renamed to getCorrespondingRequestSlot.
  8800. (getCorrespondingRequestSlot): New function.
  8801. (countPendingMessage): Removed.
  8802. (countMessageInQueue): New function.
  8803. (getTorrentMan): New function.
  8804. (getPeerConnection): New function.
  8805. (hasDownloadPiece): New function.
  8806. (getDownloadPiece): New function.
  8807. (setDownloadPiece): New function.
  8808. (syncPiece): New function.
  8809. (sendMessages): New function.
  8810. (sendNow): New function.
  8811. (trySendNow): New function.
  8812. (abortPiece): New function.
  8813. (sendHandshake): New function.
  8814. (receiveMessage): New function.
  8815. (receiveHandshake): New function.
  8816. (createRequestMessage): New function.
  8817. (createCancelMessage): New function.
  8818. (createPieceMessage): New function.
  8819. (createHaveMessage): New function.
  8820. (createChokeMessage): New function.
  8821. (createUnchokeMessage): New function.
  8822. (createInterestedMessage): New function.
  8823. (createNotInterestedMessage): New function.
  8824. (createBitfieldMessage): New function.
  8825. (createKeepAliveMessage): New function.
  8826. * src/SendMessageQueue.cc
  8827. (SendMessageQueue): Removed requestSlotMan.
  8828. Instantiated peerConnection here.
  8829. (~SendMessageQueue): Removed requestSlotMan.
  8830. Added deletion of peerConnection and the contents of messageQueue.
  8831. (send): Updated according to the change of messageQueue.
  8832. (addPendingMessage): Renamed to addMessage.
  8833. (addMessage): New function.
  8834. (deletePendingPieceMessage): Renamed to deletePieceMessageInQueue.
  8835. (deletePieceMessageInQueue): New function.
  8836. (deletePendingRequestMessage): Renamed to deleteRequestMessageInQueue.
  8837. (deleteRequestMessageInQueue): New function.
  8838. (deleteRequestSlot): RequestSlotMan::deleteRequestSlot(...) was moved
  8839. here.
  8840. (deleteTimeoutRequestSlot): RequestSlotMan::deleteTimeoutRequestSlot
  8841. (...) was moved here.
  8842. (deleteAllRequestSlot): RequestSlotMan::deleteAllRequestSlot(...) was
  8843. moved here.
  8844. (deleteCompletedRequestSlot):
  8845. RequestSlotMan::deleteCompletedRequestSlot(...) was moved here.
  8846. (getCorrespondingRequestSlot):
  8847. RequestSlotMan::getCorrespoindingRequestSlot(...) was moved here.
  8848. And renamed to getCorrespondingRequestSlot, correcting a typo.
  8849. (countPendingMessage): Renamed to countMessageInQueue.
  8850. (countMessageInQueue): New function.
  8851. (countRequestSlot): RequestSlotMan::countRequestSlot() was moved here.
  8852. (receiveHandshake): New function.
  8853. (createHandshakeMessage): New function.
  8854. (receiveMessage): New function.
  8855. (createPeerMessage): New function.
  8856. (syncPiece): New function.
  8857. (getNewPieceAndSendInterest): New function.
  8858. (sendMessages): New function.
  8859. (sendNow): New function.
  8860. (trySendNow): New function.
  8861. (sendHandshake): New function.
  8862. (abortPiece): New function.
  8863. (getDownloadPiece): New function.
  8864. (getPeerMessageCommonProperty): New function.
  8865. (createRequestMessage): New function.
  8866. (createCancelMessage): New function.
  8867. (createPieceMessage): New function.
  8868. (createHaveMessage): New function.
  8869. (createChokeMessage): New function.
  8870. (createUnchokeMessage): New function.
  8871. (createInterestedMessage): New function.
  8872. (createNotInterestedMessage): New function.
  8873. (createBitfieldMessage): New function.
  8874. (createKeepAliveMessage): New function.
  8875. To add simple Content-Disposition support:
  8876. * src/HttpResponseCommand.h (determinFilename): New function.
  8877. * src/HttpResponseCommand.cc (executeInternal):
  8878. Use determinFilename(headers) instead of req->getFile() when comparing
  8879. filename.
  8880. (determinFilename): New function.
  8881. (handleDefaultEncoding): Use determinFilename(headers) instead of
  8882. req->getFile().
  8883. (handleOtherEncoding): Use determinFilename(headers) instead of
  8884. req->getFile().
  8885. * src/Util.h (getContentDispositionFilename): New function.
  8886. * src/Util.cc (getContentDispositionFilename): New function.
  8887. * src/LogFactory.h (release): New function.
  8888. * src/LogFactory.cc (release): New function.
  8889. To fix a bug that causes out-of-bound exception when HTTP status
  8890. line is wrong:
  8891. * src/HttpConnection.cc (receiveResponse): Added a check for header
  8892. size.
  8893. * src/common.h (Deleter): New class.
  8894. * src/SegmentMan.cc
  8895. (~SegmentMan): Added deletion of splitter and diskWriter.
  8896. * src/DownloadEngine.h
  8897. (Commands): Use deque.
  8898. (clearQueue): New function.
  8899. * src/DownloadEngine.cc
  8900. (~DownloadEngine): Added deletion of segmentMan.
  8901. (cleanQueue): New function.
  8902. * src/TorrentDownloadEngine.h
  8903. (TorrentDownloadEngine): The implementation was moved to
  8904. TorrentDownloadEngine.cc.
  8905. (~TorrentDownloadEngine): The implementation was moved to
  8906. TorrentDownloadEngine.cc.
  8907. * src/TorrentDownloadEngine.cc
  8908. (~TorrentDownloadEngine): Added deletion of torrentMan.
  8909. * src/main.cc
  8910. (clearRequest): Removed.
  8911. (handler): Added deletion of e.
  8912. (torrentHandler): Added deletion of te.
  8913. (main): Do not share splitter.
  8914. Use Deleter instead of clearRequest.
  8915. Deletion of classes were updated.
  8916. 2006-05-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  8917. * src/main.cc (main): Fixed typo.
  8918. * src/message.h: Fixed typo.
  8919. * po/de.po: Added German translation, thanks to Hermann J. Beckers.
  8920. 2006-04-29 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  8921. To add --select-file command-line option:
  8922. * src/Util.cc
  8923. (unfoldRange): New function.
  8924. (getNum): New function.
  8925. (unfoldSubRange): New function
  8926. * src/main.cc
  8927. (showUsage): Added help message.
  8928. (main): Added --select-file command-line option. Updated the layout of
  8929. file listing.
  8930. * src/common.h
  8931. (Integers): New definition.
  8932. * src/SocketCore.cc
  8933. (writeData): Removed timeout argument.
  8934. (readData): Removed timeout argument.
  8935. (peekData): Removed timeout argument.
  8936. * src/Socket.cc
  8937. (writeData): Removed timeout argument.
  8938. (readData): Removed timeout argument.
  8939. (peekData): Removed timeout argument.
  8940. * Release 0.4.1
  8941. 2006-04-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  8942. To deploy upload rate based choking algorithm:
  8943. * src/PeerInteractionCommand.cc
  8944. (PeerInteractionCommand): Add peer to TorrentMan::activePeers to track
  8945. peer currently used.
  8946. (decideChoking): Deleted the choke/unchoke decision algorithm when
  8947. download completes. Simplified.
  8948. (receiveMessage): Updated.
  8949. * src/TorrentMan.h
  8950. (activePeers): New variable.
  8951. (addActivePeer): New function.
  8952. (getActivePeers): New function.
  8953. (deleteActivePeer): New function.
  8954. * src/TorrentMan.cc
  8955. (addPeer): deleteOldErrorPeers is moved to the begining of the function
  8956. * src/PeerAbstractCommand.cc
  8957. (onAbort): Use peer->resetStatus().
  8958. * src/main.cc
  8959. (PeerChokeCommand.h): Included.
  8960. (main): Added the instance of ChokingCommand to the command queue.
  8961. * src/Peer.h
  8962. (amChoking): Renamed from amChocking
  8963. (chokingRequired): New variable.
  8964. (optUnchoking): New variable.
  8965. (deltaUpload): New variable.
  8966. (deltaDownload): New variable.
  8967. (addDeltaUpload): New function.
  8968. (resetDeltaUpload): New function.
  8969. (addDeltaDownload): New function.
  8970. (resetDeltaDownload): New function.
  8971. (addPeerUpload): Added a call to addDeltaUpload.
  8972. (addPeerDownload): Added a call to addDeltaDownload.
  8973. * src/Peer.cc
  8974. (shouldBeChoking): Renamed from shouldChoke.
  8975. (resetStatus): New function.
  8976. * src/PeerChokeCommand.h: New class.
  8977. * src/PeerChokeCommand.cc: New class.
  8978. To add lazy upload speed limiter:
  8979. * src/TorrentConsoleDownloadEngine.h: Moved the variables for
  8980. statistics calculation to TorrentDownloadEngine.
  8981. * src/TorrentConsoleDownloadEngine.cc
  8982. (sendStatistics): Renamed from printStatistics.
  8983. (initStatistics): Removed. Moved to TorrentDownloadEngine.
  8984. (calculateSpeed): Removed. Moved to TorrentDownloadEngine.
  8985. (calculateStatistics): Removed. Moved to TorrentDownloadEngine.
  8986. * src/TorrentDownloadEngine.h: Added the variables for statistics
  8987. calculation.
  8988. (sendStatistics): New function as pure virtual function.
  8989. (getUploadSpeed): New function.
  8990. * src/TorrentDownloadEngine.cc
  8991. (initStatistics): New function.
  8992. (calculateSpeed): New function.
  8993. (calculateStatistics): New function.
  8994. * src/SendMessageQueue.h
  8995. (uploadLength): New variable.
  8996. (send): Added an argument.
  8997. (setUploadLimit): New function.
  8998. (getUploadLimit): New function.
  8999. * src/SendMessageQueue.cc
  9000. (send): Added upload speed limiter.
  9001. * src/prefs.h
  9002. (PREF_UPLOAD_LIMIT): New definition.
  9003. * src/PeerInteractionCommand.cc
  9004. (PeerInteractionCommand): Set upload speed limit to sendMessageQueue.
  9005. * src/main.cc
  9006. (main): Added --upload-limit option
  9007. For bug fixes:
  9008. * src/main.cc
  9009. (showUsage): Corrected --listen-port help
  9010. Other changes:
  9011. * src/TorrentMan.cc
  9012. (getPeer): Return nullPeer if connection is grather than
  9013. MAX_PEER_UPDATE(15) in order to leave space for incoming peers.
  9014. 2006-04-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9015. To add some useful information to the exception message:
  9016. * src/SocketCore.cc : Updated messages.
  9017. * src/SegmentMan.cc :
  9018. * src/TorrentMan.cc : Updated messages.
  9019. * src/MultiDiskWriter.cc : Updated messages.
  9020. * src/Util.cc : Updated messages.
  9021. * src/AbstractDiskWriter.cc : Updated messages.
  9022. * src/PreAllocationDiskWriter.cc : Updated messages.
  9023. * src/message.cc : Added new messages. Updated some messages.
  9024. * src/TrackerWatcherCommand.h (MIN_PEERS): New definition.
  9025. * src/TrackerWatcherCommand.cc (execute): Use MIN_PEERS.
  9026. Updated threshold from 30 to 15.
  9027. * src/AbstractDiskWriter.h (filename): New variable.
  9028. * src/AbstractDiskWriter.cc (openExistingFile): Assigned filename.
  9029. (createFile): Assigned filename.
  9030. * src/main.cc: Updated the help message for http-auth-scheme.
  9031. * Release 0.4.0
  9032. 2006-04-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9033. To add TrackerUpdateCommand with which replaces
  9034. CompactTrackerResponseProcessor:
  9035. * src/TrackerWatcherCommand.h (req): Removed.
  9036. * src/TrackerWatcherCommand.cc (execute): Send a request to tracker
  9037. if the number of peer connections are less than 30.
  9038. * src/ByteArrayDiskWriter.h (readData): Implemented.
  9039. * src/SegmentMan.h (diskWriter): New function.
  9040. * src/SegmentMan.cc (init): Added a call to diskWriter->closeFile()
  9041. * src/main.cc : Removed #include "CompactTrackerResponseProcessor.h"
  9042. (main): Use TrackerUpdateCommand.
  9043. * src/TorrentMan.h (CompactTrackerResponseProcessor): Removed.
  9044. (req): New variable.
  9045. (setTrackerResponseProcessor): Removed.
  9046. (getTrackerResponseProcessor): Removed.
  9047. (processTrackerResponse): Removed.
  9048. * src/DownloadEngine.h (diskWriter): Removed.
  9049. * src/TorrentDownloadEngine.cc (afterEachIteration): Removed a call
  9050. to torrentMan->processTrackerResponse().
  9051. To add Util::expandBuffer:
  9052. * src/ByteArrayDiskWriter.h (expandBuffer): Removed.
  9053. * src/ByteArrayDiskWriter.cc (writeData): Use Util::expandBuffer().
  9054. * src/Util.h (expandBuffer): New function.
  9055. To fix the bug that causes segmentation fault when "-l ." is specified
  9056. in command-line option:
  9057. * src/SimpleLogger.h (SimpleLogger): Removed "filename" argument.
  9058. (openFile): New function.
  9059. (closeFile): New function.
  9060. * src/SimpleLogger.cc (SimpleLogger): Removed fopen.
  9061. (~SimpleLogger): Call closeFile();
  9062. * src/LogFactory.cc (getInstance): Added a call to slogger->openFile().
  9063. * src/main.cc (main): Added a check to see logger is configured
  9064. properly.
  9065. To enable HTTP authentication without specifying "--http-auth-scheme"
  9066. * src/prefs.h (PREF_HTTP_AUTH_ENABLED): New definition.
  9067. * src/HttpConnection.cc (createRequest): Send Authorization header
  9068. if PREF_HTTP_AUTH_ENABLED == V_TRUE.
  9069. * src/main.cc (main): Preset PREF_HTTP_AUTH_SCHEME to V_TRUE
  9070. If "--http-user" is specified, set PREF_HTTP_AUTH_ENABLED to V_TRUE
  9071. * src/Peer.cc (shouldChoke): Updated algorithm.
  9072. * src/message.h (EX_AUTH_FAILED): New definition.
  9073. (EX_FILE_OPEN): New definition.
  9074. * src/HttpResponseCommand.cc (checkResponse): Throw DlAbortEx
  9075. if status == 401.
  9076. (handleDefaultEncoding): Added a call to diskWriter->initAndOpenFile()
  9077. if req->isTorrent == true.
  9078. * src/main.cc (handler): Removed the check to see e->diskWriter != NULL
  9079. (torrentHandler): Removed the check to see diskAdaptor != NULL.
  9080. * src/AbstractDiskWriter.cc (openExistingFile): Updated messsage.
  9081. (createFile): Updated message.
  9082. 2006-04-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9083. To add a readout of estimated remaining time to normal HTTP/FTP
  9084. downloads:
  9085. * src/ConsoleDownloadEngine.h (startup): New variable.
  9086. (startupLength): New variable.
  9087. (isStartupLengthSet): New variable.
  9088. (avgSpeed): New variable.
  9089. (eta): New variable.
  9090. * src/ConsoleDownloadEngine.cc (sendStatistics): Added a readout of
  9091. estimated remaining time.
  9092. (initStatistics): Initialized newly added variables.
  9093. (calculateStatistics): Calculate average speed and estimated remaining
  9094. time.
  9095. To decouple TorrentDownloadEngine from HttpResponseCommand:
  9096. * src/TrackerDownloadCommand.h: Removed.
  9097. * src/TrackerDownloadCommand.cc: Removed.
  9098. * src/TrackerInitCommand.h: Removed.
  9099. * src/TrackerInitCommand.cc: Removed.
  9100. * src/TrackerUpdateCommand.h: Removed.
  9101. * src/TrackerUpdateCommand.cc: Removed.
  9102. * src/TrackerWatcherCommand.cc (execute): The construction of request
  9103. url written in TrackerInitCommand was moved here. Do not create
  9104. tracker request command if torrentMan->trackers != 0.
  9105. * src/CompactTrackerResponseProcessor.h: New class.
  9106. * src/CompactTrackerResponseProcessor.cc: New class.
  9107. * src/message.h (MSG_TRACKER_WARNING_MESSAGE): Updated.
  9108. * src/HttpResponseCommand.cc (createHttpDownloadCommand):
  9109. Decoupled TorrentDownloadEngine from this.
  9110. * src/SegmentMan.h (init): New function.
  9111. * src/SegmentMan.cc (init): New function.
  9112. * src/TorrentMan.h (responseProcessor): New variable.
  9113. (trackers): New variable.
  9114. (setTrackerResponseProcessor): New function.
  9115. (getTrackerResponseProcessor): New function.
  9116. (processTrackerResponse): New function.
  9117. * src/TorrentMan.cc (Constructor): Initialized new variable trackers.
  9118. (processTrackerResponse): New function.
  9119. * src/main.cc (main): Use ByteArrayDiskWriter and
  9120. CompactTrackerResponseProcessor.
  9121. * src/TorrentDownloadEngine.cc (afterEachIteration): Call torrentMan->
  9122. processTrackerResponse().
  9123. * src/TorrentConsoleDownloadEngine.cc (printStatistics): Updated a
  9124. readout.
  9125. * src/TorrentDownloadEngine.cc (afterEachIteration): Added log message
  9126. which indicates download has completed.
  9127. * src/AbstractDiskWriter.cc (Destructor): fd >= 0, not fd >0
  9128. (closeFile): fd >= 0, not fd > 0
  9129. * src/main.cc (main): Added short cut for show-files.
  9130. Added short cut for torrent-file.
  9131. Added new command-line option listen-port.
  9132. Updated i18n messages.
  9133. 2006-04-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9134. To add LogFactory which creates singleton logger:
  9135. * src/LogFactory.h: New class.
  9136. * src/LogFactory.cc: New class.
  9137. * src/Command.h (logger): New variable.
  9138. (Constructor): Use LogFactory.
  9139. * src/AbstractCommand.cc: Use Command::logger
  9140. * src/PeerConnection.cc (Constructor): Deleted the argument logger.
  9141. Use LogFactory.
  9142. * src/SegmentSplitter.h : Made logger protected.
  9143. * src/SegmentSplitter.cc (Constructor): Use LogFactory.
  9144. * src/SegmentMan.cc (Constructor): Use LogFactory.
  9145. * src/DownloadEngine.h : Made logger protected.
  9146. * src/DownloadEngine.cc (Constructor): Use LogFactory.
  9147. * src/PeerInteractionCommand.cc : Use Command::logger.
  9148. * src/HttpResponseCommand.cc : Use Command::logger.
  9149. * src/SegmentMan.h : Made logger private.
  9150. * src/TorrentMan.h : Made logger private.
  9151. * src/TorrentMan.cc : Use LogFactory.
  9152. * src/FtpNegotiateCommand.cc : Use Command::logger.
  9153. * src/HttpConnection.h (Constructor): Deleted the argument logger.
  9154. * src/HttpConnection.cc (Constructor): Deleted the argument logger.
  9155. Use LogFactory.
  9156. * src/FtpConnection.h (Constructor): Deleted the argument logger.
  9157. * src/FtpConnection.cc (Constructor): Deleted the argument logger.
  9158. Use LogFactory.
  9159. * src/DownloadCommand.cc : Use Command::logger.
  9160. * src/PeerAbstractCommand.cc : Use Command::logger.
  9161. * src/PeerListenCommand.cc : Use Command::logger.
  9162. * src/PeerInitiateConnectionCommand.cc : Use Command::logger.
  9163. * src/HttpInitiateConnectionCommand.cc : Use Command::logger.
  9164. * src/FtpInitiateConnectionCommand.cc : Use Command::logger.
  9165. * src/TrackerWatcherCommand.cc : Use Command::logger.
  9166. * src/TrackerUpdateCommand.cc : Use Command::logger.
  9167. * src/TrackerDownloadCommand.cc : Use Command::logger.
  9168. * src/RequestSlotMan.cc (Constructor): Deleted the argument logger.
  9169. Use LogFactory.
  9170. * src/SendMessageQueue.h (Constructor): Deleted the argument logger.
  9171. * src/SendMessageQueue.cc (Constructor): Deleted the argument logger.
  9172. Use LogFactory.
  9173. * src/main.cc (main): Use LogFactory.
  9174. * src/DiskAdaptor.h (logger): New variable.
  9175. * src/DiskAdaptor.cc (Constructor): Use LogFactory.
  9176. * src/CopyDiskAdaptor.cc (fixFilename): Added a log message.
  9177. 2006-04-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9178. * src/TrackerInitCommand.cc (TrackerInitCommand): Added a "key"
  9179. parameter to a tracker request.
  9180. * src/TorrentMan.cc (readFileEntryFromMetaInfoFile): Bug fix.
  9181. * src/TrackerWatcherCommand.cc (execute): Call req->resetTryCount().
  9182. * src/main.cc (setSignalHander): New function.
  9183. (main): Added a handler for SIGTERM.
  9184. (handler): Updated message.
  9185. (torrentHandler): Updated message.
  9186. 2006-04-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9187. * src/TorrentConsoleDownloadEngine.cc
  9188. (onPartialDownloadingCompletes): Renamed as
  9189. onSelectiveDownloadingCompletes.
  9190. (onSelectiveDownloadingCompletes): Updated message.
  9191. To add DiskAdaptor which abstract DiskWriter family:
  9192. * src/PeerConnection.cc: Use diskAdaptor instead of diskWriter.
  9193. * src/PeerInteractionCommand.cc: Use diskAdaptor instead of diskWriter.
  9194. * src/BitfieldMan.cc (isAllBitSet): bug fix.
  9195. * src/TorrentMan.cc : Included CopyDiskAdaptor.h, DirectDiskAdaptor.h,
  9196. MultiDiskAdaptor.h.
  9197. (readFileEntry): Changed its arguments.
  9198. (setup): setupDiskWriter is merged into this function.
  9199. (setupDiskWriter): Removed.
  9200. (setFileFilter): New function.
  9201. (readFileEntryFromMetaInfoFile): Updated according to the changes
  9202. made in readFileEntry.
  9203. (getFilePath): Removed.
  9204. (getTempFilePath): Removed.
  9205. (getSegmentFilePath): Updated due to the removal of getFilePath.
  9206. (fixFilename): Removed.
  9207. (copySingleFile): Removed.
  9208. (splitMultiFile): Removed.
  9209. (deleteTempFile): Removed.
  9210. (setFileEntriesToDownload): Removed.
  9211. (isPartialDownloadingMode): Renamed as isSelectiveDownloadingMode.
  9212. (isSelectiveDownloadingMode): New function.
  9213. (setAllMultiFileRequestedState): Removed.
  9214. (finishPartialDownloadingMode): Renamed as
  9215. finishSelectiveDownloadingMode.
  9216. (finishSelectiveDownloadingMode): New function.
  9217. (getPartialTotalLength): Renamed as getSelectedTotalLength.
  9218. (getSelectedTotalLength): New function.
  9219. (onDownloadComplete): Use diskAdaptor.
  9220. * src/MultiDiskWriter.cc (Constructor): Added the argument pieceLength
  9221. (Range): Removed.
  9222. (setMultiFileEntries): Renamed as setFileEntries.
  9223. (setFileEntries): New function.
  9224. * src/MultiDiskWriter.h [DiskWriterEntry](enabled): Removed.
  9225. (pieceLength): New variable.
  9226. * src/main.cc (printDownloadCompeleteMessage): New function.
  9227. (torrentHandler): Use diskAdaptor instead of diskWriter.
  9228. (main): Renamed torrent-show-files to show-files.
  9229. Rewritten file contents listing.
  9230. * src/TorrentMan.h (FileEntry): Removed.
  9231. (multiFileTopDir): Removed.
  9232. (multiFileEntries): Removed.
  9233. (diskWriter): Removed.
  9234. (diskAdaptor): New variable.
  9235. * src/DefaultDiskWriter.h (totalLength): New variable.
  9236. * src/DefaultDiskWriter.cc (initAndOpenFile): Added ftruncate.
  9237. * src/TorrentDownloadEngine.cc (onEndOfRun): Use diskAdaptor instead of
  9238. diskWriter.
  9239. * src/TorrentConsoleDownloadEngine.h
  9240. (partialDownloadLengthDiff): Renamed as selectedDownloadLengthDiff.
  9241. (partialTotalLength): Renamed as selectedTotalLength.
  9242. * src/AbstractDiskWriter.cc (openFile): If file exists, call
  9243. openExistingFile, otherwise call initAndOpenFile.
  9244. (closeFile): fd > 0, not fd != 0.
  9245. * src/DirectDiskAdaptor.h: New class.
  9246. * src/DirectDiskAdaptor.cc: New class.
  9247. * src/MultiDiskAdaptor.h: New class.
  9248. * src/MultiDiskAdaptor.cc: New class.
  9249. * src/CopyDiskAdaptor.h: New class.
  9250. * src/CopyDiskAdaptor.cc: New class.
  9251. * src/DiskAdaptor.h: New class.
  9252. * src/DiskAdaptor.cc: New class.
  9253. * src/prefs.h (PREF_TORRENT_SHOW_FILES): Renamed as PREF_SHOW_FILES
  9254. (PREF_SHOW_FILES): New definition.
  9255. 2006-04-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9256. To add the ability to download multi torrent into respective files
  9257. directly:
  9258. * src/DiskWriter.h (openFile): New function.
  9259. (seek): Removed.
  9260. * src/MultiDiskWriter.h: New class.
  9261. * src/MultiDiskWriter.cc: New class.
  9262. * src/AbstractDiskWriter.h (seek): Changed its scope from public to
  9263. protected.
  9264. (openFile): New function.
  9265. * src/AbstractDiskWriter.cc (openFile): New function.
  9266. * src/prefs.h (V_FALSE): New definition.
  9267. (PREF_DIRECT_FILE_MAPPING): New definition.
  9268. * src/TorrentMan.h (setupDiskWriter): New function.
  9269. (setAllMultiFileRequestedState): New function.
  9270. (onDownloadComplete): New function.
  9271. * src/TorrentMan.cc : Included MultiDiskWriter.h
  9272. (setupDiskWriter): New function.
  9273. (getFilePath): Updated.
  9274. (getTempFilePath): Updated.
  9275. (getSegmentFilePath): Updated.
  9276. (fixFilename): Updated.
  9277. (deleteTempFile): Updated.
  9278. (setAllMultiFileRequestedState): New function.
  9279. (setFileEntriesToDownload): Use setAllMultiFileRequestedState().
  9280. (finishPartialDownloadingMode): Reset requested flags.
  9281. (onDownloadComplete): New function.
  9282. * src/main.cc: Added --direct-file-mapping option.
  9283. Use TorrentMan::setupDiskWriter().
  9284. * src/TorrentDownloadEngine.cc (afterEachIteration): Use TorrentMan::
  9285. onDownloadComplete().
  9286. To fix ETA bug:
  9287. * src/Util.h (difftvsec): New function.
  9288. * src/Util.cc (difftvsec): New function.
  9289. * src/TorrentConsoleDownloadEngine.cc (calculateSpeed): Use int for the
  9290. type of "elapsed" instead of long long int.
  9291. (calculateStatistics): Use Util::difftvsec instead of Util::difftv.
  9292. The updates of statistics takes place every 1 seconds.
  9293. * src/TorrentConsoleDownloadEngine.h (lastElapsed): Changed its type.
  9294. (calculateSpeed): Changed its argument signature.
  9295. * src/PeerMessage.cc (toString): Fixed message.
  9296. 2006-04-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9297. To print ETA:
  9298. * src/TorrentDownloadEngine.cc (afterEachIteration): Added download
  9299. completion handling when dealing with
  9300. TorrentMan::isPartialDownloadingMode() == true.
  9301. * src/TorrentDownloadEngine.h (onPartialDownloadingCompletes):
  9302. New function.
  9303. * src/TorrentConsoleDownloadEngine.h (startup): New variable.
  9304. (sessionDownloadLength): New variable.
  9305. (avgSpeed): New variable.
  9306. (eta): New variable.
  9307. * src/TorrentConsoleDownloadEngine.cc (initStatistics): Initialized
  9308. new variables: eta, avgSpeed, startup.
  9309. (calculateSpeed): Calculate average speed and ETA.
  9310. (printStatistics): Added ETA.
  9311. * src/Util.h (secfmt): New function.
  9312. * src/Util.cc (secfmt): New function.
  9313. 2006-04-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9314. To detect "keep alive" flooding:
  9315. * src/PeerInteractionCommand.h (keepAliveCount): New variable
  9316. * src/PeerInteractionCommand.cc (Constructor): Initialized new
  9317. variable: keepAliveCount.
  9318. (detectMessageFlooding): Added "keep alive" flooding detection.
  9319. (receiveMessage): Increase keepAliveCount when "keep alive" message
  9320. received.
  9321. To add the ability to download only specified files in multi-file
  9322. torrent:
  9323. * src/BitfieldMan.h (filterBitfield): New variable.
  9324. (filterEnabled): New variable.
  9325. (setFilterBit): New function.
  9326. (enableFilter): New function.
  9327. (disableFilter): New function.
  9328. (isFilterEnabled): New function.
  9329. (getFilteredTotalLength): New function.
  9330. (getCompletedLength): New function.
  9331. * src/BitfieldMan.cc (Constructor): Initialized new variable:
  9332. filterBitfield, filterEnabled.
  9333. (CopyConstructor): Added filterBitfield and filterEnabled.
  9334. (operator==): Added filterBitfield and filterEnabled.
  9335. (Destructor): Added filterBitfield.
  9336. (getMissingIndex): Use filterBitfield.
  9337. (getMissingUnusedIndex): Use filterBitfield.
  9338. (getFirstMissingUnusedIndex): Use filterBitfield.
  9339. (getFirstMissingUnusedIndex): Use filterBitfield.
  9340. (getAllMissingIndexes): Use filterBitfield.
  9341. (countMissingBlock): Use filterBitfield.
  9342. (countBlock): Use filterBitfield.
  9343. (setBitInternal): Added new argument on.
  9344. (setUseBit): Use setBitInternal.
  9345. (unsetUseBit): Use setBitInternal.
  9346. (setBit): Use setBitInternal.
  9347. (unsetBit): Use setBitInternal.
  9348. (isAllBitSet): Use filterBitfield.
  9349. (setFilterBit): New function.
  9350. (addFilter): New function.
  9351. (enableFilter): New function.
  9352. (disableFilter): New function.
  9353. (clearFilter): New function.
  9354. (isFilterEnabled): New function.
  9355. (getFilteredTotalLength): New function.
  9356. (getCompletedLength): New function.
  9357. * src/TorrentMan.h [FileEntry](Constructor): Updated signature.
  9358. Initalized newly added variables.
  9359. [FileEntry](offset): New variable.
  9360. [FileEntry](extracted): New variable.
  9361. [FileEntry](requested): New variable.
  9362. (readFileEntry): New function.
  9363. (option): New variable.
  9364. (splitMultiFile): Removed const qualifier.
  9365. (fixFilename): Removed const qualifier.
  9366. (readFileEntryFromMetaInfoFile): New function.
  9367. (finishPartialDownloadingMode): New function.
  9368. (isPartialDownloadingMode): New function.
  9369. (setFileEntriesToDownload): New function.
  9370. (getCompletedLength): New function.
  9371. (getPartialTotalLength): New function.
  9372. * src/TorrentMan.cc (readFileEntry): New function.
  9373. (setup): Use readFileEntry. If no-preallocation option is specified,
  9374. use DefaultDiskWriter.
  9375. (readFileEntryFromMetaInfoFile): New function.
  9376. (fixFilename): Removed const qualifier.
  9377. (splitMultiFile): Removed const qualifier.
  9378. (setFileEntriesToDownload): New function.
  9379. (isPartialDownloadingMode): New function.
  9380. (finishPartialDownloadingMode): New function.
  9381. (getCompletedLength): New function.
  9382. (getPartialTotalLength): New function.
  9383. * src/TorrentConsoleDownloadEngine.h (partialDownloadLengthDiff):
  9384. New variable.
  9385. (partialTotalLength): New variable.
  9386. (downloadLength): New variable.
  9387. (totalLength): New variable.
  9388. * src/TorrentConsoleDownloadEngine.cc (onPartialDownloadingCompletes):
  9389. Added log.
  9390. (initStatistics): Initialized new variables: partialDownloadLengthDiff,
  9391. partialTotalLength, downloadLength, totalLength.
  9392. (calculate): Calculate downloadLength and totalLength.
  9393. * src/prefs.h :New definition PREF_NO_PREALLOCATION
  9394. * src/main.cc (addCommand): Changed argument signature.
  9395. (main): Added new variable: args. Added new option "torrent-show-files"
  9396. "no-preallocation". Usage is not updated yet.
  9397. 2006-04-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9398. * src/PeerMessage.cc (setBitfield): Fixed invalid memory de-allocation.
  9399. 2006-04-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9400. Attempt to add the ability to listing file entries in a .torrent file.
  9401. This feature is not yet complete.
  9402. * src/prefs.h (PREF_TORRENT_SHOW_FILES): New definition
  9403. * src/TorrentMan.cc (getMultiFileEntries): New function.
  9404. (getName): New function.
  9405. * src/TorrentMan.h (getMultiFileEntries): New function.
  9406. (getName): New function.
  9407. * src/main.cc (main): Use above 2 funtion.
  9408. * Release 0.3.2
  9409. 2006-03-31 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9410. * src/PeerInteractionCommand.cc (checkInactiveConnection): New function
  9411. (detectMessageFlooding): Updated threshold value.
  9412. (checkLongTimePeerChoking): Updated timeout value.
  9413. (getNewPieceAndSendInterest): Added debug log.
  9414. * src/PeerInteractionCommand.h (checkInactiveConnection): New function
  9415. * src/TorrentMan.cc (deleteOldErrorPeers): Updated.
  9416. (getPeer): Updated.
  9417. * src/TorrentMan.h: Added MAX_PEER_ERROR.
  9418. * src/PeerAbstractCommand.cc (onAbort): Increment error counter.
  9419. * src/PeerListenCommand.cc (execute): Close connection if incoming peer
  9420. is localhost.
  9421. * src/main.cc (main): Updated PREF_PEER_CONNECTION_TIMEOUT to 60.
  9422. * src/PendingMessage.cc (processMessage): Not to send piece message
  9423. if peer is not interested in the pieces localhost has.
  9424. * src/Peer.cc (shouldChoke): Updated.
  9425. * src/SendMessageQueue.cc (cancelAllRequest): Fixed.
  9426. * src/Util.cc (isPowerOf): New function.
  9427. * src/Util.h (isPowerOf): New function.
  9428. * src/PeerMessageUtil.cc (checkLength): Added a check for length
  9429. whether or not it is power of 2.
  9430. 2006-03-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9431. Added new class SendMessageQueue that includes PendingMessages and
  9432. RequestSlotMan.
  9433. * src/SendMessageQueue.h: New class.
  9434. * src/SendMessageQueue.cc: New class.
  9435. * src/PendingMessage.h: Added new member variable blockIndex and its
  9436. accessors.
  9437. (createRequestMessage): Updated.
  9438. * src/PendingMessage.cc (createRequestMessage): Updated.
  9439. * src/PeerInteractionCommand.cc (executeInternal): Updated with
  9440. SendMessageQueue.
  9441. (checkLongTimePeerChoking): Updated with SendMessageQueue.
  9442. (receiveMessage): Updated with SendMessageQueue.
  9443. (deletePendingPieceMessage): Removed.
  9444. (getNewPieceAndSendInterest): Updated with SendMessageQueue.
  9445. (sendInterest): Updated with SendMessageQueue.
  9446. (createRequestPendingMessage): Updated with SendMessageQueue.
  9447. (sendMessages): Updated with SendMessageQueue.
  9448. (onAbort): Updated with SendMessageQueue.
  9449. (keepAlive): Updated with SendMessageQueue.
  9450. (beforeSocketCheck): Updated SendMessageQueue.
  9451. * src/PeerInteractionCommand (sendMessages): Shuffle
  9452. missingBLockIndexes before using it.
  9453. Added its own timeout for peer connection.
  9454. * src/PeerAbstractCommand.h: Added member variable timeout and its
  9455. setter.
  9456. * src/prefs.h: Added PREF_PEER_CONNECTION_TIMEOUT.
  9457. * src/PeerInteractionCommand.cc (PeerInteractionCommand):
  9458. Added setTimeout() call.
  9459. (executeInternal): Added setTimeout() call.
  9460. * src/PeerAbstractCommand.cc (PeerAbstractCommand):
  9461. Added timeout.
  9462. (isTimeoutDetected): Updated.
  9463. * src/main.cc (main): Added PREF_PEER_CONNECTION_TIMEOUT entry to
  9464. option.
  9465. Added *simple* message flooding checker.
  9466. * src/PeerInteractionCommand.cc (executeInternal):
  9467. Added detectMessageFlooding() call.
  9468. (detectMessageFlooding): New function.
  9469. (receiveMessage): Count up CHOKE, UNCHOKE, HAVE message.
  9470. (beforeSocketCheck): Added detectMessageFlooding() call.
  9471. * src/PeerInteractionCommand.h: Added sendMessageQueue,
  9472. chokeUnchokeCount, haveCount, detectMessageFlooding().
  9473. Removed deletePendingPieceMessage(), getRequestSlot(),
  9474. deleteRequestSlot(), deleteAllRequestSlot().
  9475. * src/PeerInteractionCommand.cc (beforeSocketCheck):
  9476. Added checkLongTimePeerChoking() call.
  9477. * src/RequestSlotMan.h: Renamed deleteTimeoutRequestSlot().
  9478. * src/TorrentMan.cc (addPeer): Delete at most MAX_PEER_LIST_SIZE peers
  9479. if duplicate == false.
  9480. The parameter "uploaded" and "downloaded" in the tracker request are
  9481. the size since the client sent the "started" event to the tracker.
  9482. * src/TorrentMan.cc (setup): Assigned saved downloaded Size and
  9483. uploaded size to preDownloadedSize, preUploadedSize respectively.
  9484. * src/TorrentMan.h: Added preDownloadedSize, preUploadedSize,
  9485. getSessionDownloadedSize(), getSessionUploadedSize().
  9486. * src/TrackerInitCommand.cc (execute): Use getSessionDownloadedSize(),
  9487. getSessionUploadedSize() instead of getDownloadedSize(),
  9488. getUploadedSize().
  9489. * src/PendingMessage.cc (processMessage): Do not send request message
  9490. if the peer is choking the client.
  9491. * src/TrackerUpdateCommand.cc (execute): Check wtheher minInterval is
  9492. less than interval.
  9493. 2006-03-27 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9494. * configure.in: Added gnutls support. Added several CPP macros.
  9495. * m4/openssl.m4: Added.
  9496. * src/SocketCore.{h,cc}: Drop const quarifier from writeData(),
  9497. readData(), peekData(). Added gnutls support.
  9498. * src/HttpDownloadCommand.cc: Removed SleepCommand.h
  9499. * src/TrackerWatcherCommand.{h,cc}: Added. This command creates
  9500. TrackerInitCommand periodicaly(TorrentMan::minInterval).
  9501. * src/TorrentMan.cc: Remove downloadedSize == 0 check from save().
  9502. Instead, added a check for whether setup method has executed
  9503. successfully.
  9504. * src/TorrentMan.h: Added member vaiable setupComplete. Updated
  9505. DEFAULT_ANNOUNCE_INTERVAL and DEFAULT_ANNOUNCE_MIN_INTERVAL to 300.
  9506. * src/Makefile.am: Updated.
  9507. * src/messageDigest.h: Added. This is a macro calculating SHA1 digest
  9508. using whether OpenSSL or gcrypt, depending on the result of configure
  9509. script.
  9510. * src/ShaVisitor.{h,cc}: Removed direct dependency on OpenSSL by using
  9511. messageDigest.h.
  9512. * src/TorrentAutoSaveCommand.h: Removed unused variable cuid.
  9513. * src/PeerListenCommand.cc: Added log about port binded successfully.
  9514. Fixed memory leak.
  9515. * src/main.cc: Added gnutls support. Replaced LIB_SSL with
  9516. ENABLE_BITTORRENT where they are not related to OpenSSL but BitTorrent.
  9517. Removed instantiation of TrackerInitCommand. Instead,
  9518. TrackerWatcherCommand is instantiated and pushed to the command queue.
  9519. * src/InitiateConnectionCommandFactory.cc: Replaced HAVE_LIBSSL with
  9520. ENABLE_SSL.
  9521. * src/Request.cc: Replaced HAVE_LIBSSL with ENABLE_SSL.
  9522. * src/RequestSlotMan.cc (deleteCompletedRequestSlot):
  9523. If a piece is already acquired by another command, delete the request
  9524. slots for the piece.
  9525. * src/TrackerUpdateCommand.cc (execute):
  9526. Changed log level of MSG_TRACKER_WARNING_MESSAGE from info to warn.
  9527. Added a check whether peer list is null.
  9528. Fixed the bug that causes sending completed event to the tracker
  9529. several times.
  9530. * src/TrackerInitCommand.cc (execute):
  9531. Fixed the bug that causes sending completed event to the tracker
  9532. several times.
  9533. * src/AbstractDiskWriter.{h,cc}: Removed direct dependency on OpenSSL
  9534. by using messageDigest.h.
  9535. 2006-03-26 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9536. * PeerConnection.cc: Replaced log message "keep-alive" with
  9537. "keep alive".
  9538. * PeerInteractionCommand.{h,cc}: Close connection if peer is choking
  9539. localhost long time.
  9540. * TorrentMan.cc: When adding new peer with duplicate = true, if the
  9541. number of peer list is equal to or grater than MAX_PEER_LIST, delete
  9542. at most 100 failure entry from the list. If with duplicate = false,
  9543. MAX_PEER_LIST is not checked.
  9544. * PeerListenCommand.cc: Fixed the argument order of log message.
  9545. 2006-03-25 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9546. * Logger.h: Moved enum LEVEL from SimpleLogger.h to here.
  9547. Added warn().
  9548. * SimpleLogger.h: Moved enum LEVEL to Logger.h.
  9549. Implemented warn().
  9550. Defined 2 macros(WRITE_LOG, WRITE_LOG_EX) to avoid duplicated code.
  9551. 2006-03-24 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9552. * Request.h: Added AFTER_COMPLETED event.
  9553. * TorrentDownloadEngine.cc: Prints "Download complete" message
  9554. instead of downloaded size and progress(%) after download completes.
  9555. * PeerInteractionCommand.cc: After download completes, sends unchoke
  9556. message to the peer if it is interested in what localhost has
  9557. downloaded.
  9558. * TorrentMan.cc: In single-file mode, copy temporary file to the final
  9559. destination instead of just renaming it.
  9560. * TorrentMan.cc: Added deleteTempFile().
  9561. * PeerAbstractCommand.cc: do not stop execution after download
  9562. completes. This makes localhost a seeder.
  9563. * Util.{h,cc}: Added fileCopy().
  9564. * PeerListenCommand.cc: do not stop execution after download completes.
  9565. This makes localhost a seeder.
  9566. * main.cc: Do not call TorrentMan::fixFilename() in torrentHandler.
  9567. Added TorrentMan::deleteTempFile() to torrentHandler.
  9568. Initialized the variable dir as ".".
  9569. * TorrentMan.h: Changed DEFAULT_ANNOUNCE_INTERVAL to 120 seconds.
  9570. Deleted renameSingleFile().
  9571. Added copySingleFile(), deleteTempFile().
  9572. * DownloadEngine.h: Added virtual function afterEachIteration().
  9573. * TorrentDownloadEngine.cc: Move a call to TorrentMan::fixFilename()
  9574. in onEndOfRun() to afterEachIteration().
  9575. In onEndOfRun(), changed if condition to check whether filenameFixed is
  9576. true.
  9577. * Util.cc: Implemented fileCopy() using rangedFileCopy().
  9578. In rangedFileCopy(), added try-catch block to properly close file
  9579. descriptors.
  9580. * TorrentDownloadEngine.cc: Added a member variable filenameFixed.
  9581. Added afterEachIteration(), isFilenameFixed().
  9582. * Peer.cc: Changed choking strategy.
  9583. * PreAllocationDiskWriter.cc: Drop O_DIRECT flag.
  9584. * TrackerInitCommand.cc: Send completed event only once.
  9585. * DownloadEngine.cc: Added a call to afterEachIteration().
  9586. * TrackerUpdateCommand.cc: Do not stop execution after download
  9587. completes.
  9588. * TorrentMan.h: Defined MAX_PEER_UPDATE as 15. aria2 attempts to
  9589. connect the peers at most MAX_PEER_UPDATE when a peer list is
  9590. received from a tracker.
  9591. * TrackerUpdateCommand.cc: Implemented above mentioned behavior.
  9592. Decreased the number of failure peers to delete to 0(just comment out
  9593. the line).
  9594. * Release 0.3.1
  9595. 2006-03-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9596. * PeerInteractionCommand.cc: added a call to
  9597. TorrentMan::unadvertisePiece in Destructor.
  9598. * PeerInteractionCommand.cc: make have message sent immediately
  9599. if the size of pending message queue is zero.
  9600. * TorrentMan.cc: set the maximum size of peer list to 250.
  9601. * TorrentMan.h: changed the container type of Peers and UsedPieces
  9602. to deque.
  9603. * Util.cc: fixed rangedFileCopy.
  9604. * AbstractDiskWriter.{h,cc}: moved digest context initialization
  9605. to Constructor. Also, moved digest cleanup to Destructor.
  9606. * MetaFileUtil.cc: fixed memory leak
  9607. * replaced std::vector with std::deque.
  9608. * AbstractCommand.cc: casted timeout value to long long int.
  9609. * ChunkedEncoding.cc: fixed memory leak.
  9610. * PeerInteractionCommand.cc: casted timeout value to long long int.
  9611. * SleepCommand.cc: casted timeout value to long long int.
  9612. * Data.cc: fixed memory leak.
  9613. * Data.cc: fixed toLLInt().
  9614. * BitfieldMan.cc: fixed memory leak.
  9615. * TorrentMan.cc: initialized storeDir to ".".
  9616. * TorrentMan.cc: fixed memory leak.
  9617. * TorrentMan.cc: corrected file paths of splitted files.
  9618. * PeerAbstractCommand.cc: casted timeout to long long int.
  9619. * main.cc: added delete(req) and delete(te->diskWriter).
  9620. * RequestSlot.cc: casted timeout value to long long int.
  9621. * Request.cc: fixed memory leak.
  9622. * PendingMessage.cc: make HAVE messages sent only when peer does not
  9623. have the piece.
  9624. * Peer.{h,cc}: added hasPiece(int index).
  9625. * main.cc: corrected addCommand.
  9626. 2006-03-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9627. * BitTorrent protocol support added.
  9628. * Release 0.3.0
  9629. 2006-03-17 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9630. * SocketCore.cc: remove the assignment of addrinfo.ai_addr.
  9631. 2006-03-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9632. * ChunkedEncoding.{h,cc}: fixed the bug that if chunk data is binary,
  9633. decoding did not work properly.
  9634. 2006-03-07 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9635. * DownloadEngine.h: included sys/time.h
  9636. * DownloadEngine.cc: remove sys/time.h
  9637. * Makefile.am (SUBDIRS): Add intl.
  9638. * configure.in (AC_CONFIG_FILES): Add intl/Makefile.
  9639. 2006-03-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9640. * main.cc: correct help message for --http-auth-scheme.
  9641. * main.cc: changed e-mail address for bug reports.
  9642. * ja.po: added japanese translation.
  9643. 2006-03-04 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9644. * SimpleLogger.cc: flush log file instead of stdout.
  9645. 2006-03-03 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9646. * main.cc: Fixed command-line option: max-tries
  9647. * HttpResponseCommand.cc: Make the request re-sent only if req->seg.sp
  9648. does not equal to seg.sp.
  9649. * DownloadCommand.cc: If EOF is got from the server and the total size
  9650. of file is not zero, then throw DlRetryEx.
  9651. * main.cc: Set the minium value of min-segment-size to 1024.
  9652. * HttpResponseCommand.cc: Fixed the bug that http segmented downloading
  9653. fails because of a regression since 0.2.0 release.
  9654. 2006-03-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9655. * HttpConnection.cc:
  9656. * common.h: defined the user agent name as macro
  9657. * DownloadEngine.{h, cc}:
  9658. * ConsoleDownloadEngine.{h, cc}: Console output message(size, speed)
  9659. is now generated by ConsoleDownloadEngine not by DownloadEngine.
  9660. * main.cc: Download complete/abort message is now generated by main.
  9661. * Makefile.am (SUBDIRS): Add m4.
  9662. (ACLOCAL_AMFLAGS): New variable.
  9663. (EXTRA_DIST): New variable.
  9664. * configure.in (AC_CONFIG_FILES): Add po/Makefile.in,
  9665. * gettext: added gettext functionality
  9666. 2006-03-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9667. * AbstractCommand.cc:
  9668. * DownloadCommand.{h, cc}: Aborted downloading commands now properly
  9669. unregister its cuid from SegmentMan.
  9670. * DownloadEngine.cc: .aria2 file was written when a downloading
  9671. failed with errors.
  9672. * HttpConnection.cc: Added "Proxy-Connection" header to proxy request.
  9673. Added "User-Agent" header to CONNECT proxy request.
  9674. Fixed "Proxy-Authorization" header. Now proxy authorization works
  9675. properly.
  9676. * Logger.h:
  9677. * SimpleLogger.{h,cc}: Changed the type of msg to const char*.
  9678. * ChunkedEncoding.cc: Added #include directive for strings.h
  9679. * Release 0.2.1
  9680. 2006-02-28 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9681. * Util.{h,cc}: added startsWith().
  9682. * CookieBox.cc: rewrited criteriaFind() using Util::startsWith() and
  9683. Util::endsWith().
  9684. * SocketCore.cc: struct addrinfo is now zero-initialized.
  9685. * common.h: added #include directive of limit.h.
  9686. * DownloadEngine.cc: added #include directive of sys/time.h and
  9687. algorithm.
  9688. * Exception.h: added #include directive of stdio.h.
  9689. * AbstractCommand.h: added #include directive of sys/time.h.
  9690. * DownloadCommand.h: added #include directive of sys/time.h.
  9691. * *.h: added #include directive of common.h to all base classes.
  9692. subclasses' one was removed.
  9693. * common.h: defined LONG_LONG_MAX and LONG_LONG_MIN if a compiler
  9694. does not define these macros.
  9695. 2006-02-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9696. * Release 0.2.0
  9697. * main.cc:
  9698. * HttpInitiateConnectionCommand.{h,cc}:
  9699. * prefs.h:
  9700. * HttpConnection.{h,cc}: added --http-proxy-method option.
  9701. We can now use GET command in http proxy.
  9702. 2006-02-22 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9703. * SplitSlowestSegmentSplitter.{h,cc}: This class provies algorithm
  9704. that splits slowest segment of SegmentMan::commands vector.
  9705. This is the default split algorithm of aria2.
  9706. * SplitFirstSegmentSplitter.{h,cc}: This class provides algorithm
  9707. that splits first segment of SegmentMan::commands vector.
  9708. * SegmentSplitter.{h,cc}: Added. This class provides split algorithm.
  9709. * DownloadCommand.{h,cc}: Added downloading speed calculation.
  9710. * Segment.h:
  9711. * SegmentMan.cc: Added speed field to Segment.h
  9712. * main.cc: -s option now affects all URLs in command-line arguemtns.
  9713. * HttpResponseCommand.cc: Fixed bug that segment file is not loaded.
  9714. * message.h: Change file size related %d to %lld.
  9715. 2006-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9716. * FtpInitiateConnectionCommand.{h,cc}:
  9717. * FtpNegotiationCommand.{h,cc}:
  9718. * FtpDownloadCommand.{h,cc}:
  9719. * FtpConnection.{h,cc}: Added FTP support
  9720. * SimpleLogger.cc: Log message now includes time information.
  9721. * main.cc: The value of --http-auth-scheme option is chagned from
  9722. 'BASIC' to 'basic'
  9723. * main.cc: Added --timeout command-line option.
  9724. * main.cc: Added --min-segment-size command-line option.
  9725. * main.cc: Added --max-retries command-line option.
  9726. * prefs.h: option string constants are now defined in prefs.h
  9727. 2006-02-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9728. * AbstractCommand.cc: Fixed timeout bug in AbstractCommand
  9729. * SegmentMan.cc: Added totalSize entry to .aria2 file. No compatibility
  9730. with version 0.1.0's one.
  9731. 2006-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
  9732. * configure.in: Added --enable-ssl option to configure script.
  9733. * HttpConnection.cc: Make Request-URI an absolute path. Some servers
  9734. cannot permit absoluteURI as Request-URI.
  9735. * HttpConnection.cc: Added Referer support.
  9736. * main.cc: Added referer command-line option.
  9737. * main.cc: Added rety-wait command-line option.
  9738. * Exception.h: Fixed formating bug in Exception::setMsg()
  9739. * SocketCore.{h,cc}:
  9740. * Socket.{h, cc}:
  9741. * Request.cc:
  9742. * InitiateConnectionCommandFactory.cc:
  9743. * HttpRequestCommand.cc: Added HTTPS support.
  9744. * SocketCore.{h,cc}: Added SocketCore. Socket becomes a handle class
  9745. for SocketCore.
  9746. * ChunkedEncoding.cc: Fixed bug in ChunkedEncoding: expanding buffer
  9747. size is wrong
  9748. * DownloadCommand.cc: Fixed bug in DownloadCommand: In Chunked
  9749. Encoding, it wrongly adds to Segment.ds buff length from the socket.
  9750. 2006-02-17 Tatsuhiro Tsujikawa <tsujikawa at rednoah dot com>
  9751. * Release 0.1.0