Make sure events handled on same looper

Two handlers are used to call a function, but the init was not forcing them on the
same looper/thread, so we could get synchronization problems as a result.

Moved to a single looper.

Also added finally clauses to clean up if a broadcast throws an uncaught exception.

bug:13399768
Change-Id: I0044e2442335ee45a15588f910064e848cf6ac55
1 file changed