This belongs only on the stdin read.
Less completely broken.