While looking for something else, I stumbled upon this IP Helper API on
windows. It might be a better way of doing this nameserver
configuration. What do you think?
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/iphlp/iphlp/ip_helper_start_page.asp
the only limitation I see is that it is not supported on win95 and on
NT4 prior do SP4. On the other hand, I really don't like the current
method of listing all configured nameservers on all interfaces. If you
have VPN interfaces ( or even dialup ) configured with fixed name
servers, they will be included for queryiing even though the interface
might be down and the servers unreachable. Maybe only listing
system-wide nameservers from
"SYSTEM\\CurrentControlSet\\Services\\Tcpip\\Parameters",
would be better?
I don't know if it is better to go the IP helper API way or keep it as is.
I will test the code shortly, thanks for the credits!!
Dimitri
I've now merged your patch to the CVS-tree. I did a few modificatiosn
before committing:
- updated to new sresolv code (the related code now in sres.c)
- added cascaded checks: first check non-dhcp fields for each interface,
then dchp-provided fields, and last the system-level fields
- modified the sresolv update interval (from 5sec to 180sec) -> I guess
there's no way to make watching the registry values as efficient
as stat("/etc/resolve.conf") on UNIX systems
- removed the 64 char limit for key values
Let me know if this works for you. I've tested this on a WindowsXP
machine.
usefull or if there are any problems with the patch. There is also a
need to
link with advapi32.lib on windows.
Yep, this is now needed for all Sofia-SIP clients on win32.
PS And oh yeah, this closes sf.net bug #1445560. Thanks very
much for the patch!
-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Sofia-sip-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sofia-sip-devel