Bug 388465 - VFAT-safe file names cannot end with dot or space
Summary: VFAT-safe file names cannot end with dot or space
Status: RESOLVED FIXED
Alias: None
Product: amarok
Classification: Applications
Component: Collections/Organize Files Dialog (show other bugs)
Version: 2.8.0
Platform: Other Linux
: NOR minor
Target Milestone: 2.9
Assignee: Amarok Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-01-02 21:03 UTC by Stefano Pettini
Modified: 2018-05-13 20:54 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 2.9.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Stefano Pettini 2018-01-02 21:03:23 UTC
According to Microsoft documentation, not only the following characters are not supported in VFAT <>:"/\|?* but also filenames cannot end with space of dot.

This last part is not corrected by the "VFAT-safe file name" option when renaming tracks. For example, songs ending with "..." create a problem.
Comment 2 Stefano Pettini 2018-02-22 23:46:57 UTC
Git commit fc9cce2bd8483a0473ea9b2514f239c07625466d by Stefano Pettini.
Committed on 22/02/2018 at 23:45.
Pushed by spettini into branch 'master'.

VFAT-safe file and directory names cannot end with dot

This adds special handling of trailing dots to vfatPath(),
that are replaced with '_'. This doesn't affect '.' and '..'.

  ../Music/R.E.M./Monster -> ../Music/R.E.M_/Monster

Unit tests updated, minor bugs when vfatPath() is invoked
with a PathSeparatorBehaviour not matching the system
detected by improving unit tests and fixed.

M  +23   -11   src/core/support/Amarok.cpp
M  +43   -11   tests/TestAmarok.cpp

https://commits.kde.org/amarok/fc9cce2bd8483a0473ea9b2514f239c07625466d