0

Revert "Read all supplied lines from STDIN, not just first one."

This reverts commit 08bf20d43a. Do not
read whole STDIN as it somehow breaks whidow tracking feature.
This commit is contained in:
Sergei Fedosov
2021-07-20 12:04:19 +03:00
parent 08bf20d43a
commit 371dc68667
2 changed files with 34 additions and 35 deletions

View File

@@ -26,4 +26,3 @@ verbose = 8
[-Modules::RequireVersionVar]
[-CodeLayout::RequireTidyCode]
[-TestingAndDebugging::RequireUseWarnings]
[-ControlStructures::ProhibitDeepNests]

View File

@@ -229,10 +229,11 @@ sub add_events () {
fh => \*STDIN,
poll => 'r',
cb => sub {
while (my $msg = <>) {
my $msg = <>;
unless ($STDIN_FIRST_LINE_DROPPED) {
$msg = <>;
$STDIN_FIRST_LINE_DROPPED = 1;
next;
}
if ($msg) {
@@ -276,7 +277,6 @@ sub add_events () {
}
}
}
}
);
# poll caps lock status, on one of my laptop there is no led for this :(