]> git.tdb.fi Git - builder.git/blobdiff - source/copy.cpp
Make sure that symlinks point to the right place
[builder.git] / source / copy.cpp
index 0073320504b0daff45e2c9577a93e9ab4c095dff..75d047df7ef50c6371835f456a747f2c34b6121a 100644 (file)
@@ -87,6 +87,8 @@ void Copy::Worker::main()
        if(!link.empty())
        {
                FS::Path relpath = FS::relative(dst_path, FS::dirname(link));
+               if(FS::exists(link))
+                       FS::unlink(link);
                symlink(relpath.str().c_str(), link.str().c_str());
        }