aboutsummaryrefslogtreecommitdiff
path: root/alacritty_terminal/tests/ref.rs
diff options
context:
space:
mode:
authorChristian Duerr <contact@christianduerr.com>2021-04-17 23:20:13 +0000
committerGitHub <noreply@github.com>2021-04-17 23:20:13 +0000
commit28abb1f9c78ab316126bdf94e2ca12f034f1d8fd (patch)
tree623eabe9b4760fc4674f36a8f953e344b0e655e3 /alacritty_terminal/tests/ref.rs
parenta312e415951fcb9156572f124b42f68c09f60ae9 (diff)
downloadalacritty-28abb1f9c78ab316126bdf94e2ca12f034f1d8fd.tar.gz
alacritty-28abb1f9c78ab316126bdf94e2ca12f034f1d8fd.zip
Fix out of order terminal query responses
This forces all responses made to the PTY through the indirection of the UI event loop, making sure that the writes to the PTY are in the same order as the original requests. This just delays all escape sequences by forcing them through the event loop, ideally all responses which are not asynchronous (like a clipboard read) would be made immediately. However since some escapes require feedback from the UI to mutable structures like the config (e.g. color query escapes), this would require additional locking. Fixes #4872.
Diffstat (limited to 'alacritty_terminal/tests/ref.rs')
-rw-r--r--alacritty_terminal/tests/ref.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/alacritty_terminal/tests/ref.rs b/alacritty_terminal/tests/ref.rs
index e229b6d2..a9968736 100644
--- a/alacritty_terminal/tests/ref.rs
+++ b/alacritty_terminal/tests/ref.rs
@@ -2,7 +2,7 @@ use serde::Deserialize;
use serde_json as json;
use std::fs::{self, File};
-use std::io::{self, Read};
+use std::io::Read;
use std::path::Path;
use alacritty_terminal::ansi;
@@ -108,7 +108,7 @@ fn ref_test(dir: &Path) {
let mut parser = ansi::Processor::new();
for byte in recording {
- parser.advance(&mut terminal, byte, &mut io::sink());
+ parser.advance(&mut terminal, byte);
}
// Truncate invisible lines from the grid.