diff options
author | millert <> | 2007-09-03 14:42:44 +0000 |
---|---|---|
committer | millert <> | 2007-09-03 14:42:44 +0000 |
commit | b7b77a835b1b9da7ec261009d15f310b4e4c4249 (patch) | |
tree | ac862acc251d3e1362df57c4b59aea10e2735418 /src/regress/lib/libc/atexit | |
parent | 7e0e6a2581ab1d1bca602865b8e38dfa2f54424a (diff) | |
download | openbsd-b7b77a835b1b9da7ec261009d15f310b4e4c4249.tar.gz openbsd-b7b77a835b1b9da7ec261009d15f310b4e4c4249.tar.bz2 openbsd-b7b77a835b1b9da7ec261009d15f310b4e4c4249.zip |
Adapt atexit() regress to recent changes and add __cxa_atexit() regress.
__cxa_atexit() regress from kurt@
Diffstat (limited to 'src/regress/lib/libc/atexit')
-rw-r--r-- | src/regress/lib/libc/atexit/atexit_test.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/regress/lib/libc/atexit/atexit_test.c b/src/regress/lib/libc/atexit/atexit_test.c index efa2274168..3dd0b62c3e 100644 --- a/src/regress/lib/libc/atexit/atexit_test.c +++ b/src/regress/lib/libc/atexit/atexit_test.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: atexit_test.c,v 1.5 2003/09/02 23:52:16 david Exp $ */ | 1 | /* $OpenBSD: atexit_test.c,v 1.6 2007/09/03 14:42:44 millert Exp $ */ |
2 | 2 | ||
3 | /* | 3 | /* |
4 | * Copyright (c) 2002 Daniel Hartmeier | 4 | * Copyright (c) 2002 Daniel Hartmeier |
@@ -79,7 +79,7 @@ main(int argc, char *argv[]) | |||
79 | /* this is supposed to segfault */ | 79 | /* this is supposed to segfault */ |
80 | if (!strcmp(argv[1], "-invalid-atexit")) { | 80 | if (!strcmp(argv[1], "-invalid-atexit")) { |
81 | signal(SIGSEGV, handle_signal); | 81 | signal(SIGSEGV, handle_signal); |
82 | __atexit->fns[0] = handle_invalid; | 82 | __atexit->fns[0].fn_ptr.std_func = handle_invalid; |
83 | } else if (!strcmp(argv[1], "-invalid-cleanup")) { | 83 | } else if (!strcmp(argv[1], "-invalid-cleanup")) { |
84 | struct atexit *p = __atexit; | 84 | struct atexit *p = __atexit; |
85 | 85 | ||
@@ -88,7 +88,7 @@ main(int argc, char *argv[]) | |||
88 | p = p->next; | 88 | p = p->next; |
89 | if (p == NULL) | 89 | if (p == NULL) |
90 | fprintf(stderr, "p == NULL, no page found\n"); | 90 | fprintf(stderr, "p == NULL, no page found\n"); |
91 | p->fns[0] = handle_invalid; | 91 | p->fns[0].fn_ptr.std_func = handle_invalid; |
92 | } | 92 | } |
93 | __atexit_register_cleanup(handle_cleanup); | 93 | __atexit_register_cleanup(handle_cleanup); |
94 | counter = 0; | 94 | counter = 0; |