File tree Expand file tree Collapse file tree 3 files changed +8
-8
lines changed Expand file tree Collapse file tree 3 files changed +8
-8
lines changed Original file line number Diff line number Diff line change 1818
1919 include :
2020 # Test MSRV
21- - rust : 1.36 .0
21+ - rust : 1.50 .0
2222 TARGET : x86_64-unknown-linux-gnu
2323
2424 # Test nightly but don't fail
Original file line number Diff line number Diff line change @@ -8,8 +8,6 @@ NOR-flash & NAND-flash, both external and internal.
88
99## [ API reference]
1010
11- [ API reference ] : https://docs.rs/embedded-storage
12-
1311## How-to: add a new trait
1412
1513This is the suggested approach to adding a new trait to ` embedded-storage `
@@ -37,7 +35,7 @@ These issues / PRs will be labeled as `proposal`s in the issue tracker.
3735
3836## Minimum Supported Rust Version (MSRV)
3937
40- This crate is guaranteed to compile on stable Rust 1.36 .0 and up. It * might*
38+ This crate is guaranteed to compile on stable Rust 1.50 .0 and up. It * might*
4139compile with older versions but that may change in any new patch release.
4240
4341## License
@@ -55,3 +53,5 @@ at your option.
5553Unless you explicitly state otherwise, any contribution intentionally submitted
5654for inclusion in the work by you, as defined in the Apache-2.0 license, shall be
5755dual licensed as above, without any additional terms or conditions.
56+
57+ [ API reference ] : https://docs.rs/embedded-storage
Original file line number Diff line number Diff line change @@ -225,11 +225,11 @@ where
225225 if is_subset {
226226 // Use `merge_buffer` as allocation for padding `data` to `WRITE_SIZE`
227227 let offset = addr as usize % S :: WRITE_SIZE ;
228- let alligned_end = data. len ( ) % S :: WRITE_SIZE ;
229- self . merge_buffer [ ..S :: WRITE_SIZE ] . fill ( 0xff ) ;
230- self . merge_buffer [ offset..data. len ( ) ] . copy_from_slice ( data) ;
228+ let aligned_end = data. len ( ) % S :: WRITE_SIZE + offset + data . len ( ) ;
229+ self . merge_buffer [ ..aligned_end ] . fill ( 0xff ) ;
230+ self . merge_buffer [ offset..offset + data. len ( ) ] . copy_from_slice ( data) ;
231231 self . storage
232- . try_write ( addr - offset as u32 , & self . merge_buffer [ ..S :: WRITE_SIZE ] ) ?;
232+ . try_write ( addr - offset as u32 , & self . merge_buffer [ ..aligned_end ] ) ?;
233233 } else {
234234 self . storage . try_erase ( page. start , page. end ( ) ) ?;
235235 self . merge_buffer [ ..S :: ERASE_SIZE ]
You can’t perform that action at this time.
0 commit comments