From 12c19060a161e9f11cc19c7b6a0f461c7d7436e1 Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Thu, 28 Dec 1995 05:24:25 +0000 Subject: (end_using_protid_port): Don't calls ports_port_deref if CRED is null. --- libdiskfs/priv.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'libdiskfs/priv.h') diff --git a/libdiskfs/priv.h b/libdiskfs/priv.h index 26b61414..fc5e8bdd 100644 --- a/libdiskfs/priv.h +++ b/libdiskfs/priv.h @@ -36,7 +36,7 @@ extern struct argp_option diskfs_common_options[]; /* Needed for MiG. */ typedef struct protid *protid_t; -/* Called by MiG to translate ports into struct protid *. +/* Called by MiG to translate ports into struct protid *. fsmutations.h arranges for this to happen for the io and fs interfaces. */ extern inline struct protid * @@ -51,7 +51,8 @@ begin_using_protid_port (file_t port) extern inline void end_using_protid_port (struct protid *cred) { - ports_port_deref (cred); + if (cred) + ports_port_deref (cred); } /* Actually read or write a file. The file size must already permit @@ -61,7 +62,7 @@ end_using_protid_port (struct protid *cred) DIR is set for writing and clear for reading. The inode must be locked. If NOTIME is set, then don't update the access or modify times on the file. */ -error_t _diskfs_rdwr_internal (struct node *np, char *data, int offset, +error_t _diskfs_rdwr_internal (struct node *np, char *data, int offset, int amt, int dir, int notime); /* Clean routine for control port. */ -- cgit v1.2.3