Hi, First sorry to bother, second thank you for providing source code worthy of a good shake down, third, arghhh, using negative years I found the return value to be off.
Using "%V/%u/%010G", which was the flag and field we matched, and creating a struct of Jan 1 dates, the return value differed. The output to buffers where identical, yours reported a different length. I haven't tried other than "%G" as a test from +- 2^29 of every first of the year took a while. This is very trivial, I know, but use info if you want. And curse me too if need be. Steve