Repository: flutter
Issue: [tool_crash] ConcurrentModificationError: (#0      List.addAll (dart:core-patch/growable_array.dart:325:11))
Labels: c: crash,tool,P2,team-tool,triaged-tool

## Command
```
flutter analyze --watch --write /tmp/analysis.flutter
```

## Steps to Reproduce
No idea. I just ran the command above.

## Logs
ConcurrentModificationError: (#0      List.addAll (dart:core-patch/growable_array.dart:325:11))
```
#0      List.addAll (dart:core-patch/growable_array.dart:325:11)
#1      AnalyzeContinuously._handleAnalysisStatus.<anonymous closure> (package:flutter_tools/src/commands/analyze_continuously.dart:116:18)
#2      _LinkedHashMapMixin.forEach (dart:collection-patch/compact_hash.dart:539:8)
#3      AnalyzeContinuously._handleAnalysisStatus (package:flutter_tools/src/commands/analyze_continuously.dart:114:22)
#4      AnalyzeContinuously.analyze.<anonymous closure> (package:flutter_tools/src/commands/analyze_continuously.dart:79:53)
#5      _rootRunUnary (dart:async/zone.dart:1434:47)
#6      _CustomZone.runUnary (dart:async/zone.dart:1335:19)
#7      _CustomZone.runUnaryGuarded (dart:async/zone.dart:1244:7)
#8      _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:341:11)
#9      _DelayedData.perform (dart:async/stream_impl.dart:591:14)
#10     _StreamImplEvents.handleNext (dart:async/stream_impl.dart:706:11)
#11     _PendingEvents.schedule.<anonymous closure> (dart:async/stream_impl.dart:663:7)
#12     _rootRun (dart:async/zone.dart:1418:47)
#13     _CustomZone.run (dart:async/zone.dart:1328:19)
#14     _CustomZone.runGuarded (dart:async/zone.dart:1236:7)
#15     _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:1276:23)
#16     _rootRun (dart:async/zone.dart:1426:13)
#17     _CustomZone.run (dart:async/zone.dart:1328:19)
#18     _CustomZone.runGuarded (dart:async/zone.dart:1236:7)
#19     _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:1276:23)
#20     _microtaskLoop (dart:async/schedule_microtask.dart:40:21)
#21     _startMicrotaskLoop (dart:async/schedule_microtask.dart:49:5)
#22     _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:122:13)
#23     _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:193:5)
```
```
[✓] Flutter (Channel master, 2.9.0-1.0.pre.182, on Ubuntu 20.04.3 LTS 5.4.0-91-generic, locale C.UTF-8)
    • Flutter version 2.9.0-1.0.pre.182 at /home/ianh/dev/flutter
    • Upstream repository git@github.com:flutter/flutter.git
    • Framework revision 4d6122bb15 (73 minutes ago), 2021-12-23 18:54:13 -0500
    • Engine revision cd6a827fd5
    • Dart version 2.16.0 (build 2.16.0-131.0.dev)
    • DevTools version 2.9.2

[!] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
    • Android SDK at /home/ianh/Android/Sdk
    ✗ cmdline-tools component is missing
      Run `path/to/sdkmanager --install "cmdline-tools;latest"`
      See https://developer.android.com/studio/command-line for more details.
    ✗ Android license status unknown.
      Run `flutter doctor --android-licenses` to accept the SDK licenses.
      See https://flutter.dev/docs/get-started/install/linux#android-setup for more details.

[✓] Chrome - develop for the web
    • Chrome at google-chrome

[✓] Linux toolchain - develop for Linux desktop
    • clang version 10.0.0-4ubuntu1
    • cmake version 3.16.3
    • ninja version 1.8.2
    • pkg-config version 0.29.1

[✓] Android Studio (version 2020.3)
    • Android Studio at /home/ianh/bin/android-studio
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)

[✓] Connected device (2 available)
    • Linux (desktop) • linux  • linux-x64      • Ubuntu 20.04.3 LTS 5.4.0-91-generic
    • Chrome (web)    • chrome • web-javascript • Google Chrome 96.0.4664.45

[✓] HTTP Host Availability
    • All required HTTP hosts are available

! Doctor found issues in 1 category.

```

## Flutter Application Metadata
**Type**: malformed
**Version**: null
**Material**: false
**Android X**: false
**Module**: false
**Plugin**: false
**Android package**: null
**iOS bundle identifier**: null
**Creation channel**: null
**Creation framework version**: null