Fixed a problem where the Unity program would disconnect every time it didn't have anything to read.