From 0d1f7add7d62bb3aad32e29baf1764de83ec5ec3 Mon Sep 17 00:00:00 2001 From: Marc Blank Date: Thu, 17 Sep 2009 15:20:00 -0700 Subject: [PATCH] Add logging to EasOutboxService to help find sending issues Change-Id: I8188fd2977724ae4ee6a8703098b7068c14b92fd --- src/com/android/exchange/EasOutboxService.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/com/android/exchange/EasOutboxService.java b/src/com/android/exchange/EasOutboxService.java index ab5fa9f8e..e9dc64828 100644 --- a/src/com/android/exchange/EasOutboxService.java +++ b/src/com/android/exchange/EasOutboxService.java @@ -129,6 +129,7 @@ public class EasOutboxService extends EasSyncService { cmd += "&ItemId=" + URLEncoder.encode(itemId, "UTF-8") + "&CollectionId=" + URLEncoder.encode(collectionId, "UTF-8") + "&SaveInSent=T"; } + userLog("Send cmd: " + cmd); HttpResponse resp = sendHttpClientPost(cmd, inputEntity); inputStream.close(); @@ -140,6 +141,7 @@ public class EasOutboxService extends EasSyncService { result = EmailServiceStatus.SUCCESS; sendCallback(-1, subject, EmailServiceStatus.SUCCESS); } else { + userLog("Message sending failed, code: " + code); ContentValues cv = new ContentValues(); cv.put(SyncColumns.SERVER_ID, SEND_FAILED); Message.update(mContext, Message.CONTENT_URI, msgId, cv); @@ -196,6 +198,7 @@ public class EasOutboxService extends EasSyncService { } catch (IOException e) { mExitStatus = EXIT_IO_ERROR; } catch (Exception e) { + userLog("Exception caught in EasOutboxService", e); mExitStatus = EXIT_EXCEPTION; } finally { userLog(mMailbox.mDisplayName, ": sync finished");