added check for TCP all done, and missing packets