Deleted Added
full compact
svr4_socket.c (116174) svr4_socket.c (130640)
1/*
2 * Copyright (c) 1998 Mark Newton
3 * Copyright (c) 1996 Christos Zoulas.
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 27 unchanged lines hidden (view full) ---

36 * a mapping from inode to pathname, we keep our own table. This is a simple
37 * linked list that contains the pathname, the [device, inode] pair, the
38 * file corresponding to that socket and the process. When the
39 * socket gets closed we remove the item from the list. The list gets loaded
40 * every time a stat(2) call finds a socket.
41 */
42
43#include <sys/cdefs.h>
1/*
2 * Copyright (c) 1998 Mark Newton
3 * Copyright (c) 1996 Christos Zoulas.
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 27 unchanged lines hidden (view full) ---

36 * a mapping from inode to pathname, we keep our own table. This is a simple
37 * linked list that contains the pathname, the [device, inode] pair, the
38 * file corresponding to that socket and the process. When the
39 * socket gets closed we remove the item from the list. The list gets loaded
40 * every time a stat(2) call finds a socket.
41 */
42
43#include <sys/cdefs.h>
44__FBSDID("$FreeBSD: head/sys/compat/svr4/svr4_socket.c 116174 2003-06-10 21:44:29Z obrien $");
44__FBSDID("$FreeBSD: head/sys/compat/svr4/svr4_socket.c 130640 2004-06-17 17:16:53Z phk $");
45
46#include <sys/param.h>
47#include <sys/systm.h>
48#include <sys/queue.h>
49#include <sys/file.h>
50#include <sys/socket.h>
51#include <sys/socketvar.h>
52#include <sys/sysproto.h>

--- 9 unchanged lines hidden (view full) ---

62#include <compat/svr4/svr4_signal.h>
63#include <compat/svr4/svr4_sockmod.h>
64#include <compat/svr4/svr4_proto.h>
65
66struct sockaddr_un *
67svr4_find_socket(td, fp, dev, ino)
68 struct thread *td;
69 struct file *fp;
45
46#include <sys/param.h>
47#include <sys/systm.h>
48#include <sys/queue.h>
49#include <sys/file.h>
50#include <sys/socket.h>
51#include <sys/socketvar.h>
52#include <sys/sysproto.h>

--- 9 unchanged lines hidden (view full) ---

62#include <compat/svr4/svr4_signal.h>
63#include <compat/svr4/svr4_sockmod.h>
64#include <compat/svr4/svr4_proto.h>
65
66struct sockaddr_un *
67svr4_find_socket(td, fp, dev, ino)
68 struct thread *td;
69 struct file *fp;
70 udev_t dev;
70 dev_t dev;
71 ino_t ino;
72{
73 struct svr4_sockcache_entry *e;
74 void *cookie = ((struct socket *)fp->f_data)->so_emuldata;
75
76 if (svr4_str_initialized != 2) {
77 if (atomic_cmpset_acq_int(&svr4_str_initialized, 0, 1)) {
78 DPRINTF(("svr4_find_socket: uninitialized [%p,%d,%d]\n",

--- 104 unchanged lines hidden ---
71 ino_t ino;
72{
73 struct svr4_sockcache_entry *e;
74 void *cookie = ((struct socket *)fp->f_data)->so_emuldata;
75
76 if (svr4_str_initialized != 2) {
77 if (atomic_cmpset_acq_int(&svr4_str_initialized, 0, 1)) {
78 DPRINTF(("svr4_find_socket: uninitialized [%p,%d,%d]\n",

--- 104 unchanged lines hidden ---