Beta

Slashdot: News for Nerds

×

Welcome to the Slashdot Beta site -- learn more here. Use the link in the footer or click here to return to the Classic version of Slashdot.

Thank you!

Before you choose to head back to the Classic look of the site, we'd appreciate it if you share your thoughts on the Beta; your feedback is what drives our ongoing development.

Beta is different and we value you taking the time to try it out. Please take a look at the changes we've made in Beta and  learn more about it. Thanks for reading, and for making the site better!

cancel ×

247 comments

Who could have foreseen a leap year coming? (5, Funny)

elrous0 (869638) | more than 2 years ago | (#39208835)

Seriously, if my American high school education taught me nothing else, it was that those things only come along like every 100 years or something.

Re:TCO TIC (5, Funny)

tripleevenfall (1990004) | more than 2 years ago | (#39208917)

Obviously you didn't inform yourself with the very helpful and informative "Get The Facts" materials Microsoft provided us with a few years ago. If you had you would know how much higher the TCO of Linux on the server is even after a massive outage.

Re:TCO TIC (1)

rogueippacket (1977626) | more than 2 years ago | (#39209507)

Haha, my "Get The Facts" materials came with a free subscription to Wired if I do recall. The funny part is, I never actually got around to reading the Microsoft stuff - our receptionist recycled it without hesitation. I knew this had happened when I saw only a copy of Wired on my desk.

Re:Who could have foreseen a leap year coming? (-1)

CryptDemon (1772622) | more than 2 years ago | (#39208949)

Actually every hundred year is when a leap year doesn't come along. (unless it's divisible by 400, then it does)

Re:Who could have foreseen a leap year coming? (4, Funny)

tripleevenfall (1990004) | more than 2 years ago | (#39209001)

Save us, Captain Obvious! *swoons* :P

Re:Who could have foreseen a leap year coming? (5, Funny)

Kamiza Ikioi (893310) | more than 2 years ago | (#39209177)

In all fairness, Microsoft never figured anyone would still be using this service by the time a leap year rolled around.

Re:Who could have foreseen a leap year coming? (2)

davidbrit2 (775091) | more than 2 years ago | (#39209645)

I think I like this theory the best.

Re:Who could have foreseen a leap year coming? (1)

NatasRevol (731260) | more than 2 years ago | (#39210205)

I thought that was Halley's comet?

Same Story / Different Day (5, Funny)

DownWithTheMan (797237) | more than 2 years ago | (#39208927)

Didn't this happen last leap year to the Zunes... oh yeah... [pcworld.com]

Re:Same Story / Different Day (4, Insightful)

g0bshiTe (596213) | more than 2 years ago | (#39208985)

You would think that they would have remembered, or some brilliant mind would have said "hey don't forget leap days", they should have asked the janitor. Those guys know everything.

Re:Same Story / Different Day (3, Funny)

robthebloke (1308483) | more than 2 years ago | (#39209785)

Like how to brush the problem under the carpet for another 4 years?

Re:Same Story / Different Day (5, Interesting)

firex726 (1188453) | more than 2 years ago | (#39209035)

What is with MS and their apparent inability to cope with leap years?

Re:Same Story / Different Day (2)

JazzHarper (745403) | more than 2 years ago | (#39209787)

I would like to know the same thing. This seems to be systemic. Is there something inherently confusing or flawed in the way Microsoft approaches elapsed-time calculations? Is it due to the internal representation of time that they use, or is there some reason that developers on their platform are doing calculations using date strings, or is it something else?

Re:Same Story / Different Day (1)

The Grim Reefer (1162755) | more than 2 years ago | (#39210185)

What is with MS and their apparent inability to cope with leap years?

This time they thought the Mayan calendar ended at the beginning of 2012 and not the end.

Re:Same Story / Different Day (2)

UnknowingFool (672806) | more than 2 years ago | (#39209597)

Yes and it will happen again. As far as I know MS never created a patch. They just told customers to wait out the bug. Looks like it will happen again this year.

Re:Same Story / Different Day (1)

roc97007 (608802) | more than 2 years ago | (#39209729)

I'm wondering if the bug started in some early version of ms-dos and then propagated to all their other projects ever since through code re-use...

Re:Same Story / Different Day (5, Interesting)

UnknowingFool (672806) | more than 2 years ago | (#39209897)

No it came from Freescale in a driver that Toshiba used. Not many know that the original Zune was a Toshiba Gigabeat with a new UI and outer shell.

Re:Same Story / Different Day (5, Funny)

John Hasler (414242) | more than 2 years ago | (#39210033)

Well, we knew it was a Microsoft product so we knew they bought it from someone.

Re:Same Story / Different Day (1)

KhabaLox (1906148) | more than 2 years ago | (#39209927)

"If you're a Zune Pass subscriber, you may need to sync your device with your PC to refresh the rights to the subscription content you have downloaded to your device.

That's the scariest sentence in that entire article.

28 days (5, Funny)

ichthus (72442) | more than 2 years ago | (#39208937)

Well, this is all because 28 days in February ought to be enough for everyone.

Re:28 days (1)

Moheeheeko (1682914) | more than 2 years ago | (#39208995)

The people who pay employees by salary instead of hourly certainly think so.

http://www.usnews.com/news/articles/2012/02/29/february-29-all-work-and-no-pay

Re:28 days (1)

tuffy (10202) | more than 2 years ago | (#39209141)

In 2012 there are 261 weekdays. In 2011, there were 260. But in 2010 and 2009 there were also 261 weekdays. So not really.

Re:28 days (1)

geekoid (135745) | more than 2 years ago | (#39209367)

yeah... because salary workers never work on weekends.

Funny, as an hourly person, I never work weekends..or more then 40 a week.

Re:28 days (1)

Chris Mattern (191822) | more than 2 years ago | (#39209999)

Article makes an assumption that is usually not true--that salaried workers get paid on a month-related schedule, which always causes all sorts of problems, not just leap-year related. I'm salaried and get paid every two weeks; leap year means squat as far as getting paid is concerned.

Re:28 days (1)

John Hasler (414242) | more than 2 years ago | (#39210091)

When I was on salary (back in ancient times) the deal was that I got $10,000/year (I said ancient times) paid out in 12 equal installments. Yes, the pay periods varied in length. So what?

Re:28 days (5, Funny)

davidbrit2 (775091) | more than 2 years ago | (#39209687)

I always remember to put DEVICEHIGH=FEB.SYS into my config.sys every four years.

Re:28 days (1)

Anonymous Coward | more than 2 years ago | (#39210471)

I'm old enough to admit DOS jokes still crack me up. Good one!

What a shame (1)

gzipped_tar (1151931) | more than 2 years ago | (#39208955)

We still see this kind of XXXX coming up every leap year.

Re:What a shame (4, Funny)

TheCRAIGGERS (909877) | more than 2 years ago | (#39210297)

We still see this kind of XXXX coming up every leap year.

We're all adults (or close enough to it, anyway) here. I think we're all capable of seeing the word "shit" without our faces melting like that nazi who peeped in the ark.

My apologies to everyone who is now having their face melt off after reading that previous sentence.

What is it with Microsoft and Leap Year? (3, Informative)

madsci1016 (1111233) | more than 2 years ago | (#39208969)

Anyone remember trying to turn on their Zune 3.5 years ago? [slashdot.org] That didn't work so well either.

Re:What is it with Microsoft and Leap Year? (4, Informative)

Kozz (7764) | more than 2 years ago | (#39209635)

Now, I'm not necessarily a Microsoft apologist, but I have to point out that it wasn't so long ago that other things near and dear to us geeks were experiencing similar problems.

I was trying to run some ant scripts yesterday that interact with an FTP server to delete some files. Those damned files wouldn't get deleted. They weren't even returned from a listing command. As it turns out, I was using a particularly old version of Apache Commons-Net library (this jar file was from 2005) which had a leap-year bug. It simply would not show me files with modification dates of 2/29. I was looking at the FTP server configuration, logging in with other clients, moving and renaming files, and all about ready to break out Wireshark... and then it occurred to me that it was leap day. Hoo-fucking-ray. "touch"ed the file, and sure enough, it was suddenly available. Those are a few hours of my life I'll never get back.

Re:What is it with Microsoft and Leap Year? (0)

Anonymous Coward | more than 2 years ago | (#39209909)

You can be forgiven for not having tested your script. Azure is another kind of beast.

Re:What is it with Microsoft and Leap Year? (2, Funny)

egamma (572162) | more than 2 years ago | (#39209931)

Now, I'm not necessarily a Microsoft apologist, but I have to point out that it wasn't so long ago that other things near and dear to us geeks were experiencing similar problems.

I was trying to run some ant scripts yesterday that interact with an FTP server to delete some files. Those damned files wouldn't get deleted. They weren't even returned from a listing command. As it turns out, I was using a particularly old version of Apache Commons-Net library (this jar file was from 2005) which had a leap-year bug. It simply would not show me files with modification dates of 2/29. I was looking at the FTP server configuration, logging in with other clients, moving and renaming files, and all about ready to break out Wireshark... and then it occurred to me that it was leap day. Hoo-fucking-ray. "touch"ed the file, and sure enough, it was suddenly available. Those are a few hours of my life I'll never get back.

Your post is not anti-Microsoft, so you must be a shill.

Re:What is it with Microsoft and Leap Year? (1)

John Hasler (414242) | more than 2 years ago | (#39210121)

> Your post is not anti-Microsoft, so you must be a shill.

It's anti-Java and therefor anti-Oracle. That makes it ok.

Re:What is it with Microsoft and Leap Year? (2)

seandiggity (992657) | more than 2 years ago | (#39210197)

As it turns out, I was using a particularly old version of Apache Commons-Net library (this jar file was from 2005) which had a leap-year bug. It simply would not show me files with modification dates of 2/29.

If this is the bug you're talking about [apache.org] , it appears a bug report was filed, discussed, and a temporary workaround was offered (perhaps more than one). Although free software has bugs just like proprietary software, the way they are reported and handled is night and day.

Re:What is it with Microsoft and Leap Year? (2)

Kozz (7764) | more than 2 years ago | (#39210427)

If this is the bug you're talking about [apache.org] , it appears a bug report was filed, discussed, and a temporary workaround was offered (perhaps more than one). Although free software has bugs just like proprietary software, the way they are reported and handled is night and day.

That appears to be the very same bug, yes. And I'm not disputing the handling of the bug, but merely pointing out that even with "many eyes", this bug existed not so very long ago. Open Source is not immune to the same kinds of problems, though I grant you I probably should have been checking for the latest compatible libraries.

To the cloud (1)

g0bshiTe (596213) | more than 2 years ago | (#39208971)

This is probably part of the reason why the cloud really hasn't taken off in the corporate sector, and it's no wonder why.

In a new press conference.. (5, Funny)

Anonymous Coward | more than 2 years ago | (#39208977)

Microsoft has told the press that they don't expect the Azure cloud service to fail again for years. In an unrelated schedule change, a down-for-maintenance slot was scheduled 4 years in advance.

Re:In a new press conference.. (1)

NatasRevol (731260) | more than 2 years ago | (#39210227)

It took the Zune slot.

office in the cloud (5, Funny)

Anonymous Coward | more than 2 years ago | (#39208997)

It's sold as Office 365 not Office 366

Re:office in the cloud (2)

GiantRobotMonster (1159813) | more than 2 years ago | (#39209219)

This behaviour is by design.

Prepared for future (3, Informative)

gmuslera (3436) | more than 2 years ago | (#39209011)

If they can't handle an exception that is around since 2k years ago, what about newer exception? Would be interesting to see what could happen next June 30.

LOL Snurk Snurk (1)

Grindalf (1089511) | more than 2 years ago | (#39209085)

Oh Man! That's so embarrassing! :0)

UNIX Epoch FTW (2)

_0x783czar (2516522) | more than 2 years ago | (#39209095)

Correct me if I'm wrong, nut they could have avoided this by relying on the UNIX epoch. Same with Y2K. But beware Y2K38 you 32-bit users!

Re:UNIX Epoch FTW (1)

gman003 (1693318) | more than 2 years ago | (#39209227)

Not necessarily. It probably wouldn't have been a complete failure, but even software using epoch time internally can have problems.

Remember, you still have to put it into Regular Time to display to users. And take input in from users - if someone schedules a task for 2011-02-29, it should fail, but if it's scheduled for 2012-02-29 it should be allowed. And maybe there's business logic to figure out whether it's a weekend and such, which could easily be thrown off during the UNIX->Gregorian conversion...

Re:UNIX Epoch FTW (0)

Anonymous Coward | more than 2 years ago | (#39209523)

But there's loads of great Open Source software to do those calculations ... oh, wait ...

Re:UNIX Epoch FTW (1)

GiantRobotMonster (1159813) | more than 2 years ago | (#39209243)

yeah that's going to be a fun year.

Re:UNIX Epoch FTW (0)

Anonymous Coward | more than 2 years ago | (#39210223)

Correct me if I'm wrong, nut they could have avoided this by relying on the UNIX [....]

Okay, see, there's your problem. At that last word, Ballmer stopped reading and just started frothing and repeatedly muttering, with increasing profanity and racial epithets each repetition, about how Microsoft is a big, grown-up company that shouldn't have to rely on anyone else's standards, ever, so all hope of solving this problem with a LOGICAL solution is in vain.

In fact, he's probably back at Redmond right now, trying to push the concept of a Microsoft(tm) LeapLess(c) DirectCalendar(r) to the shareholders.

Dumb people never learn (1)

Anonymous Coward | more than 2 years ago | (#39209109)

Never trust Microsoft for anything.

Re:Dumb people never learn (1, Insightful)

Anonymous Coward | more than 2 years ago | (#39209333)

Never trust Microsoft for anything.

Never trust any vendor for anything.

FTFY, blah blah blah....

You whipper snappers don't remeber what it was like doing business with IBM back when they ruled the World and some of the things I see about Oracle here on Slashdot makes me cringe.

Re:Dumb people never learn (4, Funny)

Tanktalus (794810) | more than 2 years ago | (#39209797)

Hey! My MS4000 keyboard and MS mouse are working jut fine.

Re:Dumb people never learn (4, Funny)

MadKeithV (102058) | more than 2 years ago | (#39209983)

Hey! My MS4000 keyboard and MS mouse are working jut fine.

I see what you did there.

Uh Oh (0)

Anonymous Coward | more than 2 years ago | (#39209117)

If we could peek into one of the container-trailers at the M$ server-farm in Oregon would we find stacks of 386-AT&T-clones running DOS 4.4 and Lotus 1-2-3 doing the calculations?

Re:Uh Oh (1)

philip.paradis (2580427) | more than 2 years ago | (#39209281)

Probably not. The folks who are still around from that era would probably be smart enough to have avoided this problem in the first place.

Everything MS does as "me too" sucks. (4, Insightful)

scorp1us (235526) | more than 2 years ago | (#39209143)

It seems that all of MS's copied products - hotmail, Azure, Zune are all done with a "me too" attitude of just having something so that they don't get left behind. They don't really try to make these "me too" products as industry leaders. But here's the catch. I know plenty of IT people who will always choose MS's offering because, as I was told "you don't get in trouble for choosing MS". And that knowledge seems to be built into MS's offerings.

Re:Everything MS does as "me too" sucks. (2)

geekoid (135745) | more than 2 years ago | (#39209293)

You 'don't get fired for buying IBM.'
Then 'You don't get fired for buying MS'
Next will be Google, probably.

Never Apple because they are a high end system in a niche market. Yea, people willing to pay 1200+ for a computer is a high end niche market.

If MS starts making excuses (1)

blind biker (1066130) | more than 2 years ago | (#39209201)

If MS starts making excuses for this mini fiasco, they will only manage to make Amazon, Google and Apple look like fucking geniuses

Only Happens Every 4 Years (5, Funny)

trongey (21550) | more than 2 years ago | (#39209235)

It's not Micorsoft's fault; they're a publicly traded company so they can't think about multi-year events. They're prohibited from considering anything that is beyond the next fiscal quarter.

Re:Only Happens Every 4 Years (1)

NatasRevol (731260) | more than 2 years ago | (#39210349)

They pay no dividend for that extra day. That they don't know about. And didn't learn about last leap year.

Inexcusable (1)

geekoid (135745) | more than 2 years ago | (#39209241)

Simply inexcusable.

Re:Inexcusable (2)

JamesP (688957) | more than 2 years ago | (#39209585)

True

Apparently MS only hires people with no concept of future.

See Zune event, see this. Absolute disregard of date concepts (and testing)

Now, Linux development worries about this THOROUGHLY (I mean, kernel and main libs, of course a sw developer can get this wrong on Linux as well)

No counter wrap-around fsck-ups, date exceptions, etc (people are watching this)

Remember the Windows bug where it would crash after 15 days or so?

Single Point of Failure (5, Insightful)

Bicx (1042846) | more than 2 years ago | (#39209251)

This points out a serious flaw in the whole idea of cloud reliability by redundancy. You may have a million servers running across multiple countries, but if the distributed software for each virtual server has a bug, every server across the globe is affected. That's a single point of failure.

Re:Single Point of Failure (4, Insightful)

Bert64 (520050) | more than 2 years ago | (#39209487)

Thats a flaw in the idea of a monoculture, true redundancy has different software implementing the same basic standards...
Like how the Internet is built from routers made by different vendors, cisco, juniper, software based linux/bsd devices etc. When new DoS vulnerabilities are found in one vendors kit it doesn`t take down the whole internet, because other vendors are immune.

Re:Single Point of Failure (1)

WilyCoder (736280) | more than 2 years ago | (#39209863)

Unless there is a bug in the "same basic standards" that the heterogeneous systems use...

Re:Single Point of Failure (1)

snowgirl (978879) | more than 2 years ago | (#39210321)

Unless there is a bug in the "same basic standards" that the heterogeneous systems use...

Ah... like the WMF exploit... I was explaining to someone at the time that the problem with the exploit was that it was functioning exactly as designed and intended. >_

Re:Single Point of Failure (1)

MetalliQaZ (539913) | more than 2 years ago | (#39209637)

That's why I'm about to launch my new "Ionosphere" product. It is a cloud that runs on top of clouds. So when Azure fails Amazon picks up the slack and so on. Trademarked/copyrighted/patent pending suckas.

-d

Re:Single Point of Failure (0)

Anonymous Coward | more than 2 years ago | (#39210019)

1. MS can't handle leap years
2. Conquer the world, banish leap years
3. Profit!

A leap year issue? Are you SERIOUS? (5, Insightful)

msobkow (48369) | more than 2 years ago | (#39209325)

Given how many DECADES leap year calculations have had to be done and how many years it's been since we fixed the Y2K issues (at great expense, I might add), it is absolutely UNACCEPTABLE for someone to blame a leap year calculation for down time.

The DIRECTOR of the service division at Microsoft should be FIRED for this failure.

Expect lawsuits from customers, Microsoft. Because this was a problem you KNEW about and should have written code to deal with.

What a pathetic excuse for planning and testing on Microsoft's part.

Re:A leap year issue? Are you SERIOUS? (0)

Anonymous Coward | more than 2 years ago | (#39209543)

Makes you wonder why they don't have the test sever environment running like 2 weeks ahead of time so if there is a date issue it fails and they have 2 weeks notice to fix it.

Re:A leap year issue? Are you SERIOUS? (1)

Xacid (560407) | more than 2 years ago | (#39209685)

Authentication issues perhaps?

Re:A leap year issue? Are you SERIOUS? (3, Funny)

Anonymous Coward | more than 2 years ago | (#39209591)

Shouldn't 'pathetic' be in uppercase?

Re:A leap year issue? Are you SERIOUS? (0)

Anonymous Coward | more than 2 years ago | (#39209629)

O KAY

WE GET IT

Microsoft - THE CULPRITS

Re:A leap year issue? Are you SERIOUS? (0)

Anonymous Coward | more than 2 years ago | (#39210107)

The director should be fired? lmao. How about firing the ones responsible, the dumbfuck developers or their dumbfuck manager who didn't care that there was no testing done for leap year? Microsoft is big man. The director has nothing to do with this.

Re:A leap year issue? Are you SERIOUS? (1)

John Hasler (414242) | more than 2 years ago | (#39210173)

> Expect lawsuits from customers...

I'm sure it's covered by the TOS. That's an area where they DONT make mistakes.

Re:A leap year issue? Are you SERIOUS? (1)

ColdWetDog (752185) | more than 2 years ago | (#39210245)

Maybe everyone should get together and file a class action suit - the lawyers will get millions, the users will get 30 seconds of their life back.

Re:A leap year issue? Are you SERIOUS? (0)

Anonymous Coward | more than 2 years ago | (#39210317)

You're acting like it's the apocalyPS3 or something :P

Hummm (0)

Anonymous Coward | more than 2 years ago | (#39209379)

I though we fixed all the clock stuff back in 2000? Guess not.

It wasn't just Microsoft... (5, Interesting)

Anonymous Coward | more than 2 years ago | (#39209447)

...they just had the most publicly catastrophic failure. I just noticed that all of the Google Chat messages I received yesterday were sent to me at various times on December 31, 1969.

And it also seems that I didn't even receive any of them until today, March 1, implying that they were incapable of even sending them yesterday.

Re:It wasn't just Microsoft... (0)

Anonymous Coward | more than 2 years ago | (#39209807)

Yeah, but the google entire google chat system didn't completely shit itself and fall over.
Is it just me, or have Microsoft products in general never handled failure gracefully?

do77 (-1)

Anonymous Coward | more than 2 years ago | (#39209473)

www.anti-slash.org ink splashes across 'doing something' wh1ch allows list tof other NetBSD user

A bad reputation for their development platform (0)

Anonymous Coward | more than 2 years ago | (#39209535)

Done right, the date/time implementation being used should have had no problems automatically adjusting to a leap year.

This is shoddy coding, pure and simple.

This does not reflect well on those developing on MS platforms.

In the year 2012, it is unthinkable for a date/time implementation to not handle this gracefully.

Did they hire an intern to code up some half baked date class?

Arthur David Olson is my hero (4, Informative)

Bruce Perens (3872) | more than 2 years ago | (#39209561)

30 years ago, Arthur David Olson started engineering a solution to this problem that persists to this day, and which he supported personally for all but the last few months. The systems I have that run his software have never even burped through legislative changes of the calendar, leap-seconds, and the Century leap-year day, which is a separate cycle from the 4-year one.

One small step for Microsoft... (0)

Anonymous Coward | more than 2 years ago | (#39209583)

...one giant leap for the rest of us...?

(edit: seriously, my captcha on this is "doomsday" :-D?=

Not a surprise... (1)

Ytsejam-03 (720340) | more than 2 years ago | (#39209641)

The story yesterday said that they were having a problem with certificate validation. The routine they were using to validate certificate expiration must not have been able to handle the leap year. I wonder what non-standard API they were using to process the expiration date. That reminds me of another article [thedailywtf.com] that I read yesterday.

All bets are off... (1)

Xacid (560407) | more than 2 years ago | (#39209661)

Bet it wont happen again next year!

who implemented and tested their date calculations (0)

Anonymous Coward | more than 2 years ago | (#39209693)

Idiots!
aren't they using any unit testing? If they are, isn't a leap year an obvious test case?

Does anyone know... (2)

roc97007 (608802) | more than 2 years ago | (#39209753)

...how Windows for cars and Windows for Warships fared during the leap year? Forget Y2K -- the apocalypse comes every four years...

WTF? (1)

UnknowingFool (672806) | more than 2 years ago | (#39209805)

While we jab at MS for the Zune fiasco, to their defense, they didn't write the subroutine that caused the problem and the most that happened was some of their customers could not play music on their Zunes for a while. Not a mission critical situation. But what the hell kind of calendar system is MS using in their mission critical software that cannot deal with leap years which comes every 4 years?

So Azure is just another front end to Excel? (0)

Anonymous Coward | more than 2 years ago | (#39209845)

I seem to remember auditors at my first job (mid 1990's) telling me about needing to account for Excel's leap year problem when they used it. I can only find this issue today :

http://en.wikipedia.org/wiki/Year_1900_problem

Re:So Azure is just another front end to Excel? (1)

VGPowerlord (621254) | more than 2 years ago | (#39210467)

Joel Spolsky has an article [joelonsoftware.com] about the 1900 Leap Year bug.

Attention Microsoft: (5, Funny)

Howard Beale (92386) | more than 2 years ago | (#39209873)

The following are leap years: 2016 2020 2024 2028 2032 2036 2040 You have been warned. After that, I'll probably be dead, so I won't care (unless Microsoft starts making pacemakers, which may end it for me...).

Re:Attention Microsoft: (3, Funny)

forkfail (228161) | more than 2 years ago | (#39210101)

The thought of an MS pacemaker EULA is pretty scary....

FAIL (0)

sproketboy (608031) | more than 2 years ago | (#39209911)

NTR

Some of the most common leap-year bugs (5, Informative)

tillerman35 (763054) | more than 2 years ago | (#39209943)

Some of the common leap year bugs that I've seen over the years:

1. A matrix with the number of days per month:
e.g. smallint dayspermonth[12]={31,28,31,30,31,30,31,31,30,31,30,31};
Indexing into the matrix for February (index 1) ignores leap years.

1. A matrix with 365 elements to represent a year's worth of something:
e.g. smallint hightemps[365];
This usually doesn't fail until Dec 31, when hightemp[mydate.dayofyear()-1] points to a non-existent element.
Of course, if dayofyear is calculated using the matrix in the prior bug, it will fail invisibly since that will be incorrect
as well.

2. Quck-n-dirty subtract one year math:
e.g. Convert date to char in YYYYDDMM format, convert char to int, subtract 10000, convert back to a char and then date.
Why people do this when you can dateadd(year,mydate,-1) is that easy, I have no clue. But it breaks horridly when
you use it to determine "one year ago today" from Feb 29.

Microsoft Never Has Been Good At Time (4, Interesting)

Greyfox (87712) | more than 2 years ago | (#39210027)

Dealing with time is hard, but it's been amusing to watch them experience problems solved by UNIX decades earlier. Daylight savings time was a constant problem for them in the early days, though they seem to have mostly got that ironed out. Every so often they seem to have a regression for a piece of new hardware. Maybe they'll eventually get it right.

Funnily enough, I used to work at IBM doing OS/2 tech support. OS/2 and Windows NT share a common heritage, so a lot of the behind-the-scenes problems I witnessed in OS/2 were (And sometimes still are) problems with Windows. I'm not sure if this is one of them, but I got a call once from a guy who was trying to use his OS/2 system to track satellites. The problem was, the OS/2 timer API specified that you could set milliseconds but it didn't seem to work. I tracked it down to a timing driver which tracked two separate interrupts. The first interrupt happened every few milliseconds and would update the clock millis when that happened. However, if the system was busy it was possible to not handle that interrupt. There was also a system periodic interrupt every 1 second. When that occurred, the system hard-reset the milli time and incremented the seconds. So you could set the millis, but the clock would become inaccurate 1 second later. Just one example of how time has been a thorn in my side for my entire career. I wrote an APAR up on it which was promptly closed "Working as Designed." Dunno if he ever got it fixed...

Typical Microsoft Spin (1)

sl4shd0rk (755837) | more than 2 years ago | (#39210271)

"Oh Hai, yeah we just carried the one! It's all fixed now. Nothing to worry about, back to work"

Time is tricky (1)

inglorion_on_the_net (1965514) | more than 2 years ago | (#39210273)

As I keep telling my fellow software developers, time is one of those things in software that tend to go wrong. Few developers give it the attention it deserves. Between different formats, timezones, changing timezones (including DST), leap seconds, and limits on what can be represented, there is plenty of opportunity for errors. And contrary to what you might hope, using an existing library to handle time does not absolve you from having to think about it, nor does that library always get it right.

Gregorian calendar hacks Microsoft (1)

aintnostranger (1811098) | more than 2 years ago | (#39210301)

This just in, the Vatican is raided by the FBI in search of XVI century documents and the evil mastermind of today's attack: Pope Gregory. Joining the FBI are Seals Team Six and Chuck Norris, who brought an abacus. The team sprays Gregory's coffin with bullets. Obama announces the permanent change to a non-leap calendar. The world is safe. Cue in Aerosmith.

No excuse (0)

Anonymous Coward | more than 2 years ago | (#39210475)

I've been accommodating leap years into my date-handling code since 1982. The computation is quite simple, but it has to be done in order to convert a julian date/time value to calendar date/time, or to do simple date arithmetic. At this point in time, there is absolutely zero, zilch, no excuse for this sort of bug to exist in ANY production-quality code. So, I guess that MS software is NOT production-ready? :rolleyes:

Load More Comments
Slashdot Account

Need an Account?

Forgot your password?

Don't worry, we never post anything without your permission.

Submission Text Formatting Tips

We support a small subset of HTML, namely these tags:

  • b
  • i
  • p
  • br
  • a
  • ol
  • ul
  • li
  • dl
  • dt
  • dd
  • em
  • strong
  • tt
  • blockquote
  • div
  • quote
  • ecode

"ecode" can be used for code snippets, for example:

<ecode>    while(1) { do_something(); } </ecode>
Create a Slashdot Account

Loading...