Pepper IO with assertions.

IO seems to be sigsegv-ing with wine/mingw, so see if we can find out why.