simplify buffer resizing - #860
Conversation
|
@roderickvd I wasn't happy with the match and trying to be "clever" and doing different things when trying to lower or raise the capacity seemed brittle. As rarely as the buffer will ever be resized. (which is currently once) "clever" doesn't save us anything. |
|
Well, amen to that, I didn't like that clippy suggestion either. In this case couldn't we just do |
This way is less verbose, much more simple and less brittle.
Done. |
|
From the discussions previously over in #811, this undoes those "optimisations" correct? As it is deemed these micro optimisation are not really worth the extra cruft? |
Basically yes. This does 99.9% of what I was after, not reallocating if the buffer size doesn't change. |
|
Alright then, let's go for it. |
…-resizing Simplify Alsa buffer resizing
This way is less verbose, much more simple and less brittle.