SafeSlingerProject / SafeSlinger-iOS

Source code for iOS platform client SafeSlinger
MIT License
6 stars 2 forks source link

disappearing recipient and sending to invalid push type #75

Closed mwfarb closed 8 years ago

mwfarb commented 9 years ago

[edited for accuracy 4/22/15]

User (A) SafeSlinger/1.8.1.1 User (A) iOS Model: iPhone User (A) iPhone OS 6.1.3

User (B) "Add Contact Invite"

User (C) SafeSlinger/1.8.1.1 User (C) iOS 6

  1. A slings keys with C.
  2. A sends Add Contact Invite from Compose|SelectRecipient|+ to a random phone contact B.
  3. B shows up in A’s recipient list with B's name, but the previous sling keys date of another recipient C.
  4. A no longer sees C in the recipient list.
  5. C sends a message to A.
  6. C receives error message from server: "User has no push registration id".

This last message is from C using push notify type 0, however that occurred.

mwfarb commented 9 years ago

I've updated the scenario, basically it appears that the Add Contact Invite is causing either UI or DB corruption int the recipients list.

tenmalin commented 8 years ago

Crashes only happens for email invitation since user may not configure the email account yet. Therefore, viewController might be null objector in the following code.

[peoplePicker dismissViewControllerAnimated:YES completion:^{
    [self presentViewController:viewController animated:YES completion:nil];
}];

Solution: add null pointer check before present the view object.

tenmalin commented 8 years ago

Close in https://github.com/SafeSlingerProject/SafeSlinger-iOS/commit/eadb24c9de82fc8eb0328814d2292e4d912aa1b2.