Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 3725 - Failure when DHCP server returns more than three DNS servers
Summary: Failure when DHCP server returns more than three DNS servers
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: pump
Version: 6.0
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Erik Troan
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 1999-06-25 14:30 UTC by jdawson
Modified: 2008-05-01 15:37 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 1999-08-19 22:11:46 UTC

Attachments (Terms of Use)

Description jdawson 1999-06-25 14:30:26 UTC
When the DHCP server returns more than three DNS servers,
all hell breaks loose.  On my system, /etc/resolv.conf gets
the first three DNS servers listed correctly, and then about
a thousand more that have random junk for their IP

------- Email Received From  John Dawson <> 06/25/99 10:42 -------

Comment 1 jdawson 1999-06-25 14:46:59 UTC
The patch I submitted fixes it.  I note that my email with the
attachment didn't show up here, so just for good measure, I'll paste
the patch here too.

Binary files pump-0.6.7.orig/pump and pump-0.6.7/pump differ
diff -uNr pump-0.6.7.orig/pump.c pump-0.6.7/pump.c
--- pump-0.6.7.orig/pump.c      Sat May  8 10:27:32 1999
+++ pump-0.6.7/pump.c   Fri Jun 25 09:11:50 1999
@@ -446,7 +446,7 @@
        switch (option) {
            case BOOTP_OPTION_DNS:
                intf->numDns = 0;
-               for (i = 0; i < length; i += 4)
+               for (i = 0; i < length && i < sizeof intf->dnsServers;
i += 4)
                    memcpy(&intf->dnsServers[intf->numDns++], chptr +
i, 4);
                intf->set |= NETINFO_HAS_DNS;
Binary files pump-0.6.7.orig/pump.o and pump-0.6.7/pump.o differ

Comment 2 Jeff Johnson 1999-06-26 14:19:59 UTC
I believe that Erik fixed the problem by discarding all nameservers
after the first 3. The resolver code in linux has never used more than
the first 3 name servers. Or so I'm told ...

Comment 3 Bill Nottingham 1999-08-19 22:11:59 UTC
Should be fixed in the errata release.

Note You need to log in before you can comment on or make changes to this bug.