Changed logs to specification, changed mergePieces

merge pieces will now be called whenever the peer gets all the needed
pieces, the output file will be the same filename as the original