Remove SPD when disable phase2, it fixes #2719
Fixes #3173 if any port information exists on the rule than put it on the NEGATE rule generated.
Revert back the behaviour to cleanup all states for 2.1 Fixes #3181 and related to Ticket #1629. This commit is only for 2.1 since on master development will continue for better alternatives
filter_generate_port error log function name

Absolutely minor adjustment to make the error log message refer to the new function name.
Sprinkle some unsets to reduce footprint and correct some whitespaces
Make the operation of saving old rule nearby the writing operation to be logical to spot
Add safety belts to code in rc.openvpn to avoid php errors to leave stale locks around
Related to Ticket #3045 avoid races in the ntpdate_sync_one script due to killall returning without the process really exiting.
Actually the / here is not needed.
When the v4 wan is dynamic and v6 is type dhcp and v6 information is retrieved through v4 link than trigger dhcp6c reconfiguration.
Ba-bump-bump.