-Change: split up and refractor.

This should make receiving a bit more thread-safe.