I've written my own calendar generation software that's pretty reliable. I can send you the text file I generate that contains all historical dates if that's helpful? Something else to be aware of is that there are half days that occur near thanksgiving and Christmas where the exchange closes at 1:00pm. These are documented on the NYSE and Nasdaq websites.