diff options
author | Otto Moerbeek <otto@cvs.openbsd.org> | 2008-10-20 06:19:03 +0000 |
---|---|---|
committer | Otto Moerbeek <otto@cvs.openbsd.org> | 2008-10-20 06:19:03 +0000 |
commit | 4bcb5a17c397dcaa67190d7232da1531718cb04a (patch) | |
tree | f46c0014e1387d40392168750d46e308e77ee51d /lib/libc | |
parent | 4618c2dab1a031ec4c9b0258b787c20d96435993 (diff) |
oops, assign errno the right way. caught by david running regress tests
Diffstat (limited to 'lib/libc')
-rw-r--r-- | lib/libc/stdlib/malloc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libc/stdlib/malloc.c b/lib/libc/stdlib/malloc.c index 4d196edbe09..3f3ec951d5f 100644 --- a/lib/libc/stdlib/malloc.c +++ b/lib/libc/stdlib/malloc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: malloc.c,v 1.102 2008/10/03 19:31:49 otto Exp $ */ +/* $OpenBSD: malloc.c,v 1.103 2008/10/20 06:19:02 otto Exp $ */ /* * Copyright (c) 2008 Otto Moerbeek <otto@drijf.net> * @@ -1180,7 +1180,7 @@ malloc(size_t size) errno = ENOMEM; } if (r != NULL) - saved_errno = errno; + errno = saved_errno; return r; } |