Commit 44215b93 authored by Mark Andrews's avatar Mark Andrews
Browse files

392. [func] Add ISC_R_FAMILYNOSUPPORT. Returned when OS does

                        not support the given address family requested.

 391.   [clarity]       ISC_R_FAMILY -> ISC_R_FAMILYMISMATCH.
parent 6f071989
392. [func] Add ISC_R_FAMILYNOSUPPORT. Returned when OS does
not support the given address family requested.
391. [clarity] ISC_R_FAMILY -> ISC_R_FAMILYMISMATCH.
390. [func] The function dns_zone_setdbtype() now takes
an argc/argv style vector of words and sets
both the zone database type and its arguments,
......
......@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: request.c,v 1.33 2000/08/14 19:31:49 gson Exp $ */
/* $Id: request.c,v 1.34 2000/08/15 01:43:34 marka Exp $ */
#include <config.h>
......@@ -530,15 +530,17 @@ dns_request_create(dns_requestmgr_t *requestmgr, dns_message_t *message,
case PF_INET:
disp = requestmgr->dispatchv4;
break;
case PF_INET6:
disp = requestmgr->dispatchv6;
break;
default:
result = ISC_R_NOTIMPLEMENTED;
goto cleanup;
}
if (disp == NULL) {
result = ISC_R_NETUNREACH;
result = ISC_R_FAMILYNOSUPPORT;
goto cleanup;
}
dns_dispatch_attach(disp, &request->dispatch);
......
......@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: result.h,v 1.48 2000/08/10 23:11:12 bwelling Exp $ */
/* $Id: result.h,v 1.49 2000/08/15 01:43:37 marka Exp $ */
#ifndef ISC_RESULT_H
#define ISC_RESULT_H 1
......@@ -70,7 +70,8 @@
#define ISC_R_NOTFILE 44 /* not a file */
#define ISC_R_NOTDIRECTORY 45 /* not a directory */
#define ISC_R_QUEUEFULL 46 /* queue is full */
#define ISC_R_FAMILY 47 /* address family mismatch */
#define ISC_R_FAMILYMISMATCH 47 /* address family mismatch */
#define ISC_R_FAMILYNOSUPPORT 48 /* AF not supported */
/*
* Not an result code: the number of results.
......
......@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: result.c,v 1.47 2000/08/10 23:11:09 bwelling Exp $ */
/* $Id: result.c,v 1.48 2000/08/15 01:43:36 marka Exp $ */
#include <config.h>
......@@ -85,7 +85,8 @@ static const char *text[ISC_R_NRESULTS] = {
"not a file", /* 44 */
"not a directory", /* 45 */
"queue is full", /* 46 */
"address family mismatch" /* 47 */
"address family mismatch", /* 47 */
"address family not supported" /* 48 */
};
#define ISC_RESULT_RESULTSET 2
......
......@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: socket.c,v 1.157 2000/08/10 23:42:17 gson Exp $ */
/* $Id: socket.c,v 1.158 2000/08/15 01:43:38 marka Exp $ */
#include <config.h>
......@@ -1167,6 +1167,12 @@ isc_socket_create(isc_socketmgr_t *manager, int pf, isc_sockettype_t type,
case ENFILE:
case ENOBUFS:
return (ISC_R_NORESOURCES);
case EPROTONOSUPPORT:
case EPFNOSUPPORT:
case EAFNOSUPPORT:
return (ISC_R_FAMILYNOSUPPORT);
default:
UNEXPECTED_ERROR(__FILE__, __LINE__,
"socket() failed: %s",
......@@ -2579,7 +2585,7 @@ isc_socket_bind(isc_socket_t *sock, isc_sockaddr_t *sockaddr) {
if (sock->pf != sockaddr->type.sa.sa_family) {
UNLOCK(&sock->lock);
return (ISC_R_FAMILY);
return (ISC_R_FAMILYMISMATCH);
}
if (setsockopt(sock->fd, SOL_SOCKET, SO_REUSEADDR, (void *)&on,
sizeof on) < 0) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment