Factored file receiving in Work Queue for consistency and clarity.  Fixed a cache leak, memory leaks, and other problems that were revealed along the way.