Date: Sun, 02 Mar 1997 12:50:18 -0700 From: Warner Losh <imp@village.org> To: Bill Fenner <fenner@parc.xerox.com> Cc: CVS-committers@freefall.freebsd.org, cvs-all@freefall.freebsd.org, cvs-sbin@freefall.freebsd.org Subject: Re: cvs commit: src/sbin/ping ping.c ping.8 Message-ID: <E0w1HH0-0005fW-00@rover.village.org> In-Reply-To: Your message of "Sun, 02 Mar 1997 11:36:07 PST." <97Mar2.113620pst.177476@crevenia.parc.xerox.com> References: <97Mar2.113620pst.177476@crevenia.parc.xerox.com>
index | next in thread | previous in thread | raw e-mail
In message <97Mar2.113620pst.177476@crevenia.parc.xerox.com> Bill Fenner writes: : Is it a good idea to call getuid() for each packet? Wouldn't it make : more sense to cache its value, since it's not going to change? (Perhaps : at the same time as we setuid(getuid())?) I don't think that it matters enough to be worth the extra effort at optimizing. getuid() is a cheap system call, and we only call getuid() when verbose is true. And then we should be doing that only once a second. However, in less time than it has taken me to whine about this, I've added it to my local copy and it compiles.... Warnerhome | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E0w1HH0-0005fW-00>
