mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
guard against DDOSing PsiElementFactory#createTypeByFQClassName with many expensive file scopes (IDEA-210047)
`fileScope(LightVirtualFile)` can hold hard reference to PSI and AST, and the memory snapshot contains many of those
This commit is contained in:
@@ -35,7 +35,7 @@ import java.util.concurrent.ConcurrentMap;
|
||||
|
||||
public class PsiElementFactoryImpl extends PsiJavaParserFacadeImpl implements PsiElementFactory {
|
||||
private final ConcurrentMap<LanguageLevel, PsiClass> myArrayClasses = ContainerUtil.newConcurrentMap();
|
||||
private final ConcurrentMap<GlobalSearchScope, PsiClassType> myCachedObjectType = ContainerUtil.newConcurrentMap();
|
||||
private final ConcurrentMap<GlobalSearchScope, PsiClassType> myCachedObjectType = ContainerUtil.createConcurrentSoftMap();
|
||||
|
||||
public PsiElementFactoryImpl(final PsiManagerEx manager) {
|
||||
super(manager);
|
||||
|
||||
Reference in New Issue
Block a user