Added a persistent state for available() so subsequent hits to .available(1) will work correctly if data is not read after the initial .available(1) execution.