using lic non-interactively hoses terminal mode #1

Closed
opened 2018-12-17 15:49:15 +01:00 by ni · 3 comments
ni commented 2018-12-17 15:49:15 +01:00 (Migrated from git.w21.org)

For instance, running

$ lic 3 4 +

in the shell hoses the terminal mode. With Linux, after running this, the following settings are different from before:
-icrnl -ixon -icanon -iexten -echo

Expected behaviour: does not hose terminal mode.

Assumed reason: the application puts lingo/liner in raw mode, which is unnecessary with a non-interactive call of lingo. That it doesn't restore the previous terminal mode is more or less expected.

What is bad about this: The (assumed) bug in the application lic isn't even the bad thing. Lingo itself should not make this possible.

Proposed solution: Put changing the terminal mode forth and back (i.e. the related liner calls) as close around the actual line reading as possible. This should eliminate most of the application's responsibility already; furthermore, lingo could work actively in restoring the terminal settings actively to the previous state when exiting. Does mean you couldn't use a lingo program to change your terminal settings, but WTH.

For instance, running ``` $ lic 3 4 + ``` in the shell hoses the terminal mode. With Linux, after running this, the following settings are different from before: `-icrnl -ixon -icanon -iexten -echo` *Expected behaviour*: does not hose terminal mode. *Assumed reason*: the application puts lingo/liner in raw mode, which is unnecessary with a non-interactive call of lingo. That it doesn't restore the previous terminal mode is more or less expected. *What is bad about this*: The (assumed) bug in the application `lic` isn't even the bad thing. Lingo itself should not make this possible. *Proposed solution*: Put changing the terminal mode forth and back (i.e. the related liner calls) as close around the actual line reading as possible. This should eliminate most of the application's responsibility already; furthermore, lingo could work actively in restoring the terminal settings actively to the previous state when exiting. Does mean you couldn't use a lingo program to change your terminal settings, but WTH.
ni commented 2020-07-08 15:24:16 +02:00 (Migrated from git.w21.org)

mentioned in issue #4

mentioned in issue #4
ni commented 2020-07-12 13:39:09 +02:00 (Migrated from git.w21.org)

mentioned in commit 0e3ad67fda

mentioned in commit 0e3ad67fda0dd7218ef5b645df42cf9df28ff372
ni commented 2020-07-12 13:40:00 +02:00 (Migrated from git.w21.org)

closed via commit 0e3ad67fda

closed via commit 0e3ad67fda0dd7218ef5b645df42cf9df28ff372
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
lisp/lingo#1
No description provided.