haiwen / seafdav

Seafile webdav server
Other
84 stars 68 forks source link

Encode path to NFC #64

Closed feiniks closed 2 years ago

shoeper commented 2 years ago

I'm not sure is backwards compatible. Can it lead to some previously stored files cannot be accessed anymore?

Here was a larger discussion on the topic in nextcloud https://github.com/owncloud/core/issues/21365

https://stackoverflow.com/questions/15985888/when-to-use-unicode-normalization-forms-nfc-and-nfd

http://www.unicode.org/reports/tr15/

But looks like NFC is suitable for filenames.

killing commented 2 years ago

@shoeper You may be misled by the commit title. All file paths in Seafile server are encoded in utf-8 NFC already. This commit solves an issue when mounting seafdav on macOS, which sends file paths in NFD normalization.