Skip to content

Commit 85958a1

Browse files
authored
Merge pull request #214 from vyasgun/pr/enable-virtual-terminal-processing
windows print: enable virtual terminal processing
2 parents f7e7374 + e0a2b19 commit 85958a1

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

v3/termutil/term_win.go

+1-2
Original file line numberDiff line numberDiff line change
@@ -138,9 +138,8 @@ func lockEcho() (err error) {
138138
}
139139

140140
newState := oldState
141-
const ENABLE_ECHO_INPUT = 0x0004
142141
const ENABLE_LINE_INPUT = 0x0002
143-
newState = newState & (^(ENABLE_LINE_INPUT | ENABLE_ECHO_INPUT))
142+
newState = newState & (^ENABLE_LINE_INPUT)
144143
if _, _, e := syscall.Syscall(setConsoleMode.Addr(), 2, uintptr(syscall.Stdout), uintptr(newState), 0); e != 0 {
145144
err = fmt.Errorf("Can't set terminal settings: %v", e)
146145
return

0 commit comments

Comments
 (0)