Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Filename/Path maxima #8

Open
nickray opened this issue Apr 14, 2020 · 0 comments
Open

Filename/Path maxima #8

nickray opened this issue Apr 14, 2020 · 0 comments

Comments

@nickray
Copy link
Member

nickray commented Apr 14, 2020

The path::{Filename,Path} objects are not very well-developed yet. I am aware of the following issues:

  • It would be nice to use heapless::Vec for paths, and handle back and forth with C strings in littlefs-sys ergonomically
  • Our Path is more like std::path::PathBuf, we want to "follow std::path as much as appropriate"
  • Upstream has no notion (I believe) of maximum path, whereas we should
  • Upstream uses LFS_NAME_MAX in lfs_info_t (https://github.com/ARMmbed/littlefs/blob/master/lfs.h#L257), which we can only override via littlefs2-sys features. If we don't, then FILENAME_MAX_PLUS_ONE should be removed (set to its default of 256)
  • From the path machinery (ancestors etc.), at least join (or try_join) needs a clean implementation, need to decide how to handle length overflows (maybe just truncate?)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant