wks_11.c revision df7f20ae77fbe03d2973d1768d6a68da1063af84
/*
* Copyright (C) 1999 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM DISCLAIMS
* ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL INTERNET SOFTWARE
* CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
* DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
* PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
* ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
* SOFTWARE.
*/
/* $Id: wks_11.c,v 1.12 1999/07/05 05:50:52 gson Exp $ */
#ifndef RDATA_IN_1_WKS_11_C
#define RDATA_IN_1_WKS_11_C
#include <limits.h>
#include <netdb.h>
#include <stdlib.h>
#include <string.h>
static dns_result_t
{
char *e;
long proto;
long port;
long maxport = -1;
unsigned int n;
/* IPv4 dotted quad */
return (DNS_R_BADDOTTEDQUAD);
return (DNS_R_NOSPACE);
/* protocol */
if (*e == 0)
(void)NULL;
else
return (DNS_R_UNEXPECTED);
return (DNS_R_RANGE);
if (proto == IPPROTO_TCP)
ps = "tcp";
else if (proto == IPPROTO_UDP)
ps = "udp";
while (1) {
ISC_TRUE));
break;
if (*e == 0)
(void) NULL;
!= NULL)
else
return (DNS_R_UNEXPECTED);
return (DNS_R_RANGE);
}
}
static dns_result_t
{
unsigned short proto;
char buf[sizeof "65535"];
unsigned int i, j;
== NULL)
return (DNS_R_NOSPACE);
for (j = 0; j < 8; j++)
}
}
return (DNS_R_SUCCESS);
}
static dns_result_t
{
return (DNS_R_UNEXPECTEDEND);
return (DNS_R_EXTRADATA);
return (DNS_R_NOSPACE);
return (DNS_R_SUCCESS);
}
static dns_result_t
}
static int
}
static dns_result_t
{
return (DNS_R_NOTIMPLEMENTED);
}
static dns_result_t
return (DNS_R_NOTIMPLEMENTED);
}
static void
freestruct_in_wks(void *source) {
}
#endif /* RDATA_IN_1_WKS_11_C */