Index: busybox/networking/udhcp/dhcpc.c
===================================================================
--- busybox/networking/udhcp/dhcpc.c	(revision 14777)
+++ busybox/networking/udhcp/dhcpc.c	(working copy)
@@ -391,6 +391,7 @@
 {
 	uint8_t c;
 	int i, end, len;
+    uint8_t opt_remainder_mask[256 / 8];
 
 	udhcp_add_simple_option(packet, DHCP_MAX_SIZE, htons(IP_UDP_DHCP_SIZE));
 
@@ -398,6 +399,7 @@
 	 * from stubborn DHCP servers. Pull the data from the struct in common.c.
 	 * No bounds checking because it goes towards the head of the packet. */
 	end = udhcp_end_option(packet->options);
+    memcpy(opt_remainder_mask, client_config.opt_mask, sizeof(opt_remainder_mask));
 	len = 0;
 	for (i = 0; (c = dhcp_optflags[i].code) != 0; i++) {
 		if ((   (dhcp_optflags[i].flags & OPTION_REQ)
@@ -406,9 +408,16 @@
 		 || (client_config.opt_mask[c >> 3] & (1 << (c & 7)))
 		) {
 			packet->options[end + OPT_DATA + len] = c;
+			opt_remainder_mask[c >> 3] &= ~(1 << (c & 7));
 			len++;
 		}
 	}
+	for (c = 1; c < 254; c++) {
+		if (opt_remainder_mask[c >> 3] & (1 << (c & 7))) {
+			packet->options[end + OPT_DATA + len] = c;
+			len++;
+		}
+	}
 	if (len) {
 		packet->options[end + OPT_CODE] = DHCP_PARAM_REQ;
 		packet->options[end + OPT_LEN] = len;
@@ -1101,8 +1110,16 @@
 		client_config.no_default_options = 1;
 	while (list_O) {
 		char *optstr = llist_pop(&list_O);
-		unsigned n = udhcp_option_idx(optstr);
-		n = dhcp_optflags[n].code;
+		unsigned long n;
+		if (isdigit(*optstr)) {
+			n = strtoul(optstr, NULL, 0);
+			if (n<1 || n>254)
+				bb_error_msg_and_die("unknown option '%lu' (out of range)", n);
+		}
+		else {
+			n = udhcp_option_idx(optstr);
+			n = dhcp_optflags[n].code;
+		}
 		client_config.opt_mask[n >> 3] |= 1 << (n & 7);
 	}
 	while (list_x) {
