implemented Open syscall