Deleted Added
full compact
res_send.c (163661) res_send.c (165258)
1/*
2 * Copyright (c) 1985, 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

65 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
66 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
67 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
68 * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
69 */
70
71#if defined(LIBC_SCCS) && !defined(lint)
72static const char sccsid[] = "@(#)res_send.c 8.1 (Berkeley) 6/4/93";
1/*
2 * Copyright (c) 1985, 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

65 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
66 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
67 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
68 * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
69 */
70
71#if defined(LIBC_SCCS) && !defined(lint)
72static const char sccsid[] = "@(#)res_send.c 8.1 (Berkeley) 6/4/93";
73static const char rcsid[] = "$Id: res_send.c,v 1.5.2.2.4.8 2006/03/08 04:13:31 marka Exp $";
73static const char rcsid[] = "$Id: res_send.c,v 1.5.2.2.4.9 2006/10/16 23:00:50 marka Exp $";
74#endif /* LIBC_SCCS and not lint */
75#include <sys/cdefs.h>
74#endif /* LIBC_SCCS and not lint */
75#include <sys/cdefs.h>
76__FBSDID("$FreeBSD: head/lib/libc/resolv/res_send.c 163661 2006-10-24 14:41:43Z ume $");
76__FBSDID("$FreeBSD: head/lib/libc/resolv/res_send.c 165258 2006-12-15 20:59:55Z ume $");
77
78/*
79 * Send query to name server and wait for reply.
80 */
81
82#include "port_before.h"
83#ifndef USE_KQUEUE
84#include "fd_setsize.h"

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

308 int kq;
309#endif
310 char abuf[NI_MAXHOST];
311
312#ifdef USE_POLL
313 highestFD = sysconf(_SC_OPEN_MAX) - 1;
314#endif
315
77
78/*
79 * Send query to name server and wait for reply.
80 */
81
82#include "port_before.h"
83#ifndef USE_KQUEUE
84#include "fd_setsize.h"

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

308 int kq;
309#endif
310 char abuf[NI_MAXHOST];
311
312#ifdef USE_POLL
313 highestFD = sysconf(_SC_OPEN_MAX) - 1;
314#endif
315
316 if (statp->nscount == 0) {
316 /* No name servers or res_init() failure */
317 if (statp->nscount == 0 || EXT(statp).ext == NULL) {
317 errno = ESRCH;
318 return (-1);
319 }
320 if (anssiz < HFIXEDSZ) {
321 errno = EINVAL;
322 return (-1);
323 }
324 DprintQ((statp->options & RES_DEBUG) || (statp->pfcode & RES_PRF_QUERY),

--- 843 unchanged lines hidden ---
318 errno = ESRCH;
319 return (-1);
320 }
321 if (anssiz < HFIXEDSZ) {
322 errno = EINVAL;
323 return (-1);
324 }
325 DprintQ((statp->options & RES_DEBUG) || (statp->pfcode & RES_PRF_QUERY),

--- 843 unchanged lines hidden ---