Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2008-12

Warning strftime format

1 message · 1 person ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

ik

Hi,

I had a very small and nasty bug that I discovered today.

I use strftime to format a date, and I accidentally used the %g option rather then %y.
The difference is that %g is returning the year of the week (2009 this week), while %y return the year of today (2008).

So I wanted to warn everyone, so if you made the same mistake, you could find it easily enough.

Ido

http://ik.homelinux.org/