X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fcopy.cpp;h=cdbbd48f1eead0b7c399a4b7ec7ad534252be2c4;hb=5504b35e6c6cfb1cfa098b94e31cda173cc0482a;hp=c9cb3112ac25465d81ddf3a098eacbb5e46003ed;hpb=291455f435a4319ce3460e2e47d8f036222a3f92;p=builder.git diff --git a/source/copy.cpp b/source/copy.cpp index c9cb311..cdbbd48 100644 --- a/source/copy.cpp +++ b/source/copy.cpp @@ -32,7 +32,8 @@ int Copy::check() void Copy::Worker::main() { - Path::mkpath(copy.src.subpath(0, copy.src.size()-1), 0755); + Path::mkpath(copy.dest.subpath(0, copy.dest.size()-1), 0755); + if(unlink(copy.dest.str().c_str())<0 && errno!=ENOENT) { int err=errno;