IEEE Std 1003.1-2001/Cor 2-2004, item XSH/TC2/D6/5: fdatasync() shall
have cancellation points. Note: we ride today's resolver-related version bumps.
This commit is contained in:
parent
79431a3d74
commit
6b3fbf5d75
@ -1,4 +1,4 @@
|
||||
# $NetBSD: Makefile.inc,v 1.152 2004/04/21 01:05:32 christos Exp $
|
||||
# $NetBSD: Makefile.inc,v 1.153 2004/05/21 17:15:42 kleink Exp $
|
||||
# @(#)Makefile.inc 8.3 (Berkeley) 10/24/94
|
||||
|
||||
# sys sources
|
||||
@ -45,7 +45,7 @@ ASM= access.S acct.S bind.S chdir.S chflags.S \
|
||||
chmod.S chown.S chroot.S clock_getres.S clock_gettime.S \
|
||||
dup.S dup2.S \
|
||||
fchdir.S fchflags.S fchmod.S fchown.S fchroot.S \
|
||||
fdatasync.S fhopen.S fhstat.S fhstatvfs1.S \
|
||||
fhopen.S fhstat.S fhstatvfs1.S \
|
||||
fktrace.S flock.S fpathconf.S __fstat13.S fstatvfs1.S \
|
||||
futimes.S __getcwd.S \
|
||||
getdents.S getfh.S getvfsstat.S getgroups.S getitimer.S \
|
||||
@ -83,7 +83,8 @@ ASM= access.S acct.S bind.S chdir.S chflags.S \
|
||||
timer_create.S timer_delete.S timer_gettime.S timer_getoverrun.S \
|
||||
timer_settime.S
|
||||
|
||||
WEAKASM= accept.S close.S connect.S execve.S fcntl.S fsync.S fsync_range.S \
|
||||
WEAKASM= accept.S close.S connect.S execve.S \
|
||||
fcntl.S fdatasync.S fsync.S fsync_range.S \
|
||||
kill.S msgrcv.S msgsnd.S __msync13.S \
|
||||
nanosleep.S open.S poll.S read.S readv.S \
|
||||
select.S __sigprocmask14.S __sigsuspend14.S sysarch.S \
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: pthread_cancelstub.c,v 1.8 2003/11/24 23:23:17 cl Exp $ */
|
||||
/* $NetBSD: pthread_cancelstub.c,v 1.9 2004/05/21 17:15:42 kleink Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2002 The NetBSD Foundation, Inc.
|
||||
@ -37,7 +37,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__RCSID("$NetBSD: pthread_cancelstub.c,v 1.8 2003/11/24 23:23:17 cl Exp $");
|
||||
__RCSID("$NetBSD: pthread_cancelstub.c,v 1.9 2004/05/21 17:15:42 kleink Exp $");
|
||||
|
||||
/*
|
||||
* This is necessary because the fsync_range() name is always weak (it is
|
||||
@ -74,6 +74,7 @@ int _sys_accept(int, struct sockaddr *, socklen_t *);
|
||||
int _sys_close(int);
|
||||
int _sys_connect(int, const struct sockaddr *, socklen_t);
|
||||
int _sys_fcntl(int, int, ...);
|
||||
int _sys_fdatasync(int);
|
||||
int _sys_fsync(int);
|
||||
int _sys_fsync_range(int, int, off_t, off_t);
|
||||
ssize_t _sys_msgrcv(int, void *, size_t, long, int);
|
||||
@ -155,6 +156,20 @@ fcntl(int fd, int cmd, ...)
|
||||
return retval;
|
||||
}
|
||||
|
||||
int
|
||||
fdatasync(int d)
|
||||
{
|
||||
int retval;
|
||||
pthread_t self;
|
||||
|
||||
self = pthread__self();
|
||||
TESTCANCEL(self);
|
||||
retval = _sys_fdatasync(d);
|
||||
TESTCANCEL(self);
|
||||
|
||||
return retval;
|
||||
}
|
||||
|
||||
int
|
||||
fsync(int d)
|
||||
{
|
||||
@ -372,6 +387,7 @@ writev(int d, const struct iovec *iov, int iovcnt)
|
||||
|
||||
__strong_alias(_close, close)
|
||||
__strong_alias(_fcntl, fcntl)
|
||||
__strong_alias(_fdatasync, fdatasync)
|
||||
__strong_alias(_fsync, fsync)
|
||||
__weak_alias(fsync_range, _fsync_range)
|
||||
__strong_alias(_msgrcv, msgrcv)
|
||||
|
Loading…
Reference in New Issue
Block a user