[Bug 1841] Incorrect processing of DNS info from DHCP

bugzilla-daemon at rtems.org bugzilla-daemon at rtems.org
Tue Dec 6 22:54:42 UTC 2011


https://www.rtems.org/bugzilla/show_bug.cgi?id=1841

--- Comment #6 from Joel Sherrill <joel.sherrill at oarcorp.com> 2011-12-06 16:54:40 CST ---
(In reply to comment #5)
> (In reply to comment #3)
> > RCS file: /usr1/CVS/rtems/cpukit/libnetworking/rtems/rtems_dhcp.c,v
> > retrieving revision 1.9
> > diff -r1.9 rtems_dhcp.c
> > 1089c1089
> > <         strcat(buf, inet_ntoa(rtems_bsdnet_ntpserver[i]));
> > ---
> > >         strcat(buf, inet_ntoa(rtems_bsdnet_nameserver[i]));
> 
> Ok.
> 
> > 
> > For (2), I see it statically initialized to 0 in rtems_glue.c
> > 
> > ./rtems/rtems_glue.c:int rtems_bsdnet_nameserver_count = 0;
> > 
> 
> This is no good. It only works for the first attempt. Any further DHCP requests
> will create a problem. The '= 0' should be removed and the value set when the
> request is processed.

Does anyone tracking this PR have a suggestion on where to put the "= 0"?

> The hack to support the name servers like this can go. It pre-dates a suitable
> file system. The /etc/resolve.conf should be the only supported method of
> managing the resolver. We should consider this. A new stack will not contain
> this table and applications that depend on it should be given notice this will
> go away.

Agreed.  It will simplify things.

-- 
Configure bugmail: https://www.rtems.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.



More information about the bugs mailing list