Possible Reason Behind Version Hop to Windows 10: Compatibility
First time accepted submitter ndykman (659315) writes The Independent reports that a MS developer has suggested a real reason behind the Windows 10 name: old code. More specifically, code that looks for "Windows 9" to determine the Windows version. Fine for Windows 95 or Windows 98, but not so great for a new operating system. The article includes a link that shows that yes, this would be a problem.
Its the same thing as with the whole Document and settings vs C:\users. There's always been a good way to get it, but most developers suck balls and won't spend the 20 seconds it takes to figure it out.
GetVersionEx(Inout_ LPOSVERSIONINFO lpVersionInfo);
Returns the major and minor versions, build number, platform id, service pack major and minor, and the product type.
It basically spits out all the crap in that appears on the bottom right corner of windows when you boot up in safemode.
Also unlike the stupid marketing names the OS versions actually make sense.
Windows 8 returns version 6.2.
I call this hogwash. When you ask Windows what version it is in software, it doesn't return its marketing name (Windows 95, Windows 2000), it returns it's platform ID (1 for DOS based, 2 for NT based), and its version numbers in major, minor format. Windows 95 returned 4.0 (platform 1), Windows 98 returned 4.1 (platform 1). Windows 2000 returned 5.0 (platform 2).
In fact, I can't speak for the latest versions of Windows (because it has been a while since I've programmed), but even as late as Windows XP, a call to "get version" returns something completely different from the marketing version number/name.
For example, under Windows 95, GetVersion() would return "4.0." Under XP, it reports NT 5.1 or NT 5.2.
http://en.wikipedia.org/wiki/L...
Cogito, igitur comedam pizza.
I'm reminded of checking for browser version in Javascript when you need to hack around a limitation or non-standard here or there (especially back in the IE6 days). Anyone worth their salt said "You don't ask the browser what it is, you ask what it can do" because the easy ways to check were also easy to spoof. So it was better to see if it threw an error when you did X, or if you could access property.Y, etc., then use those results to figure out which browser you were running in. I don't think it's done as often these days, partly because of engines catching up and partly because of frameworks doing it for you.
Anyway, I don't know how trivial it would be to spoof the system information, but relying on the system to report its proper version doesn't seem like a good idea to me. Speaking of version, code like the last link is looking at the marketing name when looking at the actual version (i.e. Windows 6.1) would be better. Maybe Microsoft should just go with the internal version number: it will cause as much marketing confusion as Windows 10, avoid the "Windows 9" checks, and make the internal/marketing names more consistent.
The search in the article shows mainly Java applications.
But the coding problem isn't specific to Windows. Opera suffers from this problem and so does every web browser that had a "version 10" that browser strings looked only for "1" or version 20 that looked for a "2" like Firefox.
Opera still by default says its Opera 9.8
But ultimately, garbage code needs to be thrown away and programmers need to stop doing stupid things like this.
Type this into powershell:
(Get-WmiObject Win32_OperatingSystem).Caption
There's your marketing name.
Took about 60 seconds of Googling to not only find this, but to find it in code that was making the same sort of error we're talking about (not literally the number 9). See this: http://ss64.com/ps/get-wmiobje... -- that's using the -match operator which is a regex comparison, and thus inferring whether it's a server build by a mismatch between the marketing name and the build name..
Granted, I don't think powershell existed on Windows 95. I expect it's just wrapping an API that did exist. If it comes right down to it, the registry itself has the versioning information available to anybody who can use ctrl+f in regedit to find the key, and people do indeed do that.
Trust me, MS doesn't give the slightest concern about any broken Java apps.
No, I don't trust that statement in the slightest. Why would you think that? It's very contrary to Microsoft's behaviour in the past.
I have no idea why they chose to name Windows "Windows 10", and I'm not convinced of this, but this is not so implausible as you seem to think.
It’s long been used as shorthand in electronics so circuit diagrams don’t get cluttered up with zeros, i.e. a 2,200 Ohm resistor is often shortened to 2K2 Ohms, 1,500,000 Ohms is 1M5.
Blank until
I’m also an electronic technician, I have reprints of articles going back to the 1930s from Europe, the UK and Australia which use the notation I described, and you can even find it stamped on components from those regions. Either is acceptable as far as I’m concerned, as long as the nomenclature is consistent.
Blank until