recv() cannot be called multiple times in parallel.
Minor improvements.