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

Console.CursorLeft, Console.CursorTop, Console.WindowWidth, Console.WindowHeight and Console.WindowTopLeft doesn't throw an IOException for invalid values on Windows 7 x86 when Input is redirected #43138

Closed
ViktorHofer opened this issue Oct 7, 2020 · 3 comments

Comments

@ViktorHofer
Copy link
Member

Happening when input/output is redirected for the in the title noted properties.

Example:

Assert.Throws() Failure
Expected: typeof(System.IO.IOException)
Actual:   typeof(System.ArgumentOutOfRangeException): Positive number required. (Parameter 'width')
Actual value was -1.
---- System.ArgumentOutOfRangeException : Positive number required. (Parameter 'width')
Actual value was -1.

Currently affected tests:

  • WindowAndCursorProps.WindowAndCursorProps.WindowWidth_SetInvalid_ThrowsArgumentOutOfRangeException
  • WindowAndCursorProps.WindowAndCursorProps.CursorLeft_SetInvalid_ThrowsArgumentOutOfRangeException
  • WindowAndCursorProps.WindowAndCursorProps.WindowHeight_SetInvalid_ThrowsArgumentOutOfRangeException
  • WindowAndCursorProps.WindowAndCursorProps.CursorTop_SetInvalid_ThrowsArgumentOutOfRangeException
  • WindowAndCursorProps.WindowAndCursorProps.WindowLeftTop_Windows

It looks like the underlying Win32 API doesn't throw the getter of these properties is accessed during the set of the properties.

cc @eiriktsarpalis @stephentoub

@Dotnet-GitSync-Bot Dotnet-GitSync-Bot added area-System.Console untriaged New issue has not been triaged by the area owner labels Oct 7, 2020
@ghost
Copy link

ghost commented Oct 7, 2020

Tagging subscribers to this area: @eiriktsarpalis, @jeffhandley
See info in area-owners.md if you want to be subscribed.

@eiriktsarpalis
Copy link
Member

Related to #43015

@eiriktsarpalis eiriktsarpalis removed the untriaged New issue has not been triaged by the area owner label Oct 29, 2020
@eiriktsarpalis eiriktsarpalis added this to the Future milestone Oct 29, 2020
@adamsitnik
Copy link
Member

dotnet/announcements#226

@adamsitnik adamsitnik closed this as not planned Won't fix, can't repro, duplicate, stale Jul 7, 2022
@ghost ghost locked as resolved and limited conversation to collaborators Aug 6, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants