Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid Standard Handle Panic on Windows Server 2012 #26

Closed
FabianKramm opened this issue Apr 7, 2021 · 3 comments
Closed

Invalid Standard Handle Panic on Windows Server 2012 #26

FabianKramm opened this issue Apr 7, 2021 · 3 comments

Comments

@FabianKramm
Copy link

FabianKramm commented Apr 7, 2021

Hello!

Since PR #9 we receive the following panic with the moby/term package on a windows server 2012 within a powershell (it worked fine before that), when trying to call term.StdStreams():

panic: Invalid standard handle identifier: 4294967286

goroutine 1 [running]:
github.com/Azure/go-ansiterm/winterm.GetStdFile(0xfffffff6, 0x28, 0xf)
        C:/Users/Administrator/DevSpace/devspace/vendor/github.com/Azure/go-ansiterm/winterm/ansi.go:173 +0x1f6
github.com/moby/term/windows.NewAnsiReader(0xfffffff6, 0xc00000000f, 0x2110980)
        C:/Users/Administrator/DevSpace/devspace/vendor/github.com/moby/term/windows/ansi_reader.go:34 +0x36
github.com/moby/term.StdStreams(0x210ed20, 0xc0000d0000, 0x210ed60, 0xc0000d0008, 0x0, 0x0)
        C:/Users/Administrator/DevSpace/devspace/vendor/github.com/moby/term/term_windows.go:74 +0x1f8

Its essentially the same error as described in for-win. Maybe I'm mistaken, but I though the PR #9 would replace the github.com/Azure/go-ansiterm package completely, however it seems to be still used in windows/ansi_reader.go, which could cause this issue.

@FabianKramm FabianKramm changed the title Panic on Windows Server 2012 Invalid Standard Handle Panic on Windows Server 2012 Apr 7, 2021
n4j added a commit to n4j/term that referenced this issue Jun 8, 2021
Upgraded version of Azure/go-ansiterm from v0.0.0-20170929234023-d6e3b3328b78 to v0.0.0-20210608035416-43c61cb656b4 which fixes issue moby#26, kubernetes/kubernetes#102404 and docker/for-win#9770

Latest version of go-ansiterm is compatible with the stdin, stdout and stderr flags passed to `winterm.GetStdFile`  function from package `golang.org/x/sys/windows` and it's also backwards compatible with `syscall` package as well
n4j added a commit to n4j/term that referenced this issue Jun 8, 2021
Upgraded version of Azure/go-ansiterm from v0.0.0-20170929234023-d6e3b3328b78 to v0.0.0-20210608035416-43c61cb656b4 which fixes issue moby#26, kubernetes/kubernetes#102404 and docker/for-win#9770

Latest version of go-ansiterm is compatible with the stdin, stdout and stderr flags passed to `winterm.GetStdFile`  function from package `golang.org/x/sys/windows` and it's also backwards compatible with `syscall` package as well

Signed-off-by: n4j <neerajx86@gmail.com>
@n4j
Copy link
Contributor

n4j commented Jun 15, 2021

@FabianKramm this issue is fixed in the latest version of moby-term. Can you please check?

@n4j
Copy link
Contributor

n4j commented Jun 23, 2021

@FabianKramm Did you get a chance to look at this? If we are good here then can we close this issue?

@FabianKramm
Copy link
Author

@n4j Sorry for the delay, I was quite busy the last days. Just confirmed the newest version works on Windows Server 2012 now, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants