summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBenjamin Muskalla2012-09-06 05:23:02 (EDT)
committerSteffen Pingel2012-09-10 16:05:31 (EDT)
commitd5bd686b534daef740e136c8ec652ebc86c8c00c (patch)
tree4a3c1b35d9e9c1f176c95746da5c2364fecbb4d9
parent2d49eec5ec62ff293744ed90aff1cd6c978e0a1b (diff)
downloadorg.eclipse.mylyn.tasks-d5bd686b534daef740e136c8ec652ebc86c8c00c.zip
org.eclipse.mylyn.tasks-d5bd686b534daef740e136c8ec652ebc86c8c00c.tar.gz
org.eclipse.mylyn.tasks-d5bd686b534daef740e136c8ec652ebc86c8c00c.tar.bz2
NEW - bug 388222: RepositoryClientManager fails to deserialize configsrefs/changes/37/7637/2
with arrays https://bugs.eclipse.org/bugs/show_bug.cgi?id=388222 Change-Id: Ie3ddf0439a231d1b93a1687dfd2f9a8ae3fb7039
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/RepositoryClientManager.java2
-rw-r--r--org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/core/RepositoryClientManagerTest.java5
2 files changed, 6 insertions, 1 deletions
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/RepositoryClientManager.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/RepositoryClientManager.java
index be600b4..252373c 100644
--- a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/RepositoryClientManager.java
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/RepositoryClientManager.java
@@ -47,7 +47,7 @@ public abstract class RepositoryClientManager<T, C extends Serializable> impleme
@Override
protected Class<?> resolveClass(ObjectStreamClass desc) throws IOException, ClassNotFoundException {
try {
- return repositoryConfigurationClass.getClassLoader().loadClass(desc.getName());
+ return Class.forName(desc.getName(), true, repositoryConfigurationClass.getClassLoader());
} catch (Exception e) {
return super.resolveClass(desc);
}
diff --git a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/core/RepositoryClientManagerTest.java b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/core/RepositoryClientManagerTest.java
index fc78c13..cd1fbb7 100644
--- a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/core/RepositoryClientManagerTest.java
+++ b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/core/RepositoryClientManagerTest.java
@@ -30,8 +30,13 @@ public class RepositoryClientManagerTest extends TestCase {
public String someString = "mylyn";
+ public ConfigSubObject[] anArray = new ConfigSubObject[] { new ConfigSubObject() };
+
public TaskRepository repository = null;
+ }
+ public static class ConfigSubObject implements Serializable {
+ private static final long serialVersionUID = -8730054324154087433L;
}
private class MockRepositoryClientManager extends RepositoryClientManager<Object, MyConfig> {