diff options
author | Jeff King <peff@peff.net> | 2015-09-24 17:08:00 -0400 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2015-10-05 11:08:05 -0700 |
commit | f063d38b808e184675e5b0931ea0167a013b3fcb (patch) | |
tree | c5d8af0937956b040451609dd31e301f17a8b823 /builtin/unpack-file.c | |
parent | stat_tracking_info: convert to argv_array (diff) | |
download | tgif-f063d38b808e184675e5b0931ea0167a013b3fcb.tar.xz |
daemon: use cld->env_array when re-spawning
This avoids an ugly strcat into a fixed-size buffer. It's
not wrong (the buffer is plenty large enough for an IPv6
address plus some minor formatting), but it takes some
effort to verify that.
Unfortunately we are still stuck with some fixed-size
buffers to hold the output of inet_ntop. But at least we now
pass very easy-to-verify parameters, rather than doing a
manual computation to account for other data in the buffer.
As a side effect, this also fixes the case where we might
pass an uninitialized portbuf buffer through the
environment. This probably couldn't happen in practice, as
it would mean that addr->sa_family was neither AF_INET nor
AF_INET6 (and that is all we are listening on).
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/unpack-file.c')
0 files changed, 0 insertions, 0 deletions