Fixed regression where operations of stdio no longer worked. Fixes#17
The beginning of what will hopefully be much better test covereage