mirror of
https://github.com/clangen/musikcube.git
synced 2025-02-18 21:41:21 +00:00
Fixed a bug in filename propagation -- ensure we don't include an
extraneous slash.
This commit is contained in:
parent
fde389a34a
commit
5ab0883735
@ -138,8 +138,9 @@ namespace musik { namespace core { namespace sdk { namespace fs {
|
|||||||
if (!findData.cFileName) {
|
if (!findData.cFileName) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
bool hasTrailingSlash = path[path.size() - 1] == '\\';
|
||||||
std::string relPath8 = str::u16to8(findData.cFileName);
|
std::string relPath8 = str::u16to8(findData.cFileName);
|
||||||
std::string fullPath8 = path + "\\" + relPath8;
|
std::string fullPath8 = path + (hasTrailingSlash ? "" : "\\") + relPath8;
|
||||||
if (interrupt && interrupt()) {
|
if (interrupt && interrupt()) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -187,6 +187,10 @@ void OpenMptIndexerSource::UpdateMetadata(
|
|||||||
}
|
}
|
||||||
|
|
||||||
std::string artist = readMetadataValue(module, "artist");
|
std::string artist = readMetadataValue(module, "artist");
|
||||||
|
if (!artist.size()) {
|
||||||
|
artist = "[unknown mod artist]";
|
||||||
|
}
|
||||||
|
|
||||||
const std::string duration = std::to_string(openmpt_module_get_duration_seconds(module));
|
const std::string duration = std::to_string(openmpt_module_get_duration_seconds(module));
|
||||||
|
|
||||||
auto track = indexer->CreateWriter();
|
auto track = indexer->CreateWriter();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user