summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
3a5e534)
This happens when the task is killed but main activity is not. A new
task gets created without a registered messenger, but the Main activity
doesn't know to reregister itself.
public void onStart()
{
super.onStart();
public void onStart()
{
super.onStart();
Os.debug("Main: onStart");
}
Os.debug("Main: onStart");
}
msg.obj = value;
this.messenger.send(msg);
} catch (Exception e) {
msg.obj = value;
this.messenger.send(msg);
} catch (Exception e) {
- Os.debug("Task: error sending message");
+ Os.debug("Task: error sending message", e);
private void handle(int cmd, Messenger mgr)
{
private void handle(int cmd, Messenger mgr)
{
+ // Validate messenger
+ if (cmd != REGISTER && mgr != null && mgr != this.messenger) {
+ Os.debug("Task: handle - invalid messenger");
+ }
+
// Setup communication with Main
if (cmd == REGISTER) {
Os.debug("Task: handle - register");
// Setup communication with Main
if (cmd == REGISTER) {
Os.debug("Task: handle - register");