Am 09. May, 2005 schwätzte Gerald Thurman so:
> > I found this article surfing this morning and I'm interested on PLUGs
> > feedback.
> >
> Here is an old C program that demonstrates the problem.
> http://shell.deru.com/~gdt/c/code/Y2.038K.c
>
> Although not a Unix system problem, I was using the 'cal' command
> to test for leap years, but it doesn't handle 5-digit years.
> http://shell.deru.com/~gdt/shell/code/ly.txt
>
> Since it is FLOSS, I looked at cal.c to see what would be involved
> in changing it to work beyond year 9999, but the modification is
> non-trivial for me to design, implement, and test.
Looks like someone fixed it.
lufthans@LuftHans:~$ cal 12 9999
Dezember 9999
So Mo Di Mi Do Fr Sa
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
lufthans@LuftHans:~$ cal 1 10000
Januar 10000
So Mo Di Mi Do Fr Sa
1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31
lufthans@LuftHans:~$ cal 2 10000
Februar 10000
So Mo Di Mi Do Fr Sa
1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29
lufthans@LuftHans:~$ cal 2 10100
Februar 10100
So Mo Di Mi Do Fr Sa
1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28
lufthans@LuftHans:~$ cal 12 99999
Dezember 99999
So Mo Di Mi Do Fr Sa
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
lufthans@LuftHans:~$ cal 1 100000
Januar 100000
So Mo Di Mi Do Fr Sa
1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31
Reemphesizes the point that applications are responsible for doing the
right thing.
ciao,
der.hans
--
# https://www.LuftHans.com/ http://www.AZOTO.org/
# Wer bereit ist, grundlegende Freiheiten aufzugeben, um sich
# kurzfristige Sicherheit zu verschaffen, der hat weder Freiheit
# noch Sicherheit verdient. -- Benjamin Franklin (1706 - 1790)
---------------------------------------------------
PLUG-discuss mailing list - PLUG-discuss@lists.plug.phoenix.az.us
To subscribe, unsubscribe, or to change you mail settings:
http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss