Greatly reducing heap allocations in Cap_handle::loop() by
using a shared buffer between loop() and callback().