Fix compile error

This commit is contained in:
Tatsuhiro Tsujikawa 2013-06-27 00:20:48 +09:00
parent da7400ef5c
commit 0b1e05b13b
3 changed files with 3 additions and 3 deletions

View File

@ -41,7 +41,7 @@
#include <aria2/aria2.h>
int downloadEventCallback(aria2::Session* session, aria2::DownloadEvent event,
const aria2::A2Gid& gid, void* userData)
aria2::A2Gid gid, void* userData)
{
switch(event) {
case aria2::EVENT_ON_DOWNLOAD_COMPLETE:

View File

@ -52,7 +52,7 @@ bool KeepRunningCommand::execute()
if(e_->isHaltRequested()) {
return true;
}
e_->addCommand(this);
e_->addCommand(std::unique_ptr<Command>(this));
return false;
}

View File

@ -128,7 +128,7 @@ Session* sessionNew(const KeyVals& options, const SessionConfig& config)
if(config.keepRunning) {
e->getRequestGroupMan()->setKeepRunning(true);
// Add command to make aria2 keep event polling
e->addCommand(new KeepRunningCommand(e->newCUID(), e.get()));
e->addCommand(make_unique<KeepRunningCommand>(e->newCUID(), e.get()));
}
if(config.downloadEventCallback) {
std::shared_ptr<DownloadEventListener> listener