2
* src/nl-util-addr.c Address Helper
4
* This library is free software; you can redistribute it and/or
5
* modify it under the terms of the GNU Lesser General Public
6
* License as published by the Free Software Foundation version 2.1
9
* Copyright (c) 2003-2009 Thomas Graf <tgraf@suug.ch>
12
#include <netlink/cli/utils.h>
14
int main(int argc, char *argv[])
21
fprintf(stderr, "Usage: nl-util-addr <address>\n");
25
a = nl_cli_addr_parse(argv[1], AF_UNSPEC);
26
err = nl_addr_resolve(a, host, sizeof(host));
28
nl_cli_fatal(err, "Unable to resolve address \"%s\": %s",
29
argv[1], nl_geterror(err));