-
Notifications
You must be signed in to change notification settings - Fork 6k
Allow for whitelisted flags to be passed to the Dart VM #9148
Conversation
| FLUTTER_RUNTIME_MODE != FLUTTER_RUNTIME_MODE_DYNAMIC_RELEASE | ||
|
|
||
| // List of common and safe VM flags to allow to be passed directly to the VM. | ||
| static const std::string gDartFlagsWhitelist[] = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The current whitelist is just composed of some flags that I thought would be useful and safe. I'm happy to add/remove from this list based on feedback.
chinmaygarde
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add a unit test for this in the shell_unittests target?
shell/platform/android/io/flutter/app/FlutterActivityDelegate.java
Outdated
Show resolved
Hide resolved
Testing that the whitelist check catches bad flags will cause the process to exit. Did we just want to check that whitelisted flags aren't dropped? |
|
You can use death tests in the Google test harness https://github.com/google/googletest/blob/master/googletest/docs/advanced.md#death-tests |
Oh cool, I didn't know that existed. Thanks for guiding me in the right direction :-) I've added a couple of tests. |
flutter/engine@86aa014...bf15bd0 git log 86aa014..bf15bd0 --no-merges --oneline bf15bd0 Add the key event source, vendorId, and productId from Android (flutter/engine#9186) d4c7c30 Roll src/third_party/skia a4bb02063672..346f82c1c3e0 (6 commits) (flutter/engine#9188) 7746e2e Compile the physical_shape_layer_unittests.cc TU. (flutter/engine#9187) 12f48f7 Allow for whitelisted flags to be passed to the Dart VM (flutter/engine#9148) b304dab [scene_host] Cleanup scene_host closures (flutter/engine#9061) The AutoRoll server is located here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+/master/autoroll/README.md If the roll is causing failures, please contact the current sheriff ([email protected]), and stop the roller if necessary.
* Allow for whitelisted flags to be passed to the Dart VM Fixed part of flutter/flutter#32176
Fixes part of flutter/flutter#32176