[tor-commits] [orbot/master] fixed crash when an user tries to add the same hidden service port twice
n8fr8 at torproject.org
n8fr8 at torproject.org
Tue Oct 31 15:59:10 UTC 2017
commit 2922e487305dc8a808990f2ae14169fc5485be24
Author: Igor Koznin <dixidroid at gmail.com>
Date: Sun Jul 16 15:55:49 2017 +0300
fixed crash when an user tries to add the same hidden service port twice
---
app/src/main/java/org/torproject/android/OrbotMainActivity.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/src/main/java/org/torproject/android/OrbotMainActivity.java b/app/src/main/java/org/torproject/android/OrbotMainActivity.java
index 0e9e2f72..3d4c954c 100644
--- a/app/src/main/java/org/torproject/android/OrbotMainActivity.java
+++ b/app/src/main/java/org/torproject/android/OrbotMainActivity.java
@@ -624,7 +624,7 @@ public class OrbotMainActivity extends AppCompatActivity
if (row == null || row.getCount() < 1) {
cr.insert(HSContentProvider.CONTENT_URI, fields);
- } else {
+ } else if (row.moveToFirst()) {
onionHostname = row.getString(row.getColumnIndex(HSContentProvider.HiddenService.DOMAIN));
row.close();
}
More information about the tor-commits
mailing list