james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nor...@apache.org
Subject svn commit: r1149594 - /james/mailbox/trunk/store/src/main/java/org/apache/james/mailbox/store/StoreMessageManager.java
Date Fri, 22 Jul 2011 12:57:22 GMT
Author: norman
Date: Fri Jul 22 12:57:21 2011
New Revision: 1149594

URL: http://svn.apache.org/viewvc?rev=1149594&view=rev
Log:
Make sure the returned permanentflags are not static and so we don't have any side effect.
See MAILBOX-109

Modified:
    james/mailbox/trunk/store/src/main/java/org/apache/james/mailbox/store/StoreMessageManager.java

Modified: james/mailbox/trunk/store/src/main/java/org/apache/james/mailbox/store/StoreMessageManager.java
URL: http://svn.apache.org/viewvc/james/mailbox/trunk/store/src/main/java/org/apache/james/mailbox/store/StoreMessageManager.java?rev=1149594&r1=1149593&r2=1149594&view=diff
==============================================================================
--- james/mailbox/trunk/store/src/main/java/org/apache/james/mailbox/store/StoreMessageManager.java
(original)
+++ james/mailbox/trunk/store/src/main/java/org/apache/james/mailbox/store/StoreMessageManager.java
Fri Jul 22 12:57:21 2011
@@ -148,7 +148,11 @@ public class StoreMessageManager<Id> imp
      * @return flags
      */
     protected Flags getPermanentFlags(MailboxSession session) {
-        return MINIMAL_PERMANET_FLAGS;
+    	
+    	// Return a new flags instance to make sure the static declared flags instance will
not get modified later.
+    	//
+    	// See MAILBOX-109
+        return new Flags(MINIMAL_PERMANET_FLAGS);
     }
 
     



---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


Mime
View raw message