mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
Configure FfiNative resolver on dart:io (#176621)
This is needed by file watching implementation after dart-lang/sdk@ed6bab847b Ideally we should actually move this whole code into `io_natives.{h,cc}` on the Dart runtime side to avoid duplication.
This commit is contained in:
parent
44c77df80a
commit
e11e2c1128
@ -17,10 +17,13 @@ namespace flutter {
|
||||
|
||||
void DartIO::InitForIsolate(bool may_insecurely_connect_to_all_domains,
|
||||
const std::string& domain_network_policy) {
|
||||
// TODO(https://dartbug.com/61694): move this code into dart_io_api.h
|
||||
Dart_Handle io_lib = Dart_LookupLibrary(ToDart("dart:io"));
|
||||
Dart_Handle result = Dart_SetNativeResolver(io_lib, dart::bin::LookupIONative,
|
||||
dart::bin::LookupIONativeSymbol);
|
||||
FML_CHECK(!CheckAndHandleError(result));
|
||||
result = Dart_SetFfiNativeResolver(io_lib, dart::bin::LookupIOFfiNative);
|
||||
FML_CHECK(!CheckAndHandleError(result));
|
||||
|
||||
Dart_Handle ui_lib = Dart_LookupLibrary(ToDart("dart:ui"));
|
||||
Dart_Handle dart_validate_args[1];
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user