server: Open mem file for write when writing memory.

This commit is contained in:
Andrey Turkin 2009-10-22 17:09:51 +04:00 committed by Alexandre Julliard
parent 44a82859d3
commit 5116dca8e1
1 changed files with 1 additions and 1 deletions

View File

@ -161,7 +161,7 @@ int write_process_memory( struct process *process, client_ptr_t ptr, size_t size
return 0; return 0;
} }
if ((fd = open_proc_as( process, O_RDONLY )) == -1) return 0; if ((fd = open_proc_as( process, O_WRONLY )) == -1) return 0;
ret = pwrite( fd, src, size, (off_t)ptr ); ret = pwrite( fd, src, size, (off_t)ptr );
close( fd ); close( fd );