* miscfuncs.cc (__check_invalid_read_ptr_errno): Return error, if any.

This commit is contained in:
Corinna Vinschen 2001-10-22 11:31:39 +00:00
parent d055070040
commit 8b6234ca12
2 changed files with 5 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2001-10-22 Corinna Vinschen <corinna@vinschen.de>
* miscfuncs.cc (__check_invalid_read_ptr_errno): Return error, if any.
2001-10-21 Christopher Faylor <cgf@redhat.com>
* resource.cc (fill_rusage): Perform paranoid zero structure passed to

View File

@ -158,7 +158,7 @@ int __stdcall
__check_invalid_read_ptr_errno (const void *s, unsigned sz)
{
if (!s || IsBadReadPtr ((void *) s, sz))
set_errno (EFAULT);
return set_errno (EFAULT);
return 0;
}