Skip to content

Commit 233435b

Browse files
committed
Fix deprecated indexing of open call in windows displaysize
missed from #12807, only happens when running in mintty
1 parent bfd5a0e commit 233435b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

base/stream.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,7 @@ function displaysize(io::TTY)
362362
if ispty(io)
363363
# io is actually a libuv pipe but a cygwin/msys2 pty
364364
try
365-
h, w = map(x -> parse(Int, x), split(readstring(open(Base.Cmd(String["stty", "size"]), "r", io)[1])))
365+
h, w = parse.(Int, split(readstring(open(Base.Cmd(String["stty", "size"]), "r", io).out)))
366366
h > 0 || (h = default_size[1])
367367
w > 0 || (w = default_size[2])
368368
return h, w

0 commit comments

Comments
 (0)