Module Name: src
Committed By: reinoud
Date: Wed Jan 11 12:37:50 UTC 2012
Modified Files:
src/sys/arch/usermode/include: thunk.h
src/sys/arch/usermode/usermode: thunk.c
Log Message:
Add thunk_close()
To generate a diff of this commit:
cvs rdiff -u -r1.58 -r1.59 src/sys/arch/usermode/include/thunk.h
cvs rdiff -u -r1.76 -r1.77 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.58 src/sys/arch/usermode/include/thunk.h:1.59
--- src/sys/arch/usermode/include/thunk.h:1.58 Tue Jan 10 12:04:56 2012
+++ src/sys/arch/usermode/include/thunk.h Wed Jan 11 12:37:50 2012
@@ -1,4 +1,4 @@
-/* $NetBSD: thunk.h,v 1.58 2012/01/10 12:04:56 reinoud Exp $ */
+/* $NetBSD: thunk.h,v 1.59 2012/01/11 12:37:50 reinoud Exp $ */
/*-
* Copyright (c) 2011 Jared D. McNeill <[email protected]>
@@ -115,6 +115,7 @@ void thunk_putchar(int);
int thunk_execv(const char *, char * const []);
int thunk_open(const char *, int, mode_t);
+int thunk_close(int);
int thunk_fstat_getsize(int, off_t *, ssize_t *);
ssize_t thunk_pread(int, void *, size_t, off_t);
ssize_t thunk_pwrite(int, const void *, size_t, off_t);
Index: src/sys/arch/usermode/usermode/thunk.c
diff -u src/sys/arch/usermode/usermode/thunk.c:1.76 src/sys/arch/usermode/usermode/thunk.c:1.77
--- src/sys/arch/usermode/usermode/thunk.c:1.76 Tue Jan 10 12:04:56 2012
+++ src/sys/arch/usermode/usermode/thunk.c Wed Jan 11 12:37:50 2012
@@ -1,4 +1,4 @@
-/* $NetBSD: thunk.c,v 1.76 2012/01/10 12:04:56 reinoud Exp $ */
+/* $NetBSD: thunk.c,v 1.77 2012/01/11 12:37:50 reinoud Exp $ */
/*-
* Copyright (c) 2011 Jared D. McNeill <[email protected]>
@@ -28,7 +28,7 @@
#include <sys/cdefs.h>
#ifdef __NetBSD__
-__RCSID("$NetBSD: thunk.c,v 1.76 2012/01/10 12:04:56 reinoud Exp $");
+__RCSID("$NetBSD: thunk.c,v 1.77 2012/01/11 12:37:50 reinoud Exp $");
#endif
#include <sys/types.h>
@@ -482,6 +482,12 @@ thunk_open(const char *path, int flags,
}
int
+thunk_close(int fd)
+{
+ return close(fd);
+}
+
+int
thunk_fstat_getsize(int fd, off_t *size, ssize_t *blksize)
{
struct stat st;