Fix problem in curses.c when using --without-gtk and --disable-ipv6

Without out this fix, the code attempts to use a struct in6_addr which is not guaranteed to be available in --disable-ipv6 mode.