Ticket #39413: patch-Port-bsd-lowlevel-bsd.c.diff
File patch-Port-bsd-lowlevel-bsd.c.diff, 1.4 KB (added by fclaire@…, 11 years ago) |
---|
-
Port-bsd/lowlevel-bsd.c
old new 10 10 * 11 11 */ 12 12 13 #define __APPLE_USE_RFC_3542 13 14 #include <stdio.h> 14 15 #include <arpa/inet.h> 15 16 #include <netinet/in.h> … … 327 328 } 328 329 329 330 /* Mac OS X have IPV6_PKTINFO only */ 330 /* OpenBSD, NetBSD require IPV6_RECVPKTINFO */331 /* OpenBSD, NetBSD require IPV6_RECVPKTINFO 331 332 #if (HAVE_DECL_IPV6_RECVPKTINFO == 0) && (HAVE_DECL_IPV6_PKTINFO == 0) 332 333 #error "Both IPV6_RECVPKTINFO and IPV6_PKTINFO not defined. Need at least one of them" 333 #endif 334 #endif */ 334 335 335 336 /* Set the options to receive info about ipv6 traffic */ 336 337 #if HAVE_DECL_IPV6_RECVPKTINFO == 1 … … 490 491 uint32_t ret; 491 492 FILE *file; 492 493 493 strcpy(filename, " /var/lib/dibbler/AAA/AAA-SPI");494 strcpy(filename, "@@PREFIX@@/var/lib/dibbler/AAA/AAA-SPI"); 494 495 495 496 if (stat(filename, &st)) 496 497 return 0; … … 508 509 char * getAAAKeyFilename(uint32_t SPI) { 509 510 static char filename[1024]; 510 511 if (SPI != 0) 511 snprintf(filename, 1024, "%s%s%x", " /var/lib/dibbler/AAA/", "AAA-key-",512 snprintf(filename, 1024, "%s%s%x", "@@PREFIX@@/var/lib/dibbler/AAA/", "AAA-key-", 512 513 SPI); 513 514 else 514 strcpy(filename, " /var/lib/dibbler/AAA/AAA-key");515 strcpy(filename, "@@PREFIX@@/var/lib/dibbler/AAA/AAA-key"); 515 516 return filename; 516 517 } 517 518