Skip to content

Commit

Permalink
Sanitize picture file names before saving them.
Browse files Browse the repository at this point in the history
  • Loading branch information
enzo1982 committed Mar 3, 2020
1 parent 26efb69 commit 1cc05a1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions runtime/common/metadata/track.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* BoCA - BonkEnc Component Architecture
* Copyright (C) 2007-2019 Robert Kausch <[email protected]>
* Copyright (C) 2007-2020 Robert Kausch <[email protected]>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
Expand Down Expand Up @@ -349,7 +349,7 @@ Bool BoCA::Track::SaveCoverArtFiles(const String &folder)
*/
String file = String(folder).Append(folder.EndsWith(Directory::GetDirectoryDelimiter()) ? NIL : Directory::GetDirectoryDelimiter()).Append(fileName);

picture.SaveToFile(Utilities::CreateDirectoryForFile(file));
picture.SaveToFile(Utilities::CreateDirectoryForFile(Utilities::NormalizeFileName(file)));
}

return True;
Expand Down

0 comments on commit 1cc05a1

Please sign in to comment.