Fixed cappedstream bug.