Skip to content

Commit

Permalink
Fix swapped dimensions from terminal.GetSize
Browse files Browse the repository at this point in the history
Signed-off-by: Anders F Björklund <[email protected]>
  • Loading branch information
afbjorklund committed Mar 26, 2021
1 parent 9e23e0b commit 826c228
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 1 addition & 1 deletion pkg/bindings/containers/attach.go
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ func attachHandleResize(ctx, winCtx context.Context, winChange chan os.Signal, i
case <-winCtx.Done():
return
case <-winChange:
h, w, err := terminal.GetSize(int(file.Fd()))
w, h, err := terminal.GetSize(int(file.Fd()))
if err != nil {
logrus.Warnf("failed to obtain TTY size: %v", err)
}
Expand Down
2 changes: 0 additions & 2 deletions test/system/450-interactive.bats
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,6 @@ function teardown() {
# BEGIN tests

@test "podman detects correct tty size" {
skip_if_remote "FIXME: resolved in #9782"

# Set the pty to a random size. Make rows/columns odd/even, to guarantee
# that they can never be the same
rows=$(( 15 + RANDOM % 60 | 1 ))
Expand Down

0 comments on commit 826c228

Please sign in to comment.