diff options
author | Michael I. Bushnell <mib@gnu.org> | 1995-11-27 21:15:51 +0000 |
---|---|---|
committer | Michael I. Bushnell <mib@gnu.org> | 1995-11-27 21:15:51 +0000 |
commit | 1487aa101f09c0aa5090cfca1bdd4cca929b08dc (patch) | |
tree | 8f53c5151a9842fb273ea1ef633d2b1e29193abf /pfinet | |
parent | 8192ca49017ca9f7409a603a3bc90646f8e4998b (diff) |
Formerly misc.c.~6~
Diffstat (limited to 'pfinet')
-rw-r--r-- | pfinet/misc.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/pfinet/misc.c b/pfinet/misc.c index 45cf61ae..24058452 100644 --- a/pfinet/misc.c +++ b/pfinet/misc.c @@ -46,7 +46,7 @@ make_sockaddr_port (struct socket *sock, mach_port_t *addr, mach_msg_type_name_t *addrtype) { - char *buf[128]; + char buf[128]; int buflen = 128; error_t err; struct sock_addr *addrstruct; @@ -60,7 +60,7 @@ make_sockaddr_port (struct socket *sock, addrport_class); addrstruct->len = buflen; bcopy (buf, addrstruct->address, buflen); - *addr = ports_get_right (addr); + *addr = ports_get_right (addrstruct); *addrtype = MACH_MSG_TYPE_MAKE_SEND; ports_port_deref (addrstruct); return 0; @@ -107,6 +107,8 @@ clean_socketport (void *arg) user->sock->refcnt--; if (user->sock->refcnt == 0) sock_release (user->sock); + + mutex_unlock (&global_lock); } struct socket * |