Fixed the read_proc and write_proc functions. They are fully correct now.