apsun / NekoSMS

A pattern-based text message blocker for Android.
GNU General Public License v3.0
419 stars 44 forks source link

Potential data loss #14

Closed apsun closed 8 years ago

apsun commented 8 years ago

Since broadcasts are asynchronous, it is possible that after we delete the SMS data from the PDU table and before the intent is received by the BroadcastReceiver in our app, the phone crashes and the SMS is lost.

To fix this, we should make the Xposed module directly write to the database first (how it used to be) BEFORE deleting the data from the PDU table. We can just broadcast the URI of the inserted row instead of the actual SMS data.