Skip to content

Call finish on UI thread - #465

Merged
william-ferguson-au merged 3 commits into
ACRA:masterfrom
F43nd1r:issue_464
Jun 4, 2016
Merged

Call finish on UI thread#465
william-ferguson-au merged 3 commits into
ACRA:masterfrom
F43nd1r:issue_464

Conversation

@F43nd1r

@F43nd1r F43nd1r commented May 28, 2016

Copy link
Copy Markdown
Member

Fix #464

@william-ferguson-au

Copy link
Copy Markdown
Member

The problem is not calling Activity.finish() on the UI Thread. It is that it is unlikely to execute before the Process is killed on line 270.

@F43nd1r

F43nd1r commented May 28, 2016

Copy link
Copy Markdown
Member Author

OK, I added a commit that should let the activity complete its lifecycle before the process is killed.

@F43nd1r

F43nd1r commented May 28, 2016

Copy link
Copy Markdown
Member Author

It looks like android is reusing the main process for the dialog. I think it is good to run the dialog on the :acra process anyway, becasue it prevents infinite loops in case of a crashing dialog. (this couldn't happen before, because we killed the process before the dialog had a chance to take it over.)

I also noticed that if the activity crashed on its main thread, it won't call onStop anymore, so it is useless to wait for that.

@william-ferguson-au
william-ferguson-au merged commit 3b1a058 into ACRA:master Jun 4, 2016
@F43nd1r
F43nd1r deleted the issue_464 branch May 4, 2018 10:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants