This is an automated email from the ASF dual-hosted git repository.
btellier pushed a commit to branch 3.8.x
in repository https://gitbox.apache.org/repos/asf/james-project.git
The following commit(s) were added to refs/heads/3.8.x by this push:
new a7f59567ad JAMES-4037 Fix NPE in IMAP LIST with APPENDLIMIT (#2258)
a7f59567ad is described below
commit a7f59567ad152ebbb2f5b83a1b46ca52701b0e42
Author: Benoit TELLIER <[email protected]>
AuthorDate: Mon May 27 08:59:45 2024 +0200
JAMES-4037 Fix NPE in IMAP LIST with APPENDLIMIT (#2258)
---
.../src/test/java/org/apache/james/IMAPIntegrationTest.java | 10 ++++++++++
.../org/apache/james/modules/protocols/IMAPServerModule.java | 2 ++
2 files changed, 12 insertions(+)
diff --git
a/server/apps/memory-app/src/test/java/org/apache/james/IMAPIntegrationTest.java
b/server/apps/memory-app/src/test/java/org/apache/james/IMAPIntegrationTest.java
index 70241c5a84..bd85641198 100644
---
a/server/apps/memory-app/src/test/java/org/apache/james/IMAPIntegrationTest.java
+++
b/server/apps/memory-app/src/test/java/org/apache/james/IMAPIntegrationTest.java
@@ -77,4 +77,14 @@ class IMAPIntegrationTest {
.contains("OK GETACL completed.");
}
+ @Test
+ void listStatusAppendLimitShouldSucceed(GuiceJamesServer guiceJamesServer)
throws Exception {
+ TestIMAPClient testIMAPClient = new TestIMAPClient();
+ testIMAPClient.connect(LOCALHOST_IP,
guiceJamesServer.getProbe(ImapGuiceProbe.class).getImapPort())
+ .login(BOB.asString(), BOB_PASSWORD);
+
+ assertThat(testIMAPClient.sendCommand("LIST \"\" % RETURN (STATUS
(APPENDLIMIT))"))
+ .contains("OK LIST completed.");
+ }
+
}
diff --git
a/server/container/guice/protocols/imap/src/main/java/org/apache/james/modules/protocols/IMAPServerModule.java
b/server/container/guice/protocols/imap/src/main/java/org/apache/james/modules/protocols/IMAPServerModule.java
index fa478b0b6a..fc43411f56 100644
---
a/server/container/guice/protocols/imap/src/main/java/org/apache/james/modules/protocols/IMAPServerModule.java
+++
b/server/container/guice/protocols/imap/src/main/java/org/apache/james/modules/protocols/IMAPServerModule.java
@@ -54,6 +54,7 @@ import org.apache.james.imap.processor.DefaultProcessor;
import org.apache.james.imap.processor.EnableProcessor;
import org.apache.james.imap.processor.PermitEnableCapabilityProcessor;
import org.apache.james.imap.processor.SelectProcessor;
+import org.apache.james.imap.processor.StatusProcessor;
import org.apache.james.imap.processor.base.AbstractProcessor;
import org.apache.james.imap.processor.base.UnknownRequestProcessor;
import org.apache.james.imapserver.netty.IMAPServerFactory;
@@ -96,6 +97,7 @@ public class IMAPServerModule extends AbstractModule {
bind(CapabilityProcessor.class).in(Scopes.SINGLETON);
bind(AuthenticateProcessor.class).in(Scopes.SINGLETON);
bind(SelectProcessor.class).in(Scopes.SINGLETON);
+ bind(StatusProcessor.class).in(Scopes.SINGLETON);
bind(EnableProcessor.class).in(Scopes.SINGLETON);
bind(MailboxTyper.class).to(DefaultMailboxTyper.class).in(Scopes.SINGLETON);
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]