Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

java.lang.LinkageError caused by IoslatingClassLoader.java #79

Open
Fourseas54 opened this issue Nov 13, 2024 · 0 comments
Open

java.lang.LinkageError caused by IoslatingClassLoader.java #79

Fourseas54 opened this issue Nov 13, 2024 · 0 comments

Comments

@Fourseas54
Copy link

There is a project named GrowingBugRepository(https://github.com/liuhuigmail/GrowingBugRepository),which can be considered as same as Defects4j. And there is a newly mined bug which is mined from apache/commons-dbcp project. When I run gzoltar on this bug, there is an error:
java.lang.LinkageError: loader constraint violation: loader (instance of com/gzoltar/internal/core/util/IsolatingClassLoader) previously initiated loading for a different type with name "javax/management/MBeanServer"
I simply thought that was due to dependency violation. But I didn't find javax.management after running "mvn dependency:tree" on root directory of gzoltar.
Then I modified com/gzoltar/internal/core/util/IsolatingClassLoader and simply added an if statement:
if (name.contains(".management")){
return super.loadClass(name,resolve);
}
And gzoltar can running perfectly on that apache/commons-dbcp project.
But there may be more elegant way to fix it.
I hope you can help me solve this problom, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant