setstream has problems