type_to_string: move formatting to appropriate files.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2017-01-04 14:07:15 +10:30
parent 5bd8063ddb
commit c7b69abdaa
12 changed files with 120 additions and 82 deletions

View File

@@ -1,5 +1,6 @@
#include "bitcoin/pullpush.h"
#include "netaddr.h"
#include "type_to_string.h"
#include "utils.h"
#include <arpa/inet.h>
#include <assert.h>
@@ -86,3 +87,4 @@ bool netaddr_from_fd(int fd, int type, int protocol, struct netaddr *a)
return getpeername(fd, &a->saddr.s, &a->addrlen) == 0;
}
REGISTER_TYPE_TO_STRING(netaddr, netaddr_name);