route.c (50477) | route.c (52419) |
---|---|
1/* 2 * Copyright (c) 1983, 1988, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 22 unchanged lines hidden (view full) --- 31 * SUCH DAMAGE. 32 */ 33 34#ifndef lint 35#if 0 36static char sccsid[] = "From: @(#)route.c 8.6 (Berkeley) 4/28/95"; 37#endif 38static const char rcsid[] = | 1/* 2 * Copyright (c) 1983, 1988, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 22 unchanged lines hidden (view full) --- 31 * SUCH DAMAGE. 32 */ 33 34#ifndef lint 35#if 0 36static char sccsid[] = "From: @(#)route.c 8.6 (Berkeley) 4/28/95"; 37#endif 38static const char rcsid[] = |
39 "$FreeBSD: head/usr.bin/netstat/route.c 50477 1999-08-28 01:08:13Z peter $"; | 39 "$FreeBSD: head/usr.bin/netstat/route.c 52419 1999-10-21 09:06:11Z julian $"; |
40#endif /* not lint */ 41 42#include <sys/param.h> 43#include <sys/protosw.h> 44#include <sys/socket.h> 45#include <sys/time.h> 46 47#include <net/if.h> 48#include <net/if_var.h> 49#include <net/if_dl.h> 50#include <net/if_types.h> 51#include <net/route.h> 52 53#include <netinet/in.h> 54#include <netipx/ipx.h> 55#include <netatalk/at.h> | 40#endif /* not lint */ 41 42#include <sys/param.h> 43#include <sys/protosw.h> 44#include <sys/socket.h> 45#include <sys/time.h> 46 47#include <net/if.h> 48#include <net/if_var.h> 49#include <net/if_dl.h> 50#include <net/if_types.h> 51#include <net/route.h> 52 53#include <netinet/in.h> 54#include <netipx/ipx.h> 55#include <netatalk/at.h> |
56#include <netgraph/ng_socket.h> |
|
56 57#ifdef NS 58#include <netns/ns.h> 59#endif 60 61#include <sys/sysctl.h> 62 63#include <netdb.h> --- 127 unchanged lines hidden (view full) --- 191 afname = "ISO"; 192 break; 193 case AF_APPLETALK: 194 afname = "AppleTalk"; 195 break; 196 case AF_CCITT: 197 afname = "X.25"; 198 break; | 57 58#ifdef NS 59#include <netns/ns.h> 60#endif 61 62#include <sys/sysctl.h> 63 64#include <netdb.h> --- 127 unchanged lines hidden (view full) --- 192 afname = "ISO"; 193 break; 194 case AF_APPLETALK: 195 afname = "AppleTalk"; 196 break; 197 case AF_CCITT: 198 afname = "X.25"; 199 break; |
200 case AF_NETGRAPH: 201 afname = "Netgraph"; 202 break; |
|
199 default: 200 afname = NULL; 201 break; 202 } 203 if (afname) 204 printf("\n%s:\n", afname); 205 else 206 printf("\nProtocol Family %d:\n", af); --- 215 unchanged lines hidden (view full) --- 422 case AF_APPLETALK: 423 { 424 if (!(flags & RTF_HOST) && mask) 425 cp = atalk_print2(sa,mask,9); 426 else 427 cp = atalk_print(sa,11); 428 break; 429 } | 203 default: 204 afname = NULL; 205 break; 206 } 207 if (afname) 208 printf("\n%s:\n", afname); 209 else 210 printf("\nProtocol Family %d:\n", af); --- 215 unchanged lines hidden (view full) --- 426 case AF_APPLETALK: 427 { 428 if (!(flags & RTF_HOST) && mask) 429 cp = atalk_print2(sa,mask,9); 430 else 431 cp = atalk_print(sa,11); 432 break; 433 } |
434 case AF_NETGRAPH: 435 { 436 printf("%s", ((struct sockaddr_ng *)sa)->sg_data); 437 break; 438 } |
|
430#ifdef NS 431 case AF_NS: 432 cp = ns_print(sa); 433 break; 434#endif 435 436 case AF_LINK: 437 { --- 443 unchanged lines hidden --- | 439#ifdef NS 440 case AF_NS: 441 cp = ns_print(sa); 442 break; 443#endif 444 445 case AF_LINK: 446 { --- 443 unchanged lines hidden --- |