fix wg_send_buffer to reconnect tcp sockets on failure

Conflicts:
	src/write_graphite.c