fixed minor issue in read and write syscalls