From e2161a6d6264e35f3466b57b16b0c5966cf759a9 Mon Sep 17 00:00:00 2001 From: Dmitry Batkovich Date: Fri, 29 Sep 2017 11:45:13 +0300 Subject: [PATCH] do not throw exceptions in CoreProgressManager.assertUnderProgress() --- .../progress/impl/CoreProgressManager.java | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) diff --git a/platform/core-impl/src/com/intellij/openapi/progress/impl/CoreProgressManager.java b/platform/core-impl/src/com/intellij/openapi/progress/impl/CoreProgressManager.java index 1479bb12418d..8fc192e76e8f 100644 --- a/platform/core-impl/src/com/intellij/openapi/progress/impl/CoreProgressManager.java +++ b/platform/core-impl/src/com/intellij/openapi/progress/impl/CoreProgressManager.java @@ -1,18 +1,4 @@ -/* - * Copyright 2000-2017 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ +// Copyright 2000-2017 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. package com.intellij.openapi.progress.impl; import com.google.common.collect.ConcurrentHashMultiset; @@ -745,7 +731,7 @@ public class CoreProgressManager extends ProgressManager implements Disposable { synchronized (threadsUnderIndicator) { Set threads = threadsUnderIndicator.get(indicator); if (threads == null || !threads.contains(Thread.currentThread())) { - throw new IllegalStateException("Must be executed under progress indicator: "+indicator+". Please see e.g. ProgressManager.runProcess()"); + LOG.error("Must be executed under progress indicator: "+indicator+". Please see e.g. ProgressManager.runProcess()"); } } }