On Mon 04 Dec 2006 at 09:52PM, Stephen Lau wrote:
> Since sethostname(3c) simply makes the same call to
> sysinfo(SI_SET_HOSTNAME,...), it's certainly not for any performance
> benefit. It's probably just cleaner, code-wise.
> I can sponsor this one.
Make sure to get codereview from Eric Saxe and Jeremy Teo, who did this
work just a few months ago. I was a codereviewer, and the reason is
that we identified this issue in the codereview:
Dan Price wrote:
> Could this use the standards-based library routines gethostname(3c) and
Which turned out to be beneficial, since when we tried this we
6438052 sethostname(3c) missing prototype in unistd.h.
My general theory is that when there's a standards based way to
do it, it's nice to use that.
Daniel Price - Solaris Kernel Engineering - dp at eng.sun.com - blogs.sun.com/dp