mirror of
				https://github.com/Ysurac/openmptcprouter-feeds.git
				synced 2025-03-09 15:40:03 +00:00 
			
		
		
		
	Fix error if adding firewall rules while rules are incorrect
This commit is contained in:
		
							parent
							
								
									a8a3ba330a
								
							
						
					
					
						commit
						2bf33b6dd1
					
				
					 1 changed files with 7 additions and 0 deletions
				
			
		| 
						 | 
				
			
			@ -467,6 +467,13 @@ _get_gre_tunnel() {
 | 
			
		|||
					set network.omrip${i}.netmask="255.255.255.252"
 | 
			
		||||
					set network.omrip${i}.lookup="667${i}"
 | 
			
		||||
					commit network
 | 
			
		||||
				EOF
 | 
			
		||||
				allintf=$(uci -q get firewall.zone_vpn.network)
 | 
			
		||||
				uci -q del firewall.zone_vpn.network
 | 
			
		||||
				for intf in $allintf; do
 | 
			
		||||
					uci -q add_list firewall.zone_vpn.network=$intf
 | 
			
		||||
				done
 | 
			
		||||
				uci -q batch <<-EOF >/dev/null
 | 
			
		||||
					add_list firewall.zone_vpn.network="omrip${i}gre"
 | 
			
		||||
					add_list firewall.zone_vpn.network="omrip${i}"
 | 
			
		||||
					commit firewall
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue