xv6

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 51716a869c2e596b43dcc9d030a6626b29cf4829
parent 856e1fc1ad22a24bd71c706bc06ba868e044ddc8
Author: rsc <rsc>
Date:   Sun, 16 Jul 2006 01:49:03 +0000

Rename fd_reference to more suggestive fd_incref.
(Fd_reference sounds like it might just return the ref count.)

Diffstat:
Mdefs.h | 2+-
Mfd.c | 2+-
Mproc.c | 2+-
3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/defs.h b/defs.h @@ -84,7 +84,7 @@ struct fd * fd_alloc(); void fd_close(struct fd *); int fd_read(struct fd *fd, char *addr, int n); int fd_write(struct fd *fd, char *addr, int n); -void fd_reference(struct fd *fd); +void fd_incref(struct fd *fd); // ide.c void ide_init(void); diff --git a/fd.c b/fd.c @@ -99,7 +99,7 @@ fd_close(struct fd *fd) } void -fd_reference(struct fd *fd) +fd_incref(struct fd *fd) { acquire(&fd_table_lock); if(fd->count < 1 || fd->type == FD_CLOSED) diff --git a/proc.c b/proc.c @@ -118,7 +118,7 @@ copyproc(struct proc* p) for(i = 0; i < NOFILE; i++){ np->fds[i] = p->fds[i]; if(np->fds[i]) - fd_reference(np->fds[i]); + fd_incref(np->fds[i]); } return np;