Hello
I get the following error message when retrieving emails from an Exchange Server with the YouTrack software. The following software versions are in use.
The initial retrieval of emails from the Exchange mailbox works. Any further attempt to retrieve the emails from the mailbox will result in this error.
2024-02-15 10:24:04,441 ERROR [ImapConnection-50719] davmail - Range [3, 3 + 0) out of bounds for length 2
java.lang.StringIndexOutOfBoundsException: Range [3, 3 + 0) out of bounds for length 2
at java.base/jdk.internal.util.Preconditions$1.apply(Preconditions.java:55)
at java.base/jdk.internal.util.Preconditions$1.apply(Preconditions.java:52)
at java.base/jdk.internal.util.Preconditions$4.apply(Preconditions.java:213)
at java.base/jdk.internal.util.Preconditions$4.apply(Preconditions.java:210)
at java.base/jdk.internal.util.Preconditions.outOfBounds(Preconditions.java:98)
at java.base/jdk.internal.util.Preconditions.outOfBoundsCheckFromIndexSize(Preconditions.java:118)
at java.base/jdk.internal.util.Preconditions.checkFromIndexSize(Preconditions.java:397)
at java.base/java.lang.String.checkBoundsOffCount(String.java:4853)
at java.base/java.lang.String.rangeCheck(String.java:307)
at java.base/java.lang.String.<init>(String.java:303)
at davmail.imap.ImapConnection$ImapTokenizer.nextQuotedToken(ImapConnection.java:2156)
at davmail.imap.ImapConnection$ImapTokenizer.nextToken(ImapConnection.java:2115)
at davmail.imap.ImapConnection.appendDateSearchParam(ImapConnection.java:1595)
at davmail.imap.ImapConnection.appendSearchParam(ImapConnection.java:1541)
at davmail.imap.ImapConnection.buildConditions(ImapConnection.java:1117)
at davmail.imap.ImapConnection.appendNotSearchParams(ImapConnection.java:1495)
at davmail.imap.ImapConnection.appendSearchParam(ImapConnection.java:1513)
at davmail.imap.ImapConnection.buildConditions(ImapConnection.java:1117)
at davmail.imap.ImapConnection.handleSearch(ImapConnection.java:1128)
at davmail.imap.ImapConnection.run(ImapConnection.java:393)</init>
Sorry I don't actively monitor Sourceforge, as most feedback comes through Github now.
Anyway there were a few changes on IMAP parsing last year, please try with latest trunk build.
Also please provide the exact IMAP command from davmail.log to help reproduce issue