aboutsummaryrefslogtreecommitdiffstats
path: root/components
diff options
context:
space:
mode:
authorJay Oster <jay@kodewerx.org>2024-12-12 15:38:24 -0800
committerGitHub <noreply@github.com>2024-12-12 23:38:24 +0000
commit53612dab90d08edc6ee3ba2856628c599a07fd83 (patch)
treeed4c536d53690091df4818d92ba6c4f7c1a35e5f /components
parentf7e2ec3a0f2a389ecca1019f09f8b99b7e65ff38 (diff)
downloadservo-53612dab90d08edc6ee3ba2856628c599a07fd83.tar.gz
servo-53612dab90d08edc6ee3ba2856628c599a07fd83.zip
Fix devtools timeout with Firefox 133 (#34602)
Signed-off-by: Jay Oster <jay@kodewerx.org>
Diffstat (limited to 'components')
-rw-r--r--components/devtools/actors/root.rs21
1 files changed, 20 insertions, 1 deletions
diff --git a/components/devtools/actors/root.rs b/components/devtools/actors/root.rs
index d6a4f2e4edd..a252255f52e 100644
--- a/components/devtools/actors/root.rs
+++ b/components/devtools/actors/root.rs
@@ -115,6 +115,13 @@ struct GetProcessResponse {
process_descriptor: ProcessActorMsg,
}
+#[derive(Serialize)]
+struct ErrorResponse {
+ from: String,
+ error: String,
+ message: String,
+}
+
pub struct RootActor {
pub tabs: Vec<String>,
pub workers: Vec<String>,
@@ -249,7 +256,19 @@ impl Actor for RootActor {
ActorMessageStatus::Processed
},
- _ => ActorMessageStatus::Ignored,
+ _ => {
+ let reply = ErrorResponse {
+ from: self.name(),
+ error: "unrecognizedPacketType".to_owned(),
+ message: format!(
+ "Actor {} does not recognize the packet type '{}'",
+ self.name(),
+ msg_type,
+ ),
+ };
+ let _ = stream.write_json_packet(&reply);
+ ActorMessageStatus::Ignored
+ },
})
}
}