Comments (3)
Hi,
thank you for the detailed bug report.
Regarding the error I believe the reason for it is different (did you try to prove the synchronized{}-theory?).
I believe the Fragment is loosing the activity (therefore getActivity()
return null) once the IodineVpnService switches the application status to CONNECT (l. 210) because then the IodineMain switches the Fragments (l. 42).
I won't promise you a date when I fix it but if you would like to do it then a PR is very welcome.
Kind regads, yves
from andiodine.
Hi,
I have read the IodineMain.java
, FragmentList.java
and IodineVpnService.java
. I think you are totally right.
The event sequences to replay the crash is as follows:
- Add a new Connection --> 2. click the item --> 3. click ok --> 4. click the item --> 5. click ok --> crash
And the time interval between steps 3 and 4 should be very small.
The root cause may be like this. The first invocation of vpnServiceConnect2
sent an intent to broadcastReceiver
which started a new thread (IodineVpnService
). And this new thread sent new status to IodineMain
which switched the Fragments. Therefore, the second invocation of vpnServiceConnect2
get a null pointer after invocation of getActivity
.
Please point out mistakes in it.
Thanks!
ps. The onReceive
of BroadcastReceiver
is always called within the main thread of its process, unless you explicitly asked for it to be scheduled on a different thread using registerReceiver(BroadcastReceiver, IntentFilter, String, Handler)
. Therefore, there won't be synchronized problems.
from andiodine.
My phone is too fast, I don't get a chance to click the item a second time
If you have a fix for this then feel free to open a PR
from andiodine.
Related Issues (20)
- Setting custom DNS Server on connect fails on Android 5
- immediately disconnects after connecting HOT 4
- Setting "Request Type" does not seem to take effect HOT 4
- Crash after FragmentList.findViewById() returned null HOT 5
- app crash after connect if "Tunnel Nameserver" setting is empty HOT 6
- java.lang.NullPointerException: Attempt to invoke virtual method 'int android.os.ParcelFileDescriptor.detachFd()' on a null object reference HOT 1
- What iodine version is being used? HOT 2
- How fast should iodine be? HOT 3
- Connection keeps randomly dropping HOT 10
- Not working on Android 6.x? HOT 5
- -device 'dns0' works, -device 'tun0' default does not. HOT 19
- port andiodine to frekky's iodine fork for better performance HOT 4
- Cannot build andiodine 1.4 HOT 1
- VPN not working HOT 6
- andiodine + openvpn tunnel? HOT 1
- v1.4 should be on F-droid HOT 3
- zinou
- andiodine 1.5 build HOT 3
- "Due to recent changes to the github platform this project has moved to gitlab..." HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from andiodine.