Module Name: src Committed By: reinoud Date: Sat Aug 27 21:14:15 UTC 2011
Modified Files: src/sys/arch/usermode/include: thunk.h src/sys/arch/usermode/usermode: thunk.c Log Message: Add a thunk_atexit() so ucontext() ends can be dealt with as they should To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.18 src/sys/arch/usermode/include/thunk.h cvs rdiff -u -r1.19 -r1.20 src/sys/arch/usermode/usermode/thunk.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/usermode/include/thunk.h diff -u src/sys/arch/usermode/include/thunk.h:1.17 src/sys/arch/usermode/include/thunk.h:1.18 --- src/sys/arch/usermode/include/thunk.h:1.17 Thu Aug 25 11:06:29 2011 +++ src/sys/arch/usermode/include/thunk.h Sat Aug 27 21:14:15 2011 @@ -1,4 +1,4 @@ -/* $NetBSD: thunk.h,v 1.17 2011/08/25 11:06:29 jmcneill Exp $ */ +/* $NetBSD: thunk.h,v 1.18 2011/08/27 21:14:15 reinoud Exp $ */ /*- * Copyright (c) 2011 Jared D. McNeill <jmcne...@invisible.ca> @@ -77,6 +77,7 @@ int thunk_sigaction(int, const struct sigaction *, struct sigaction *); void thunk_signal(int, void (*)(int)); +int thunk_atexit(void (*function)(void)); int thunk_aio_read(struct aiocb *); int thunk_aio_write(struct aiocb *); Index: src/sys/arch/usermode/usermode/thunk.c diff -u src/sys/arch/usermode/usermode/thunk.c:1.19 src/sys/arch/usermode/usermode/thunk.c:1.20 --- src/sys/arch/usermode/usermode/thunk.c:1.19 Thu Aug 25 11:06:29 2011 +++ src/sys/arch/usermode/usermode/thunk.c Sat Aug 27 21:14:15 2011 @@ -1,4 +1,4 @@ -/* $NetBSD: thunk.c,v 1.19 2011/08/25 11:06:29 jmcneill Exp $ */ +/* $NetBSD: thunk.c,v 1.20 2011/08/27 21:14:15 reinoud Exp $ */ /*- * Copyright (c) 2011 Jared D. McNeill <jmcne...@invisible.ca> @@ -27,7 +27,7 @@ */ #include <sys/cdefs.h> -__RCSID("$NetBSD: thunk.c,v 1.19 2011/08/25 11:06:29 jmcneill Exp $"); +__RCSID("$NetBSD: thunk.c,v 1.20 2011/08/27 21:14:15 reinoud Exp $"); #include <sys/types.h> #include <sys/ansi.h> @@ -265,6 +265,12 @@ } int +thunk_atexit(void (*function)(void)) +{ + return atexit(function); +} + +int thunk_aio_read(struct aiocb *aiocbp) { return aio_read(aiocbp);