net: fix async connect to non-listening port.

In this case, Linux (at least, Ubuntu 13.10, x86-64 kernel 3.11.0-14-generic)
sets POLLHUP and gives no other error notification.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
timer: fix abortstring on 64 bit platforms.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
bitmap: add endianness casts

sparse yells at us when it realises we are implicitly casting an
endian type (big endian) to a plain unsigned long.

Get rid of this warning by telling sparse that we know what
we are doing.

Signed-off-by: Emilio G. Cota <cota@braap.org>
opt: only use termios if HAVE_SYS_TERMIOS_H is defined

This fixes building for Windows and other platforms which lack <sys/termios.h>

Signed-off-by: Luke Dashjr <luke-jr+git@utopios.org>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
opt: avoid using %lld and %llx formats

These are not supported in all environments, so use PRId64 and PRIu64 instead.

Signed-off-by: Luke Dashjr <luke-jr+git@utopios.org>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
tools/configurator: add HAVE_SYS_TERMIOS_H

As recently required by ccan/opt.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
opt: test HAVE_SYS_TERMIOS_H via #if

As ccanlint warns.  Also, test TIOCGWINSZ before ioctl, rather than the
header directly since it's a little orthogonal.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
opt: fix tests for 64-bit systems.

Actually, only an issue for 64 bit big endian systems, but still...

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Merge branch 'master' of https://github.com/rustyrussell/ccan

Conflicts:
	ccan/timer/timer.c