On Thu, Jul 04, 2013 at 08:48:16AM +0200, Maxime Villard wrote:
> Hi,
> - - - src/usr.sbin/smtpd/smtpd.c l.1326
>       if (! bsnprintf(key, sizeof key,
>               "profiling.imsg.%s.%s.%s",
>               proc_name(smtpd_process),
>               proc_name(p->proc),
>               imsg_to_str(imsg->hdr.type)));    <-- ';'
>       stat_set(key, stat_timespec(&dt));
> What's the goal of the 'if' right there?

I just commited a fix, it was reported by someone else in private too ;)

And for the record:

No need to worry much about it: it is a bug in profiling code which gets
bypassed unless you start smtpd in profiling mode. If you did, you would
still not hit it because the values we currently have do not exceed that
key buffer. And if they did, it wouldn't really be an issue anyway, this
is a key intended to carry informative value to the developer, it is not
clear if it's preferable to store a truncated key with its value, or not
to store any value at all :-/

Gilles Chehade

https://www.poolp.org                                          @poolpOrg

  • smtpd: if? Maxime Villard
    • Re: smtpd: if? Gilles Chehade

Reply via email to