mirror of
https://github.com/flutter/flutter.git
synced 2025-06-03 00:51:18 +00:00
Fix a crash in remote device daemon. (#144358)
The daemon server is expecting the client to pass `deviceId` in `device.shutdownDartDevelopmentService` method.
24a792dae1/packages/flutter_tools/lib/src/commands/daemon.dart (L1239)
This commit is contained in:
parent
b099bf0b4c
commit
cfa011dd9d
@ -810,7 +810,9 @@ class ProxiedDartDevelopmentService implements DartDevelopmentService {
|
|||||||
await _localDds.shutdown();
|
await _localDds.shutdown();
|
||||||
_ddsStartedLocally = false;
|
_ddsStartedLocally = false;
|
||||||
} else {
|
} else {
|
||||||
await connection.sendRequest('device.shutdownDartDevelopmentService');
|
await connection.sendRequest('device.shutdownDartDevelopmentService', <String, Object?>{
|
||||||
|
'deviceId': deviceId,
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -615,6 +615,9 @@ void main() {
|
|||||||
final DaemonMessage shutdownMessage = await broadcastOutput.first;
|
final DaemonMessage shutdownMessage = await broadcastOutput.first;
|
||||||
expect(shutdownMessage.data['id'], isNotNull);
|
expect(shutdownMessage.data['id'], isNotNull);
|
||||||
expect(shutdownMessage.data['method'], 'device.shutdownDartDevelopmentService');
|
expect(shutdownMessage.data['method'], 'device.shutdownDartDevelopmentService');
|
||||||
|
expect(shutdownMessage.data['params'], <String, Object?>{
|
||||||
|
'deviceId': 'test_id',
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
testWithoutContext('starts a local dds if the VM service port is not a forwarded port', () async {
|
testWithoutContext('starts a local dds if the VM service port is not a forwarded port', () async {
|
||||||
|
Loading…
Reference in New Issue
Block a user