]> git.ipfire.org Git - thirdparty/mtr.git/commit
performance: make reset in net.c more effective
authorSami Kerola <kerolasa@iki.fi>
Sun, 25 Sep 2016 21:09:09 +0000 (22:09 +0100)
committerSami Kerola <kerolasa@iki.fi>
Sun, 25 Sep 2016 21:34:39 +0000 (22:34 +0100)
commitb90a522f23167bd00062504803e94220937aba23
treeb160bd1f0cb7a6071afe79486cee555c0e986c11
parent50e63b55378d46e485e4a6c17c81bc867e828d33
performance: make reset in net.c more effective

Set all values in one go rather than each struct member separately.  Notice
that template initializer takes advantage of setting all missing values
using value of the last item that was set.  That makes them to be implicitly
zero.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
net.c