From da46773f744bd95d2e94c6761d47dca71e4b2b08 Mon Sep 17 00:00:00 2001 From: Matthew Brace Date: Mon, 9 Feb 2009 01:50:31 +0000 Subject: [PATCH] Fix potential index issues when less than 10 emails are in the folder when fetching messages in WebDavStore. --- src/com/android/email/mail/store/WebDavStore.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/com/android/email/mail/store/WebDavStore.java b/src/com/android/email/mail/store/WebDavStore.java index 3addb4af9..7ccb4000c 100644 --- a/src/com/android/email/mail/store/WebDavStore.java +++ b/src/com/android/email/mail/store/WebDavStore.java @@ -992,6 +992,10 @@ public class WebDavStore extends Store { throw new MessagingException(String.format("Invalid message set %d %d", start, end)); } + if (start == 0 && end < 10) { + end = 10; + } + /** Verify authentication */ messageBody = getMessagesXml();