diff --git a/kernel/trunk/posix/posix.inc b/kernel/trunk/posix/posix.inc index 9ef0ba5b7..e4bd6c8aa 100644 --- a/kernel/trunk/posix/posix.inc +++ b/kernel/trunk/posix/posix.inc @@ -83,6 +83,9 @@ sys_read: mov edi, [current_process] mov ebp, [edi + PROC.htab + ecx*4] + stdcall is_region_userspace, ebp, 4 + jz .fail + cmp [ebp + FILED.magic], 'PIPE' jne .fail cmp [ebp + FILED.handle], ecx @@ -113,6 +116,9 @@ sys_write: mov edi, [current_process] mov ebp, [edi + PROC.htab+ecx*4] + stdcall is_region_userspace, ebp, 4 + jz .fail + cmp [ebp + FILED.magic], 'PIPE' jne .fail cmp [ebp + FILED.handle], ecx