about summary refs log tree commit diff
path: root/resolv/res_mkquery.c
diff options
context:
space:
mode:
Diffstat (limited to 'resolv/res_mkquery.c')
-rw-r--r--resolv/res_mkquery.c60
1 files changed, 0 insertions, 60 deletions
diff --git a/resolv/res_mkquery.c b/resolv/res_mkquery.c
index feaf0eff8b..505c3914a9 100644
--- a/resolv/res_mkquery.c
+++ b/resolv/res_mkquery.c
@@ -94,9 +94,6 @@ res_mkquery(op, dname, class, type, data, datalen, newrr_in, buf, buflen)
 	register HEADER *hp;
 	register u_char *cp;
 	register int n;
-#ifdef ALLOW_UPDATES
-	struct rrec *newrr = (struct rrec *) newrr_in;
-#endif
 	u_char *dnptrs[20], **dpp, **lastdnptr;
 
 	if ((_res.options & RES_INIT) == 0 && res_init() == -1) {
@@ -186,63 +183,6 @@ res_mkquery(op, dname, class, type, data, datalen, newrr_in, buf, buflen)
 		hp->ancount = htons(1);
 		break;
 
-#ifdef ALLOW_UPDATES
-	/*
-	 * For UPDATEM/UPDATEMA, do UPDATED/UPDATEDA followed by UPDATEA
-	 * (Record to be modified is followed by its replacement in msg.)
-	 */
-	case UPDATEM:
-	case UPDATEMA:
-
-	case UPDATED:
-		/*
-		 * The res code for UPDATED and UPDATEDA is the same; user
-		 * calls them differently: specifies data for UPDATED; server
-		 * ignores data if specified for UPDATEDA.
-		 */
-	case UPDATEDA:
-		buflen -= RRFIXEDSZ + datalen;
-		if ((n = dn_comp(dname, cp, buflen, dnptrs, lastdnptr)) < 0)
-			return (-1);
-		cp += n;
-		__putshort(type, cp);
-		cp += INT16SZ;
-		__putshort(class, cp);
-		cp += INT16SZ;
-		__putlong(0, cp);
-		cp += INT32SZ;
-		__putshort(datalen, cp);
-		cp += INT16SZ;
-		if (datalen) {
-			bcopy(data, cp, datalen);
-			cp += datalen;
-		}
-		if ( (op == UPDATED) || (op == UPDATEDA) ) {
-			hp->ancount = htons(0);
-			break;
-		}
-		/* Else UPDATEM/UPDATEMA, so drop into code for UPDATEA */
-
-	case UPDATEA:	/* Add new resource record */
-		buflen -= RRFIXEDSZ + datalen;
-		if ((n = dn_comp(dname, cp, buflen, dnptrs, lastdnptr)) < 0)
-			return (-1);
-		cp += n;
-		__putshort(newrr->r_type, cp);
-		cp += INT16SZ;
-		__putshort(newrr->r_class, cp);
-		cp += INT16SZ;
-		__putlong(0, cp);
-		cp += INT32SZ;
-		__putshort(newrr->r_size, cp);
-		cp += INT16SZ;
-		if (newrr->r_size) {
-			bcopy(newrr->r_data, cp, newrr->r_size);
-			cp += newrr->r_size;
-		}
-		hp->ancount = htons(0);
-		break;
-#endif /* ALLOW_UPDATES */
 	default:
 		return (-1);
 	}