Move read_in_full() and write_in_full() to wrapper.c