if (r->rtm_family == AF_INET6 && table != RT_TABLE_MAIN)
ip6_multiple_tables = 1;
- if (filter.cloned == !(r->rtm_flags&RTM_F_CLONED))
+ if (filter.cloned == !(r->rtm_flags & RTM_F_CLONED))
return 0;
if (r->rtm_family == AF_INET6 && !ip6_multiple_tables) {
if (nh->rtnh_len > len)
break;
- if (r->rtm_flags&RTM_F_CLONED && r->rtm_type == RTN_MULTICAST) {
+ if ((r->rtm_flags & RTM_F_CLONED) &&
+ r->rtm_type == RTN_MULTICAST) {
if (first) {
fprintf(fp, "Oifs: ");
first = 0;
print_rta_flow(fp, tb[RTA_FLOW]);
}
- if (r->rtm_flags&RTM_F_CLONED && r->rtm_type == RTN_MULTICAST) {
+ if ((r->rtm_flags & RTM_F_CLONED) &&
+ r->rtm_type == RTN_MULTICAST) {
fprintf(fp, "%s", ll_index_to_name(nh->rtnh_ifindex));
if (nh->rtnh_hops != 1)
fprintf(fp, "(ttl>%d)", nh->rtnh_hops);
if (r->rtm_dst_len != host_len) {
fprintf(fp, "%s/%u ",
rt_addr_n2a_rta(family, tb[RTA_DST]),
- r->rtm_dst_len);
+ r->rtm_dst_len);
} else {
fprintf(fp, "%s ",
format_host_rta(family, tb[RTA_DST]));
if (r->rtm_src_len != host_len) {
fprintf(fp, "from %s/%u ",
rt_addr_n2a_rta(family, tb[RTA_SRC]),
- r->rtm_src_len);
+ r->rtm_src_len);
} else {
fprintf(fp, "from %s ",
format_host_rta(family, tb[RTA_SRC]));
if (table && (table != RT_TABLE_MAIN || show_details > 0) && !filter.tb)
fprintf(fp, "table %s ", rtnl_rttable_n2a(table, b1, sizeof(b1)));
- if (!(r->rtm_flags&RTM_F_CLONED)) {
+ if (!(r->rtm_flags & RTM_F_CLONED)) {
if ((r->rtm_protocol != RTPROT_BOOT || show_details > 0) && filter.protocolmask != -1)
fprintf(fp, "proto %s ", rtnl_rtprot_n2a(r->rtm_protocol, b1, sizeof(b1)));
if ((r->rtm_scope != RT_SCOPE_UNIVERSE || show_details > 0) && filter.scopemask != -1)
print_rta_cacheinfo(fp, RTA_DATA(tb[RTA_CACHEINFO]));
} else if (r->rtm_family == AF_INET6) {
-
if (r->rtm_flags & RTM_F_CLONED)
fprintf(fp, "%s cache ", _SL_);
invarg("invalid mark value", *argv);
filter.markmask = -1;
} else if (matches(*argv, "metric") == 0 ||
- matches(*argv, "priority") == 0 ||
- strcmp(*argv, "preference") == 0) {
+ matches(*argv, "priority") == 0 ||
+ strcmp(*argv, "preference") == 0) {
__u32 metric;
NEXT_ARG();
return iproute_showdump();
if (matches(*argv, "help") == 0)
usage();
- fprintf(stderr, "Command \"%s\" is unknown, try \"ip route help\".\n", *argv);
+
+ fprintf(stderr,
+ "Command \"%s\" is unknown, try \"ip route help\".\n", *argv);
exit(-1);
}