--- rpl/src/instructions_w1.c 2010/06/09 12:19:13 1.15 +++ rpl/src/instructions_w1.c 2010/08/09 13:51:47 1.22 @@ -1,6 +1,6 @@ /* ================================================================================ - RPL/2 (R) version 4.0.16 + RPL/2 (R) version 4.0.18 Copyright (C) 1989-2010 Dr. BERTRAND Joël This file is part of RPL/2. @@ -20,7 +20,7 @@ */ -#include "rpl.conv.h" +#include "rpl-conv.h" /* @@ -124,7 +124,7 @@ instruction_while(struct_processus *s_et void instruction_warranty(struct_processus *s_etat_processus) { -# include "garanties.conv.h" +# include "garanties-conv.h" (*s_etat_processus).erreur_execution = d_ex; @@ -420,7 +420,9 @@ instruction_write(struct_processus *s_et struct sigaction registre; struct sockaddr_in adresse_ipv4; +# ifdef IPV6 struct sockaddr_in6 adresse_ipv6; +# endif struct sockaddr_un adresse_unix; struct flock lock; @@ -1634,6 +1636,7 @@ instruction_write(struct_processus *s_et &(adresse[12]), &(adresse[13]), &(adresse[14]), &(adresse[15]), &port)== 17) { // Adresse IPv6 +# ifdef IPV6 memset(&adresse_ipv6, 0, sizeof(adresse_ipv6)); adresse_ipv6.sin6_family = AF_INET6; adresse_ipv6.sin6_port = htons((uint16_t) port); @@ -1698,6 +1701,18 @@ instruction_write(struct_processus *s_et return; } } +# else + if ((*s_etat_processus).langue == 'F') + { + printf("+++Attention : Support du protocole" + " IPv6 indisponble\n"); + } + else + { + printf("+++Attention : IPv6 support " + "unavailable\n"); + } +# endif } else { @@ -2623,7 +2638,9 @@ instruction_wfsock(struct_processus *s_e struct_objet *s_objet_resultat; struct sockaddr_in adresse_ipv4; +# ifdef IPV6 struct sockaddr_in6 adresse_ipv6; +# endif unsigned long i; @@ -2789,6 +2806,7 @@ instruction_wfsock(struct_processus *s_e else if ((*((struct_socket *) (*s_objet_resultat).objet)).domaine == PF_INET6) { +# ifdef IPV6 longueur = sizeof(adresse_ipv6); do @@ -2892,6 +2910,18 @@ instruction_wfsock(struct_processus *s_e .objet)).adresse_distante, "%s(%u)", (*((struct_socket *) (*s_objet_resultat) .objet)).adresse_distante, ntohs(adresse_ipv6.sin6_port)); +# else + if ((*s_etat_processus).langue == 'F') + { + printf("+++Attention : Support du protocole" + " IPv6 indisponble\n"); + } + else + { + printf("+++Attention : IPv6 support " + "unavailable\n"); + } +# endif } else {