Skip to content

v0.4.0

Compare
Choose a tag to compare
@nickray nickray released this 07 Feb 17:02
· 54 commits to main since this release

[v0.4.0] - 2023-02-07

This release fixes an overflow of the lookahead buffer. Users are advised to
upgrade from previous releases to avoid filesystem corruption.

Added

  • Added Path::from_str_with_nul and path! to create Path instances from
    str.
  • Added Eq and PartialEq implementations for Path.

Changed

  • Made Path::from_bytes_with_nul_unchecked const.
  • [breaking] Replaced LOOKAHEADWORDS_SIZE (measured in multiples of four
    bytes) with LOOKAHEAD_SIZE (measured in multiples of eight bytes) in
    driver::Storage so that all possible values are valid. (See the lookahead
    size fix below for context.)
  • [breaking] Require &mut self in driver::Storage::read for compatibility
    with embedded_storage.

Fixed

  • Fixed the lookahead size reported to littlefs2-sys. Previously, the
    reported size was too large by the factor of 8, potentially leading to a
    buffer overflow causing filesystem corruption. Fixing this means that
    Storage::LOOKAHEADWORD_SIZE values that are not a multiple of 2 can now
    lead to an error. Fixes #16.
  • Propagate errors in littlefs callbacks instead of panicking.