diff options
| author | deraadt <> | 2022-10-22 15:21:25 +0000 |
|---|---|---|
| committer | deraadt <> | 2022-10-22 15:21:25 +0000 |
| commit | 425b9864e075e414ba80737267bd09efdff37c1f (patch) | |
| tree | cb808dd0cbd49558567901756fc7810c7500894e | |
| parent | 39854bb4d7997af0b835a7ec170c51fb922a960e (diff) | |
| download | openbsd-425b9864e075e414ba80737267bd09efdff37c1f.tar.gz openbsd-425b9864e075e414ba80737267bd09efdff37c1f.tar.bz2 openbsd-425b9864e075e414ba80737267bd09efdff37c1f.zip | |
In __cxa_atexit(), there is no need to initialize local pointer before
the lock, when it is correctly initialized after the lock
ok otto millert
Diffstat (limited to '')
| -rw-r--r-- | src/lib/libc/stdlib/atexit.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/libc/stdlib/atexit.c b/src/lib/libc/stdlib/atexit.c index ea9dd129c1..81d2dc2476 100644 --- a/src/lib/libc/stdlib/atexit.c +++ b/src/lib/libc/stdlib/atexit.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: atexit.c,v 1.27 2017/12/16 20:06:56 guenther Exp $ */ | 1 | /* $OpenBSD: atexit.c,v 1.28 2022/10/22 15:21:25 deraadt Exp $ */ |
| 2 | /* | 2 | /* |
| 3 | * Copyright (c) 2002 Daniel Hartmeier | 3 | * Copyright (c) 2002 Daniel Hartmeier |
| 4 | * All rights reserved. | 4 | * All rights reserved. |
| @@ -67,7 +67,7 @@ struct atfork_listhead _atfork_list = TAILQ_HEAD_INITIALIZER(_atfork_list); | |||
| 67 | int | 67 | int |
| 68 | __cxa_atexit(void (*func)(void *), void *arg, void *dso) | 68 | __cxa_atexit(void (*func)(void *), void *arg, void *dso) |
| 69 | { | 69 | { |
| 70 | struct atexit *p = __atexit; | 70 | struct atexit *p; |
| 71 | struct atexit_fn *fnp; | 71 | struct atexit_fn *fnp; |
| 72 | int pgsize = getpagesize(); | 72 | int pgsize = getpagesize(); |
| 73 | int ret = -1; | 73 | int ret = -1; |
