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.
It would get really confusing if they released a Windows 9.5 or Windows 9.8....
It would have been better if they'd gone with Windows 11. One better.
Who ordered that?
If something as stupid as the name of the operating system can trip up some applications, what about the rest of the code?
Instead of giving programmers dozens of ways of checking and doing things, they should be forced into doing it one way. Easier to prevent mistakes, check for errors, etc.
Get free satoshi (Bitcoin) and Dogecoins
if (os.startsWith("Windows 9") || os.equals("Windows Me")) {
ShootYourself();
}
//TODO: Insert catchy phrase
And looking at the code examples like 90% of the cases where in the Java sources.
Isn't there a more specific property that doesn't rely on location specific strings?
I mean the whole friggen world isn't English.
Does anybody seriously write any platform specific desktop code in Java that needs to check the Windows version??
.net function to get the Windows version string? Doesn't this return actual version numbers and not a string that you have to parse?
What's the standard Windows API, or
18 years as a developer, I've never used such a shitty test..
Couldn't care less about Microsoft's reason for skipping a version number - can't stand the fact I've been reading about this for 2 days already. What's the point in reading Slashdot if it reports things days behind every other news source. I get there's the discussion element, but I used to trust Slashdot to keep me up to date - now I'm never interested or surprised in anything it runs. RIP...
Mainstream media, please stop perpetuating this speculative misinformation. It is VERY unlikely, given that, according to an IP editor who removed my addition of this alleged, speculative information, "even if their assertion were correct, the confluence of events required to run on 95/98 *and* an unreleased Windows 9 without modifications is improbable. While that code exists in the wild (with modifications), none of it is remotely modern. They're using JDK6/7 internal test tools and code from a 13 year old version of jEdit as an example as to why "Windows 9" was skipped."
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).
Windows 8 is really version 6.3. http://en.wikipedia.org/wiki/L...
Windows! Nein!
Regards,
-Jeremy
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.
So you're telling me that Microsoft decided/had to skip a version number because of existing Java code? Rly? Srsly?
they should have just changed the whole name from "windows" to "Balmers gone, and its safe to us windows again, please come back".
Some drink at the fountain of knowledge. Others just gargle.
Old function: GetVersion() and GetVersionEx() [for Windows 8 and older]
New function: GetVersionEx2() [for Windows 9 and newer]
Seems a less intrusive solution that jumping a whole major Windows revision.
Considering the industry move to 64-bit (how long ago now?), how easy is it to get a 16-bit DOS or a 32-bit Windows app to run in a 64-bit *NT* environment?
Between 16 and 32 bit, you had (for 9x) the fact that the kernel was actually 16-bit but could address a 32-bit address space, for 32-bit NT systems you have WOWExec (a DOS VM with a shared memory space) but for running 16-bit apps on 64-bit platforms you have to go one step further than a compatibility subsystem (ie WOWExec) and run the app in a third party sandbox - or virtual machine, if you will - such as VirtualBox running a dedicated DOS or 9x session in a segregated memory space. Other esoteric limitations particularly in 64-bit Windows versions prompted Microsoft to issue an update which included zero-length root files (AUTOEXEC.BAT and CONFIG.SYS among others) in August 2010.
Long story short, if you're running into problems with "Windows 9" it's nothing to do with pulling a version number, you're trying to make a 64-bit system do a 16-bit thing which it was clearly not meant to do and will fail spectacularly anyway.
Political debates have me rolling my eyes so much I think I got optical whiplash. I should sue. - Foamy The Squirrel
Charms are gone in the preview version, such a small change, but it is a good one
Why not just go with "Windows Nine".
Politics; n. : A religion whereby man is god.
Windows does return integers. See the dwMajorVersion and dwMinorVersion members of the OSVERSIONINFOEX struct. This seems to be a Java-specific issue, or at least specific to Java programmers--for whatever reason, a lot of Java code checks the "os.name" property to determine the OS version instead of "os.version".
... because, you know, it might get confused with Windows 3.11 ?
That's a load of BS. Is there even an API that returns the "marketing" version of the OS name? I know of no way to programmatically get the text "Windows 95" or "Windows 98", etc, in the Windows API, unless I build that string myself. The APIs that return the OS version use a completely different versioning convention (one that actually makes sense and is consistent). Maybe there is some way to dig through the registry and find that, but any app doing that deserves to be broken anyway.
Further, the example and "proof" in that second link is also a load of crap. That is only via some Java API, which does exactly what I said above, which is turn the actual internal version into some higher-level OS name. Trust me, MS doesn't give the slightest concern about any broken Java apps.
They named it Windows 10 for marketing reasons. End of story. Quit being retarded.
Better known as 318230.
The charms bar isn't gone, but will be updated somehow; It is only for the touch version.
Most linux users don't know this, but the man pages were named after Chuck Norris. Chuck Norris fsck'ing hates noobs!
:'(
--charms dev
ps it's gone now are you happy
pss <3
Considering windows 95 and 98 would return an version number of 9, there is no reason that Windows 9 couldn't have returned a totally different number, say 10.
I bet it they went with 10 only as a symbolic leap from 8/8.1.
The problem isn't making sure code that worked on Windows 95 still works. It's code that wouldn't run in the DOS code tree, but will still run in the NT tree, and has code that prevents trying to run it on older systems...and, instead of checking for Windows_NT and proceeding, checked for Windows_9* and stopped.
And, for the record, on a Windows 7 box, the OS environment variable is still "Windows_NT". Somebody out there must have a 95 (or 98) box still running that could check if it shows "Windows_95". ("echo %OS%", but if you've still got a box that old, you knew that.)
Premature optimization is the root of all evil.
If your code is old enough to be checking for Windows 9x, chances are you're really asking "am I running under NT, or 9x?"
And os.version is 100% useless for that, since Windows NT and Windows 95 could both (honestly) report an os.version of "4.0".
So instead they checked the os.name since that check was easier and you had two "4.0" lines of code you wanted to tell apart. (Of course, then there was Windows ME. Oops. Of course, they could have checked for Windows NT. But then there was Windows 2000. Oops.)
Of course, the real problem is that the Java API for checking the underlying OS version sucks ass and is literally a collection of three strings that have no well-defined values. (What's os.name under Linux? Just "Linux"? "GNU/Linux"? The distro name? I guess any of those are just as valid!)
You'd think by Java version 8 they could have added some better API for dealing with the OS like something as simple as an "os.family" value ("Windows NT", "OS X", "Linux") and APIs for dealing with comparing version numbers. But, nope. I mean, after all, there's a spec for what version numbers should look like but the API for dealing with them still processes them as strings! (Well, there is java.lang.Package.isCompatibleWith(String) which would still be useless in this case.)
You are in a maze of twisty little relative jumps, all alike.
Someone at MS is just pulling this out of their asses to try and cover that Microsoft has no clue what they are doing.
So they were able to easily query the code for a few thousand applications online that made this version check mistake. Big deal.
Compare this to how many applications out that that have broken because of other minor OS changes combined with bad programming. I've seen piles of that myself, and Microsoft never bothered this hard to keep compatibility for any of those.
if (os.startsWith("Windows")
use linux
fi
# There you go, fixed it for you.
A key selling point of windows is backward compatibility. Lose that and the companies that have been using windows software for years suddenly have to buy new software... and then they might as well switch to linux.
I've decided to stop wasting my time responding to AC trolls/sockpuppets... so if you want a response from me... login.
I always just assumed they were inspired by Leisure Suit Larry versioning system.
Monstar L
Go to a command prompt and it gives the version number. WIN 7 comes back as 6.1.7601.
Why wouldn't they just change whatever internal version number is being improperly queried to 10, have the correct API call return 9, and market it as 9? Maybe once they realized there was a problem, they decided they liked the idea of 10 and it would be the simplest fix? Or perhaps these bad apps are using the correct API call (as opposed to pulling a registry key or something) but are parsing it incorrectly... The correct approach would be to issue an advisory for all these shitty programmers to update their applications or they may not work on Windows 9. Fix your shit, or GTFO, basically. In any case, glad I don't have to deal with that sort of crap anymore. Linux has its own steaming pile for me to wade through these days. :)
Buy your next Linux PC at eightvirtues.com
Now can somebody explain "Xbox One?"
Yes, it is supposed to be the "Xbox" that is is going to be the "one" device for all things in your living room. Pity no one told Microsoft that "Xbox one" can be abbreviated to "XBone" and after the numerous 180's the XB1's name should have been changed to XB180 or to keep the revisions correct XB540 which would be more in-line with their current numbering system.
Actually the XBox's numbering system can be better explained in simple maths terms. "X" is normally used to designate an unknown number so "Xbox" would translate to "Unknown Box" so being fair and using the abbreviations that the Playstation uses "XB1" would translate to "Unknown Box version 1" which we know that can't be true since there is already an "Unknown Box" and version 2 should translate to "Unknown Box version 2" or XB360 as it is more popularly known.
No! No! that can't be right. The original "Unknown Box" must be version 0 then the next release must be "Unknown Box version 1" (XB360) therefore the next release should be "Unknown Box version 2" (XB1), This now proves that 0 is greater than 360 (great so far), and 1 is greater then 360 Err!!
All this shows that Microsoft is really bad as simple maths :)
There ain't no such thing as proprietary standards only proprietary formats. Standards are by definition open.
There really were "Windows Nein" jokes already waiting for it some of them involving moustaches, svatiskas and hysterical screams (decency standards need not apply)
There is: GetVersion()
No one was forced to deal with a string. TFA is talking about third-party developers who may have use the marketing name instead of the recommended API call to check versions.
It must have been something you assimilated. . . .
...with Windows 100.
I've seen at least one suggestion that all future versions of Windows will be Windows 10. So, that would presumably be Windows 10.90 you're looking forward to?
for whatever reason, a lot of Java code checks the "os.name" property to determine the OS version instead of "os.version".
Because Java's API design is fucked up.
Windows NT 4.0: os.name = "Windows NT", os.version = "4.0"
Windows 95 (= MSDOS 7.0): os.name = "Windows 95", os.version = "4.0"
Windows 98: (also MSDOS 7.0): os.name = "Windows 98", os.version = "4.1"
Windows 2000 (aka NT 5): os.name = "Windows 2000", os.version = "5.0"
Given these 4 versions as the likely target platforms, how do I determine if I'm running on Windows-the-DPMI-DOS-Extender or Windows NT?
http://searchcode.com/?q=if(version%2Cstartswith(%22windows+9%22)
If your code is old enough to be checking for Windows 9x, chances are you're really asking "am I running under NT, or 9x?"
A relatively recent program designed for XP or Vista could be checking for Windows 9x during install, like if (OS.name.StartsWith('Windows 9')) {print "Your computer is too old, please upgrade to XP"}
When FreeBSD started having "10" in the version number, a lot of 3rd party (open source) software thought it must be version "1.0" (based on checks by GNU configure) which usually resulted in a failure to even go through the configure-phase....
Same reason why Solaris 11 is actually 2.11...
Windows 2000 - from the guys who brought us edlin
But then there would be the inevitable Spinal Tap jokes.
is there's often 5 ways to do something. The first works, but will slow your app to a crawl. The next two only work on your test machine. The 4th works, but it has horrible side effects. There's a registry query function that triggers a scan of the registry, which on a broken registry can kill the whole OS. Who the hell thought that was a good idea?
Finally there's the 1 method that works. I find writing Windows apps a bit like playing Russian Roulette...
Hi! I make Firefox Plug-ins. Check 'em out @ https://addons.mozilla.org/en-US/firefox/addon/youtube-mp3-podcaster/
Legacy 9x code doesn't run on Win8 unless you're using the built in VMs from the fancier editions. They took most of the old Win32 stuff out.
Hi! I make Firefox Plug-ins. Check 'em out @ https://addons.mozilla.org/en-US/firefox/addon/youtube-mp3-podcaster/
Maybe it is simply that the project that would have been Windows 9 got canned within Microsoft. I am sure work on Win 9 was underway by the time Win 8.0 was released just to have its plug pulled after the dismal and entirely preventable (if Microsoft would have listened to beta testers) sales figures and adoption rate of Win 8. As much speculation as any other explanation. In the end it does not matter, it's just a name.
Windows 1 was distributed on 3.5" floppies. 720k floppies, no less. I know, I still have a copy, though I have no way to load it.
Is it just my observation, or are there way too many stupid people in the world?
Every other version of Windows is a dog: XP to Vista, then 7, then 8. 9 should be a winner, but maybe MS already knows it is essentially 8.2, so they needed to skip to 10 to keep the streak alive.
Are we really sure it isn't simply that MS developers can't count? That would explain a few things...
Stupid programmers. os.name is used to identify Windows (as opposed to Linux, iOS, whatever). os.version is used to identify which version of Windows (or any OS) you are running.
This is stupid! Why don't they have a standard way of doing things!?!
Standards have a way of biting you in the ass, for example this standard way of abbreviating the year.
It seems ironic that an abbreviated name was used for a problem caused by abbreviations.
But that's a perfectly normal abbreviation!
No it's not! This other system of abbreviation makes much more sense!
No, the first kind of abbreviation makes more sense in some contexts because of these reasons.
And so we have come full circle to why we can't just have one method of doing things, and thus why we can't have nice things.
Also, obligatory xkcd: http://xkcd.com/927/
This Space Intentionally Left Blank
My Windows 1.0 apps are now working on Windows 10 Technical Preview! *WOOHOO*