avoid working with buffers directly in threadpool - amends #360