Sentinel: fix bufsize to support IPv6 address

Closes #1914
Rename two 'buf' vars to 'ip' for better clarity

Clearly ip[32] is wrong, but it's less clear that buf[32] was wrong
without further reading.