X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fcopy.cpp;h=0073320504b0daff45e2c9577a93e9ab4c095dff;hb=f7e0a54c49480981a8d9bec064375323fce0aaf1;hp=30ab60e446b6ae8353112a5e707a8fb21ddf7355;hpb=4a46970b4a036e432d0bf7af5d5960ddf59082d3;p=builder.git diff --git a/source/copy.cpp b/source/copy.cpp index 30ab60e..0073320 100644 --- a/source/copy.cpp +++ b/source/copy.cpp @@ -19,8 +19,7 @@ Copy::Copy(Builder &b): Target *Copy::create_target(const list &sources, const string &arg) const { FileTarget &file_tgt = dynamic_cast(*sources.front()); - const SourcePackage &pkg = dynamic_cast(*file_tgt.get_package()); - InstalledFile *inst = new InstalledFile(builder, pkg, file_tgt, arg); + InstalledFile *inst = new InstalledFile(builder, *file_tgt.get_package(), file_tgt, arg); inst->set_tool(*this); return inst; } @@ -35,9 +34,7 @@ Task *Copy::run(const Target &target) const Copy::Worker::Worker(const InstalledFile &t): target(t) -{ - launch(); -} +{ } void Copy::Worker::main() {