chiark / gitweb /
subnet_to_string: Do not allocate
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 19 Sep 2014 22:37:58 +0000 (23:37 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 5 Oct 2014 20:06:27 +0000 (21:06 +0100)
commit322a0105bc70230236732e9751d0c888f37a5072
tree5600460877a934f0cc6388141a834ccecb5644d7
parent4f28e77ed21e75fcfb30e2f8d1d2b9b1657f44c6
subnet_to_string: Do not allocate

None of the three call sites want to keep the value for any length of
time - they just use it right away.  Replace the allocation with a use
of the round-robin buffers from ipaddr_getbuf, and remove the frees at
the call sites.

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
ipaddr.c
netlink.c
slip.c