Skip to content

Commit cdcfcb9

Browse files
authored
Reduce RST cancel prefix to 32 bytes (#697)
Reduce RST cancel prefix to 32 bytes
1 parent 1ad5b57 commit cdcfcb9

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

bellows/ash.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -719,4 +719,4 @@ async def send_data(self, data: bytes) -> None:
719719

720720
def send_reset(self) -> None:
721721
# Some adapters seem to send a NAK immediately but still process the reset frame
722-
self._write_frame(RstFrame(), prefix=40 * (Reserved.CANCEL,))
722+
self._write_frame(RstFrame(), prefix=32 * (Reserved.CANCEL,))

tests/test_ash.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -438,7 +438,7 @@ async def test_ash_protocol_startup(caplog):
438438

439439
assert ezsp.reset_received.mock_calls == [call(t.NcpResetCode.RESET_SOFTWARE)]
440440
assert protocol._write_frame.mock_calls == [
441-
call(ash.RstFrame(), prefix=40 * (ash.Reserved.CANCEL,))
441+
call(ash.RstFrame(), prefix=32 * (ash.Reserved.CANCEL,))
442442
]
443443

444444
protocol._write_frame.reset_mock()

0 commit comments

Comments
 (0)