| Index: media/capture/content/android/java/src/org/chromium/media/ScreenCapture.java
|
| diff --git a/media/capture/content/android/java/src/org/chromium/media/ScreenCapture.java b/media/capture/content/android/java/src/org/chromium/media/ScreenCapture.java
|
| index 4956571caab08f3d39c7e6b8c3f56f96791b3749..11a8a3558f643931462b636dc8955e6abcca52fc 100644
|
| --- a/media/capture/content/android/java/src/org/chromium/media/ScreenCapture.java
|
| +++ b/media/capture/content/android/java/src/org/chromium/media/ScreenCapture.java
|
| @@ -319,14 +319,16 @@ public class ScreenCapture extends Fragment {
|
| if (mMediaProjection != null && mCaptureState == CaptureState.STARTED) {
|
| mMediaProjection.stop();
|
| changeCaptureStateAndNotify(CaptureState.STOPPING);
|
| - }
|
|
|
| - while (mCaptureState != CaptureState.STOPPED) {
|
| - try {
|
| - mCaptureStateLock.wait();
|
| - } catch (InterruptedException ex) {
|
| - Log.e(TAG, "ScreenCaptureEvent: " + ex);
|
| + while (mCaptureState != CaptureState.STOPPED) {
|
| + try {
|
| + mCaptureStateLock.wait();
|
| + } catch (InterruptedException ex) {
|
| + Log.e(TAG, "ScreenCaptureEvent: " + ex);
|
| + }
|
| }
|
| + } else {
|
| + changeCaptureStateAndNotify(CaptureState.STOPPED);
|
| }
|
| }
|
| }
|
|
|