Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions bin/apport-cli
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,15 @@ class CLIDialog:
sys.stdout.flush()

file = sys.stdin.fileno()
import os
if not os.isatty(file):
if multi_char:
response = str(sys.stdin.readline()).strip()
else:
response = str(sys.stdin.read(1))
sys.stdout.write("\n")
return response

saved_attributes = termios.tcgetattr(file)
attributes = termios.tcgetattr(file)
attributes[3] = attributes[3] & ~(termios.ICANON)
Expand Down
Loading