[tor-commits] [orbot/master] we want to only look up iptables once per run

n8fr8 at torproject.org n8fr8 at torproject.org
Thu Mar 2 04:10:21 UTC 2017


commit c9fc49a2de314800a1d271b3555e357af95c1c37
Author: Nathan Freitas <nathan at freitas.net>
Date:   Sat Jan 14 06:40:10 2017 -0500

    we want to only look up iptables once per run
---
 .../org/torproject/android/service/transproxy/TorTransProxy.java   | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/orbotservice/src/main/java/org/torproject/android/service/transproxy/TorTransProxy.java b/orbotservice/src/main/java/org/torproject/android/service/transproxy/TorTransProxy.java
index 6c3121a..8d37bd9 100644
--- a/orbotservice/src/main/java/org/torproject/android/service/transproxy/TorTransProxy.java
+++ b/orbotservice/src/main/java/org/torproject/android/service/transproxy/TorTransProxy.java
@@ -103,21 +103,20 @@ public class TorTransProxy implements TorServiceConstants {
 	
 	private String findSystemIPTables ()
 	{
-		if (mSysIptables == null)
-		{
+		if (mSysIptables == null) {
 			//if the user wants us to use the built-in iptables, then we have to find it
 			File fileIpt = new File("/system/xbin/iptables");
 
 			if (fileIpt.exists())
 				mSysIptables = fileIpt.getAbsolutePath();
-			else
-			{
+			else {
 
 				fileIpt = new File("/system/bin/iptables");
 
 				if (fileIpt.exists())
 					mSysIptables = fileIpt.getAbsolutePath();
 			}
+		}
 
 		return mSysIptables;
 	}





More information about the tor-commits mailing list