Fix bufferlist

* Merge creesch's PR (#155)
* Revert my previous commit that broke the bufferlist functionality