2010-05-06 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>

Removed useless pathJoin
	* src/MetalinkParserController.cc
pull/1/head
Tatsuhiro Tsujikawa 2010-05-06 14:25:51 +00:00
parent 460ee92644
commit 0bc298df00
2 changed files with 7 additions and 6 deletions

View File

@ -1,3 +1,8 @@
2010-05-06 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Removed useless pathJoin
* src/MetalinkParserController.cc
2010-05-06 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Fixed the bug that name attribute of file element in Metalink file

View File

@ -85,14 +85,10 @@ void MetalinkParserController::setFileNameOfEntry(const std::string& filename)
if(_tEntry.isNull()) {
return;
}
std::vector<std::string> elements;
util::split(filename, std::back_inserter(elements), "/");
std::string path = util::joinPath(elements.begin(), elements.end());
if(_tEntry->file.isNull()) {
_tEntry->file.reset(new FileEntry(util::escapePath(path), 0, 0));
_tEntry->file.reset(new FileEntry(util::escapePath(filename), 0, 0));
} else {
_tEntry->file->setPath(util::escapePath(path));
_tEntry->file->setPath(util::escapePath(filename));
}
}