]> jfr.im git - irc.git/blob - software/!RELEASES/ircservices/achurch.org/services/lists/ircservices/2000/000402.html
RELEASE -> !RELEASE
[irc.git] / software / !RELEASES / ircservices / achurch.org / services / lists / ircservices / 2000 / 000402.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
2 <HTML>
3 <HEAD>
4 <TITLE> [IRCServices] Re: DALnet-src: Y2K bug in the ircd (dreamforge and below)
5 </TITLE>
6 <LINK REL="Index" HREF="index.html" >
7 <LINK REL="made" HREF="mailto:ircservices%40ircservices.za.net?Subject=%5BIRCServices%5D%20Re%3A%20DALnet-src%3A%20Y2K%20bug%20in%20the%20ircd%20%28dreamforge%20and%20below%29&In-Reply-To=">
8 <META NAME="robots" CONTENT="index,nofollow">
9 <META http-equiv="Content-Type" content="text/html; charset=us-ascii">
10 <LINK REL="Previous" HREF="000401.html">
11 <LINK REL="Next" HREF="000405.html">
12 </HEAD>
13 <BODY BGCOLOR="#ffffff">
14 <H1>[IRCServices] Re: DALnet-src: Y2K bug in the ircd (dreamforge and below)</H1>
15 <B>Andrew Church</B>
16 <A HREF="mailto:ircservices%40ircservices.za.net?Subject=%5BIRCServices%5D%20Re%3A%20DALnet-src%3A%20Y2K%20bug%20in%20the%20ircd%20%28dreamforge%20and%20below%29&In-Reply-To="
17 TITLE="[IRCServices] Re: DALnet-src: Y2K bug in the ircd (dreamforge and below)">achurch at dragonfire.net
18 </A><BR>
19 <I>Mon Jan 3 11:24:21 PST 2000</I>
20 <P><UL>
21 <LI>Previous message: <A HREF="000401.html">[IRCServices] DreamForge 4.6.7
22 </A></li>
23 <LI>Next message: <A HREF="000405.html">[IRCServices] DreamForge 4.6.7
24 </A></li>
25 <LI> <B>Messages sorted by:</B>
26 <a href="date.html#402">[ date ]</a>
27 <a href="thread.html#402">[ thread ]</a>
28 <a href="subject.html#402">[ subject ]</a>
29 <a href="author.html#402">[ author ]</a>
30 </LI>
31 </UL>
32 <HR>
33 <!--beginarticle-->
34 <PRE>&gt;&gt;<i> Well my bug is in the date() function (s_misc.c), where the reply string
35 </I>&gt;&gt;<i> is generated:
36 </I>&gt;&gt;<i>
37 </I>&gt;&gt;<i> (void)sprintf(buf, &quot;%s %s %d 19%02d -- %02d:%02d %c%02d:%02d&quot;,
38 </I>&gt;&gt;<i> weekdays[lt-&gt;tm_wday], months[lt-&gt;tm_mon],lt-&gt;tm_mday,
39 </I>&gt;&gt;<i> lt-&gt;tm_year, lt-&gt;tm_hour, lt-&gt;tm_min,
40 </I>&gt;&gt;<i> plus, minswest/60, minswest%60);
41 </I>&gt;&gt;<i>
42 </I>&gt;&gt;<i> The &quot;19&quot;, for the centuary, is hardcoded.
43 </I>
44 &lt;rant&gt;
45 Is it just me, or is this so completely braindead it's not even funny?
46 Even assuming this is left over from the original ircd, that's still
47 post-1990 code, and it would have taken some major guts (or stupidity) to
48 assume that that code would no longer be in use by 2000. It doesn't even
49 take any extra effort to write &quot;%04d&quot; and &quot;lt-&gt;tm_year+1900&quot; instead.
50
51 _This_ is why programming should be left to experts.
52 &lt;/rant&gt;
53
54 --Andrew Church
55 <A HREF="http://www.ircservices.za.net/mailman/listinfo/ircservices">achurch at dragonfire.net</A>
56 <A HREF="http://achurch.dragonfire.net/">http://achurch.dragonfire.net/</A>
57 ---------------------------------------------------------------
58 To unsubscribe, send email to <A HREF="http://www.ircservices.za.net/mailman/listinfo/ircservices">majordomo at ender.shadowfire.org</A>
59 with &quot;unsubscribe ircservices&quot; in the body, without the quotes.
60
61 </PRE>
62
63 <!--endarticle-->
64 <HR>
65 <P><UL>
66 <!--threads-->
67 <LI>Previous message: <A HREF="000401.html">[IRCServices] DreamForge 4.6.7
68 </A></li>
69 <LI>Next message: <A HREF="000405.html">[IRCServices] DreamForge 4.6.7
70 </A></li>
71 <LI> <B>Messages sorted by:</B>
72 <a href="date.html#402">[ date ]</a>
73 <a href="thread.html#402">[ thread ]</a>
74 <a href="subject.html#402">[ subject ]</a>
75 <a href="author.html#402">[ author ]</a>
76 </LI>
77 </UL>
78
79 </body></html>