Searched refs:fd (Results 176 - 200 of 1919) sorted by relevance

1234567891011>>

/freebsd-10.1-release/usr.sbin/bluetooth/sdpd/
H A Dserver.c54 static void server_accept_client (server_p srv, int32_t fd);
55 static int32_t server_process_request (server_p srv, int32_t fd);
56 static int32_t server_send_error_response (server_p srv, int32_t fd,
58 static void server_close_fd (server_p srv, int32_t fd);
171 log_crit("Could not allocate fd index");
228 int fd; local
232 for (fd = 0; fd < srv->maxfd + 1; fd ++)
233 if (srv->fdidx[fd]
250 int32_t n, fd; local
290 server_accept_client(server_p srv, int32_t fd) argument
406 server_process_request(server_p srv, int32_t fd) argument
535 server_send_error_response(server_p srv, int32_t fd, uint16_t error) argument
562 server_close_fd(server_p srv, int32_t fd) argument
[all...]
H A Dssr.c51 server_prepare_service_search_response(server_p srv, int32_t fd) argument
55 uint8_t *rsp = srv->fdidx[fd].rsp;
118 if (srv->fdidx[fd].rsp_cs != cs)
120 if (srv->fdidx[fd].rsp_size > 0)
201 srv->fdidx[fd].rsp_limit = srv->fdidx[fd].omtu - sizeof(sdp_pdu_t) - 4;
202 srv->fdidx[fd].rsp_size = ptr - rsp;
203 srv->fdidx[fd].rsp_cs = 0;
213 server_send_service_search_response(server_p srv, int32_t fd) argument
215 uint8_t *rsp = srv->fdidx[fd]
[all...]
/freebsd-10.1-release/usr.sbin/apm/
H A Dapm.c116 apm_suspend(int fd) argument
118 if (ioctl(fd, APMIO_SUSPEND, NULL) == -1)
123 apm_standby(int fd) argument
125 if (ioctl(fd, APMIO_STANDBY, NULL) == -1)
130 apm_getinfo(int fd, apm_info_t aip) argument
132 if (ioctl(fd, APMIO_GETINFO, aip) == -1)
137 apm_enable(int fd, int enable) argument
140 if (ioctl(fd, APMIO_ENABLE) == -1)
143 if (ioctl(fd, APMIO_DISABLE) == -1)
193 print_all_info(int fd, apm_info_ argument
334 apm_display(int fd, int newstate) argument
341 apm_haltcpu(int fd, int enable) argument
353 apm_set_timer(int fd, int delta) argument
383 int c, fd; local
[all...]
/freebsd-10.1-release/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/privs/
H A Dtst.fds.ksh31 #define DUMPFIELD(fd, fmt, field) \
33 printf("%d: field =fmt\n", fd, fds[fd].field);
39 #define DUMP(fd) \
40 DUMPFIELD(fd, %s, fi_name); \
41 DUMPFIELD(fd, %s, fi_dirname); \
42 DUMPFIELD(fd, %s, fi_pathname); \
43 DUMPFIELD(fd, %d, fi_offset); \
44 DUMPFIELD(fd, %s, fi_fs); \
45 DUMPFIELD(fd,
[all...]
/freebsd-10.1-release/contrib/ipfilter/ipsd/
H A Dsbpf.c91 int readloop(fd, port, dst)
92 int fd, port;
101 while ((cc = read(fd, buf, bufsize)) >= 0) {
131 int fd; local
133 if ((fd = open(bpfname, O_RDWR)) < 0)
140 int fd = -1, i; local
145 if ((fd = open(bpfname, O_RDWR)) >= 0)
155 if (ioctl(fd, BIOCVERSION, (caddr_t)&bv) < 0)
171 if (ioctl(fd, BIOCSETIF, &ifr) == -1)
173 fprintf(stderr, "%s(%d):", ifr.ifr_name, fd);
[all...]
/freebsd-10.1-release/contrib/libarchive/libarchive/test/
H A Dtest_write_disk_failures.c35 int fd;
44 fd = open("dir/testfile", O_WRONLY | O_CREAT | O_BINARY, 0777);
45 if (fd >= 0) {
47 close(fd);
/freebsd-10.1-release/contrib/netcat/
H A Datomicio.c39 atomicio(ssize_t (*f) (int, void *, size_t), int fd, void *_s, size_t n) argument
46 pfd.fd = fd;
49 res = (f) (fd, s + pos, n - pos);
/freebsd-10.1-release/contrib/tcp_wrappers/
H A Dclean_exit.c33 request->sink(request->fd);
/freebsd-10.1-release/crypto/heimdal/lib/roken/
H A Dmkstemp.c63 int fd; local
64 fd = open(template, O_RDWR | O_CREAT | O_EXCL, 0600);
65 if(fd >= 0 || errno != EEXIST)
66 return fd;
/freebsd-10.1-release/games/random/
H A Drandomize_fd.h49 int randomize_fd(int fd, int type, int unique, double denom);
/freebsd-10.1-release/lib/libstand/
H A Dwrite.c70 write(fd, dest, bcount)
71 int fd;
75 struct open_file *f = &files[fd];
78 if ((unsigned)fd >= SOPEN_MAX || !(f->f_flags & F_WRITE)) {
/freebsd-10.1-release/sbin/nvmecontrol/
H A Dnvmecontrol.h65 int open_dev(const char *str, int *fd, int show_error, int exit_on_error);
67 void read_controller_data(int fd, struct nvme_controller_data *cdata);
68 void read_namespace_data(int fd, int nsid, struct nvme_namespace_data *nsdata);
70 void read_logpage(int fd, uint8_t log_page, int nsid, void *payload,
/freebsd-10.1-release/sys/sys/
H A Dmqueue.h43 extern void (*mq_fdclose)(struct thread *td, int fd, struct file *fp);
/freebsd-10.1-release/tools/tools/mwl/mwlstats/
H A Dstatfoo.c89 statfoo_print_header(struct statfoo *sf, FILE *fd) argument
96 fprintf(fd, "%*s", f->width, f->label);
98 putc(*cp, fd);
100 putc('\n', fd);
104 statfoo_print_current(struct statfoo *sf, FILE *fd) argument
113 fprintf(fd, "%*s", f->width, buf);
115 putc(*cp, fd);
117 putc('\n', fd);
121 statfoo_print_total(struct statfoo *sf, FILE *fd) argument
130 fprintf(fd, "
138 statfoo_print_verbose(struct statfoo *sf, FILE *fd) argument
150 statfoo_print_fields(struct statfoo *sf, FILE *fd) argument
[all...]
/freebsd-10.1-release/usr.bin/fsync/
H A Dfsync.c44 int fd; local
55 if ((fd = open(argv[i], O_RDONLY)) == -1) {
62 if (fsync(fd) == -1) {
67 close(fd);
/freebsd-10.1-release/usr.bin/gcore/
H A Dextern.h38 void (*dump)(int efd, int fd, pid_t pid);
/freebsd-10.1-release/usr.sbin/bluetooth/btpand/
H A Dserver.c153 int fd, n; local
157 fd = accept(s, (struct sockaddr *)&ra, &len);
158 if (fd == -1)
162 if (ioctl(fd, FIONBIO, &n) == -1) {
164 close(fd);
169 if (getsockopt(fd, SOL_L2CAP, SO_L2CAP_IMTU, &mru, &len) == -1) {
171 close(fd);
176 close(fd);
181 if (getsockopt(fd, SOL_SOCKET, SO_RCVBUF, &n, &len) == -1) {
183 close(fd);
[all...]
/freebsd-10.1-release/usr.sbin/lptcontrol/
H A Dlptcontrol.c60 int fd; local
99 if ((fd = open(device, O_WRONLY)) < 0)
101 if (ioctl(fd, LPT_IRQ, &irq_status) < 0)
103 close(fd);
/freebsd-10.1-release/contrib/ntp/sntp/libevent/
H A Devmap-internal.h31 * An event_map is a utility structure to map each fd or signal to zero or
54 underlying eventops about the fd if its state has changed.
59 @param fd the file descriptor corresponding to ev.
62 int evmap_io_add_(struct event_base *base, evutil_socket_t fd, struct event *ev);
65 underlying eventops about the fd if its state has changed.
68 @param fd the file descriptor corresponding to ev.
71 int evmap_io_del_(struct event_base *base, evutil_socket_t fd, struct event *ev);
72 /** Active the set of events waiting on an event_base for a given fd.
75 @param fd the file descriptor that has become active.
78 void evmap_io_active_(struct event_base *base, evutil_socket_t fd, shor
[all...]
/freebsd-10.1-release/contrib/ntp/ntpd/
H A Drefclock_arbiter.c23 #define write(fd, data, octets) async_write(fd, data, octets)
159 int fd; local
166 fd = refclock_open(device, SPEED232, LDISC_CLK);
167 if (fd <= 0)
178 pp->io.fd = fd;
180 close(fd);
181 pp->io.fd = -1;
195 close(fd);
[all...]
/freebsd-10.1-release/cddl/contrib/opensolaris/cmd/dtrace/test/cmd/baddof/
H A Dbaddof.c55 corrupt(int fd, unsigned char *buf, int len) argument
77 if ((rv = ioctl(fd, DTRACEIOC_ENABLE, buf)) == -1) {
99 close(fd);
106 if (new != fd) {
107 dup2(new, fd);
135 if ((rv = ioctl(fd, DTRACEIOC_ENABLE, buf)) > 0) {
159 int err, fd, len; local
196 fd = open("/devices/pseudo/dtrace@0:dtrace", O_RDWR);
198 if (fd == -1)
201 corrupt(fd, cop
[all...]
/freebsd-10.1-release/contrib/libarchive/libarchive/
H A Darchive_read_open_fd.c54 int fd; member in struct:read_fd_data
65 archive_read_open_fd(struct archive *a, int fd, size_t block_size) argument
72 if (fstat(fd, &st) != 0) {
73 archive_set_error(a, errno, "Can't stat fd %d", fd);
87 mine->fd = fd;
100 setmode(mine->fd, O_BINARY);
118 bytes_read = read(mine->fd, mine->buffer, mine->block_size);
122 archive_set_error(a, errno, "Error reading fd
[all...]
/freebsd-10.1-release/contrib/traceroute/
H A Difaddrlist.c72 register int fd, nipaddr; local
85 fd = socket(AF_INET, SOCK_DGRAM, 0);
86 if (fd < 0) {
93 if (ioctl(fd, SIOCGIFCONF, (char *)&ifc) < 0 ||
102 (void)close(fd);
130 if (ioctl(fd, SIOCGIFFLAGS, (char *)&ifr) < 0) {
136 (void)close(fd);
152 if (ioctl(fd, SIOCGIFADDR, (char *)&ifr) < 0) {
155 (void)close(fd);
162 (void)close(fd);
[all...]
/freebsd-10.1-release/lib/libusbhid/
H A Ddescr.c47 hid_set_immed(int fd, int enable) argument
50 ret = ioctl(fd, USB_SET_IMMED, &enable);
53 ret = hid_set_immed_compat7(fd, enable);
59 hid_get_report_id(int fd) argument
68 if ((rep = hid_get_report_desc(fd)) == NULL)
85 ret = ioctl(fd, USB_GET_REPORT_ID, &temp);
88 ret = hid_get_report_id_compat7(fd);
97 hid_get_report_desc(int fd) argument
108 if (ioctl(fd, USB_GET_REPORT_DESC, &ugd) < 0) {
112 return (hid_get_report_desc_compat7(fd));
[all...]
/freebsd-10.1-release/lib/libutil/tests/
H A Dflopen_test.c52 int fd; local
55 fd = flopen(fn, O_RDWR|O_CREAT, 0640);
56 if (fd < 0) {
59 close(fd);
73 int fd; local
75 fd = open(fn, O_RDWR|O_CREAT, 0640);
76 if (fd < 0) {
79 close(fd);
80 fd = flopen(fn, O_RDWR);
81 if (fd <
[all...]

Completed in 329 milliseconds

1234567891011>>