route.c (146079) | route.c (146187) |
---|---|
1/* 2 * Copyright (c) 1983, 1989, 1991, 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 --- 24 unchanged lines hidden (view full) --- 33 The Regents of the University of California. All rights reserved.\n"; 34#endif /* not lint */ 35 36#ifndef lint 37#if 0 38static char sccsid[] = "@(#)route.c 8.6 (Berkeley) 4/28/95"; 39#endif 40static const char rcsid[] = | 1/* 2 * Copyright (c) 1983, 1989, 1991, 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 --- 24 unchanged lines hidden (view full) --- 33 The Regents of the University of California. All rights reserved.\n"; 34#endif /* not lint */ 35 36#ifndef lint 37#if 0 38static char sccsid[] = "@(#)route.c 8.6 (Berkeley) 4/28/95"; 39#endif 40static const char rcsid[] = |
41 "$FreeBSD: head/sbin/route/route.c 146079 2005-05-11 02:50:41Z jmallett $"; | 41 "$FreeBSD: head/sbin/route/route.c 146187 2005-05-13 16:31:11Z ume $"; |
42#endif /* not lint */ 43 44#include <sys/param.h> 45#include <sys/file.h> 46#include <sys/socket.h> 47#include <sys/ioctl.h> 48#include <sys/sysctl.h> 49#include <sys/types.h> --- 297 unchanged lines hidden (view full) --- 347 break; 348 } 349 350#ifdef INET6 351 case AF_INET6: 352 { 353 struct sockaddr_in6 sin6; /* use static var for safety */ 354 int niflags = 0; | 42#endif /* not lint */ 43 44#include <sys/param.h> 45#include <sys/file.h> 46#include <sys/socket.h> 47#include <sys/ioctl.h> 48#include <sys/sysctl.h> 49#include <sys/types.h> --- 297 unchanged lines hidden (view full) --- 347 break; 348 } 349 350#ifdef INET6 351 case AF_INET6: 352 { 353 struct sockaddr_in6 sin6; /* use static var for safety */ 354 int niflags = 0; |
355#ifdef NI_WITHSCOPEID 356 niflags = NI_WITHSCOPEID; 357#endif | |
358 359 memset(&sin6, 0, sizeof(sin6)); 360 memcpy(&sin6, sa, sa->sa_len); 361 sin6.sin6_len = sizeof(struct sockaddr_in6); 362 sin6.sin6_family = AF_INET6; 363#ifdef __KAME__ 364 if (sa->sa_len == sizeof(struct sockaddr_in6) && 365 (IN6_IS_ADDR_LINKLOCAL(&sin6.sin6_addr) || --- 109 unchanged lines hidden (view full) --- 475 break; 476 } 477 478#ifdef INET6 479 case AF_INET6: 480 { 481 struct sockaddr_in6 sin6; /* use static var for safety */ 482 int niflags = 0; | 355 356 memset(&sin6, 0, sizeof(sin6)); 357 memcpy(&sin6, sa, sa->sa_len); 358 sin6.sin6_len = sizeof(struct sockaddr_in6); 359 sin6.sin6_family = AF_INET6; 360#ifdef __KAME__ 361 if (sa->sa_len == sizeof(struct sockaddr_in6) && 362 (IN6_IS_ADDR_LINKLOCAL(&sin6.sin6_addr) || --- 109 unchanged lines hidden (view full) --- 472 break; 473 } 474 475#ifdef INET6 476 case AF_INET6: 477 { 478 struct sockaddr_in6 sin6; /* use static var for safety */ 479 int niflags = 0; |
483#ifdef NI_WITHSCOPEID 484 niflags = NI_WITHSCOPEID; 485#endif | |
486 487 memset(&sin6, 0, sizeof(sin6)); 488 memcpy(&sin6, sa, sa->sa_len); 489 sin6.sin6_len = sizeof(struct sockaddr_in6); 490 sin6.sin6_family = AF_INET6; 491#ifdef __KAME__ 492 if (sa->sa_len == sizeof(struct sockaddr_in6) && 493 (IN6_IS_ADDR_LINKLOCAL(&sin6.sin6_addr) || --- 1171 unchanged lines hidden --- | 480 481 memset(&sin6, 0, sizeof(sin6)); 482 memcpy(&sin6, sa, sa->sa_len); 483 sin6.sin6_len = sizeof(struct sockaddr_in6); 484 sin6.sin6_family = AF_INET6; 485#ifdef __KAME__ 486 if (sa->sa_len == sizeof(struct sockaddr_in6) && 487 (IN6_IS_ADDR_LINKLOCAL(&sin6.sin6_addr) || --- 1171 unchanged lines hidden --- |