diff options
| author | Dario Nieuwenhuis <[email protected]> | 2022-08-31 02:51:15 +0200 |
|---|---|---|
| committer | GitHub <[email protected]> | 2022-08-31 02:51:15 +0200 |
| commit | 2bd7205c79968ba2121ece47a025ac1a90b30893 (patch) | |
| tree | 49f718ce3ec80d8f99059842597fce52023f87fa /src | |
| parent | 69e92e5639e0a86994c9bdf647a0f2d57f768898 (diff) | |
| parent | acaa8b3e8b80ccd49e04a6dc7d595d3a52d1ad0d (diff) | |
Merge pull request #9 from jannic-dev-forks/fix-total-len-slice
Fix calculation of slice index
Diffstat (limited to 'src')
| -rw-r--r-- | src/lib.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib.rs b/src/lib.rs index 8f439cf2f..34170a266 100644 --- a/src/lib.rs +++ b/src/lib.rs | |||
| @@ -762,7 +762,7 @@ where | |||
| 762 | let bus = unsafe { &mut *bus }; | 762 | let bus = unsafe { &mut *bus }; |
| 763 | async { | 763 | async { |
| 764 | bus.write(&[cmd]).await?; | 764 | bus.write(&[cmd]).await?; |
| 765 | bus.write(&buf[..(total_len + 3 / 4)]).await?; | 765 | bus.write(&buf[..(total_len / 4)]).await?; |
| 766 | Ok(()) | 766 | Ok(()) |
| 767 | } | 767 | } |
| 768 | }) | 768 | }) |
