fixed dumb bug for os_memcpy and also fixed up sloppy merging problems