Bug #69781 [Fbk->Opn]: phpinfo() reports Professional Editions of Windows 7/8/8.1/10 as "Business"
| From: | cmb@php.net | Date: | Wed, 10 Jun 2015 00:13:01 +0000 |
| Subject: | Bug #69781 [Fbk->Opn]: phpinfo() reports Professional Editions of Windows 7/8/8.1/10 as "Business" | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-193268@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=69781&edit=1
ID: 69781
Updated by: cmb@php.net
Reported by: wenz@php.net
Summary: phpinfo() reports Professional Editions of Windows
7/8/8.1/10 as "Business"
-Status: Feedback
+Status: Open
Type: Bug
Package: PHP options/info functions
Operating System: Windows
PHP Version: Irrelevant
Assigned To: ab
Block user comment: N
Private report: N
New Comment:
Switched back to "open" to avoid the bug tracker to close the ticket prematurely. :)
Previous Comments:
------------------------------------------------------------------------
[2015-06-09 08:45:40] wenz@php.net
(might have messed up the PR since I was playing around with the web interface and syncing first,
which showed up in the history. However the file changes are correct.)
I have also tested the patch with 5.6 and master, so that could be merged for those, too.
------------------------------------------------------------------------
[2015-06-09 08:02:22] wenz@php.net
Related To: Bug #54020
------------------------------------------------------------------------
[2015-06-09 08:00:41] wenz@php.net
Description:
------------
Microsoft changed the behavior of GetProductInfo with Windows 7 and upwards:
https://msdn.microsoft.com/en-us/library/windows/desktop/ms724358%28v=vs.85%29.aspx
Obviously due to maintain backwards compatibility, applications that were compiled to be compatible
with Windows Vista report the Professional, Professional N, and Starter N editions of Windows as
Business, Business N, and Starter.
We could fix this by defining _WIN32_WINNT as 0x0600 or higher, but would then loose Windows Vista
support.
The pull request fixes that in a pretty straight forward way. There could be a more elaborate fix,
since the "official" wording for the Professional editions from Windows 8 onwards is
"Pro", but I'd say we leave it for now.
Bug #55319 reports a specific aspect of this bug, namely the "Business" instead of
"Professional".
Test script:
---------------
<?php
phpinfo(INFO_GENERAL);
Expected result:
----------------
Output contains "Windows 7 Professional" on a Windows 7 Professional machine.
Actual result:
--------------
Output contains "Windows 7 Business".
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=69781&edit=1