pthread: avoid copying input packets when possible.