Skip to content
Commit 3e521095 authored by Krzysztof Chruściński's avatar Krzysztof Chruściński Committed by Benjamin Cabé
Browse files

lib: os: mpsc_pbuf: Fix infinite loop during allocation



It was possible that allocation was continuously attempting to find
space. It could happen if allocation interrupted consuming a packet
(which is marked as busy) and there is not enough space to allocate
requested packet but there would be if busy packet was freed.
Algorithm in that case was continuously going through the buffer
in search for packets that can be dropped to find space for the
new packet.

Signed-off-by: default avatarKrzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
parent 398d9e3d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment