projects
/
unix-history
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
tags
|
clone url
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
A litte trouble with declarations of boot() and panic() resolved. gcc-2.5.8
[unix-history]
/
sys
/
kern
/
vfs_syscalls.c
diff --git
a/sys/kern/vfs_syscalls.c
b/sys/kern/vfs_syscalls.c
index
c7e7fd0
..
08824db
100644
(file)
--- a/
sys/kern/vfs_syscalls.c
+++ b/
sys/kern/vfs_syscalls.c
@@
-31,7
+31,7
@@
* SUCH DAMAGE.
*
* from: @(#)vfs_syscalls.c 7.74 (Berkeley) 6/21/91
* SUCH DAMAGE.
*
* from: @(#)vfs_syscalls.c 7.74 (Berkeley) 6/21/91
- * $Id: vfs_syscalls.c,v 1.
6 1993/11/25 01:33:43 wollman
Exp $
+ * $Id: vfs_syscalls.c,v 1.
9 1994/01/19 20:27:38 guido
Exp $
*/
#include "param.h"
*/
#include "param.h"
@@
-47,6
+47,9
@@
#include "uio.h"
#include "malloc.h"
#include "uio.h"
#include "malloc.h"
+static int getvnode(struct filedesc *, int, struct file **);
+static int chdirec(struct nameidata *, struct proc *);
+
/*
* Virtual File System System Calls
*/
/*
* Virtual File System System Calls
*/
@@
-565,7
+568,7
@@
chroot(p, uap, retval)
/*
* Common routine for chroot and chdir.
*/
/*
* Common routine for chroot and chdir.
*/
-int
+
static
int
chdirec(ndp, p)
struct nameidata *ndp;
struct proc *p;
chdirec(ndp, p)
struct nameidata *ndp;
struct proc *p;
@@
-1460,7
+1463,12
@@
utimes(p, uap, retval)
int error;
struct nameidata nd;
int error;
struct nameidata nd;
- if (error = copyin((caddr_t)uap->tptr, (caddr_t)tv, sizeof (tv)))
+ VATTR_NULL(&vattr);
+ if ((caddr_t)uap->tptr == NULL) {
+ microtime(&tv[0]);
+ tv[1] = tv[0];
+ vattr.va_vaflags |= VA_UTIMES_NULL;
+ } else if (error = copyin((caddr_t)uap->tptr, (caddr_t)tv, sizeof (tv)))
return (error);
ndp = &nd;
ndp->ni_nameiop = LOOKUP | FOLLOW | LOCKLEAF;
return (error);
ndp = &nd;
ndp->ni_nameiop = LOOKUP | FOLLOW | LOCKLEAF;
@@
-1473,7
+1481,6
@@
utimes(p, uap, retval)
error = EROFS;
goto out;
}
error = EROFS;
goto out;
}
- VATTR_NULL(&vattr);
vattr.va_atime = tv[0];
vattr.va_mtime = tv[1];
error = VOP_SETATTR(vp, &vattr, p->p_ucred, p);
vattr.va_atime = tv[0];
vattr.va_mtime = tv[1];
error = VOP_SETATTR(vp, &vattr, p->p_ucred, p);
@@
-1913,11
+1920,11
@@
out:
/*
* Convert a user file descriptor to a kernel file entry.
*/
/*
* Convert a user file descriptor to a kernel file entry.
*/
-int
+
static
int
getvnode(fdp, fdes, fpp)
struct filedesc *fdp;
getvnode(fdp, fdes, fpp)
struct filedesc *fdp;
- struct file **fpp;
int fdes;
int fdes;
+ struct file **fpp;
{
struct file *fp;
{
struct file *fp;