-
Notifications
You must be signed in to change notification settings - Fork 306
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
win: New PaWinUtil_GetOsVersion() function for getting Windows OS version #830
Conversation
bd45895
to
0c9de1f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice. Thanks for doing this.
0c9de1f
to
0a557c0
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, I'll wait for Ross to review.
0a557c0
to
888dd84
Compare
Overlooked that WDMKS is also using |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi Dmitry,
In addition to my one review comment, could you please let us know what tests you have run on this new code. Thankyou!
…sion. Refactored WASAPI, DS, MME and WDMKS host back-ends to use PaWinUtil_GetOsVersion() instead of direct OS API.
888dd84
to
2aeebdc
Compare
I tested on Windows 10: PortAudio Test: output sine wave. SR = 44100, BufSize = 64
before paHostApiInitializers[0].
getting Windows version with RtlGetVersion(): major=10, minor=0, build=19045, platform=2
Windows version=10 also Windows UWP and the lowest I have is Windows Server 2003 R2. I did not test on Windows Vista, 7, 8. Windows Server 2003 R2 is practically latest Windows XP with 3790 build (https://en.wikipedia.org/wiki/List_of_Microsoft_Windows_versions) which is detected correctly: PortAudio Test: output sine wave. SR = 44100, BufSize = 64
before paHostApiInitializers[0].
getting Windows version with RtlGetVersion(): major=5, minor=2, build=3790, platform=2
Windows version=5 Unfortunately I did not implement testing of every Windows version that could be done with Docker I believe due to lack of time resource. The underlying implementation is a copy-paste from the WASAPI's implementation which is time-tested on Windows Vista, 7, 8. |
As per discussion in #796 introducing a single API for getting Windows OS version in PA that will improve client code readability and reliability.
Additionally:
PaWinUtil_GetOsVersion()
instead of direct OS API