diff --git a/miniupnpd/Changelog.txt b/miniupnpd/Changelog.txt index 6d463e4..2835f5b 100644 --- a/miniupnpd/Changelog.txt +++ b/miniupnpd/Changelog.txt @@ -1,4 +1,7 @@ -$Id: Changelog.txt,v 1.350 2014/02/06 09:52:03 nanard Exp $ +$Id: Changelog.txt,v 1.351 2014/02/11 09:35:52 nanard Exp $ + +2014/02/11: + Fix PCP Map renewal 2014/02/06: possibility to disable ipv6 at runtime diff --git a/miniupnpd/pcpserver.c b/miniupnpd/pcpserver.c index c12eb96..7354fb3 100644 --- a/miniupnpd/pcpserver.c +++ b/miniupnpd/pcpserver.c @@ -1,4 +1,4 @@ -/* $Id: pcpserver.c,v 1.7 2014/02/03 09:38:26 nanard Exp $ */ +/* $Id: pcpserver.c,v 1.9 2014/02/11 09:35:53 nanard Exp $ */ /* MiniUPnP project * Website : http://miniupnp.free.fr/ * Author : Peter Tatrai @@ -803,7 +803,7 @@ static void CreatePCPMap(pcp_info_t *pcp_msg_info) char desc[64]; char iaddr_old[INET_ADDRSTRLEN]; uint16_t iport_old; - unsigned int timestamp = time(NULL) + pcp_msg_info->lifetime; + unsigned int timestamp; int r=0; if (pcp_msg_info->ext_port == 0) { @@ -840,6 +840,8 @@ static void CreatePCPMap(pcp_info_t *pcp_msg_info) } } while (r==0); + timestamp = time(NULL) + pcp_msg_info->lifetime; + if ((pcp_msg_info->ext_port == 0) || (IN6_IS_ADDR_V4MAPPED(pcp_msg_info->int_ip) && (!check_upnp_rule_against_permissions(upnppermlist,