From e161ca513dbb812328af85e2172737895a9eaa3a Mon Sep 17 00:00:00 2001 From: Marc Blank Date: Tue, 18 Sep 2012 08:48:53 -0700 Subject: [PATCH] Properly check for deleted messages Bug: 7011707 Change-Id: I9b977774e4b6d201dd96da1675bef7e3de88099c --- src/com/android/email/imap2/Imap2SyncService.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/com/android/email/imap2/Imap2SyncService.java b/src/com/android/email/imap2/Imap2SyncService.java index 97a125810..5dfaf5dd4 100644 --- a/src/com/android/email/imap2/Imap2SyncService.java +++ b/src/com/android/email/imap2/Imap2SyncService.java @@ -26,7 +26,6 @@ import android.database.Cursor; import android.net.TrafficStats; import android.net.Uri; import android.os.Bundle; -import android.os.Debug; import android.os.RemoteException; import android.util.Base64; import android.util.Log; @@ -233,6 +232,7 @@ public class Imap2SyncService extends AbstractSyncService { // TODO Auto-generated method stub } + @Override public void addRequest(Request req) { super.addRequest(req); if (req instanceof PartRequest) { @@ -303,6 +303,7 @@ public class Imap2SyncService extends AbstractSyncService { } } + @Override public void stop () { if (mSocket != null) try { @@ -866,14 +867,14 @@ public class Imap2SyncService extends AbstractSyncService { private void saveNewMessages (ArrayList msgList) { // Get the ids of updated messages in this mailbox (usually there won't be any) Cursor c = getUpdatesCursor(); - ArrayList updatedIds = new ArrayList(); + ArrayList updatedIds = new ArrayList(); boolean newUpdates = false; if (c != null) { try { if (c.moveToFirst()) { do { - updatedIds.add(c.getInt(UPDATE_DELETE_SERVER_ID_COLUMN)); + updatedIds.add(c.getString(UPDATE_DELETE_SERVER_ID_COLUMN)); newUpdates = true; } while (c.moveToNext()); } @@ -1154,6 +1155,7 @@ public class Imap2SyncService extends AbstractSyncService { mCursor = cursor; } + @Override public void run() { try { fetchMessageData(mConnection, mCursor);