]> jfr.im git - irc/quakenet/snircd-patchqueue.git/commitdiff
welcome: dont allow timestamp to be 0
authorwiebe <redacted>
Tue, 6 Apr 2010 12:32:08 +0000 (14:32 +0200)
committerwiebe <redacted>
Tue, 6 Apr 2010 12:32:08 +0000 (14:32 +0200)
welcome.patch

index 40b3f74df29545bf684b6f9bc9ca2d63bb126fa1..094222c727d4f45c94b7fa4dac697e23fb545a0b 100644 (file)
@@ -771,7 +771,7 @@ diff -r a9b437e961ec ircd/s_user.c
 diff -r a9b437e961ec ircd/welcome.c
 --- /dev/null
 +++ b/ircd/welcome.c
-@@ -0,0 +1,592 @@
+@@ -0,0 +1,596 @@
 +/*
 + * IRC - Internet Relay Chat, ircd/welcome.c
 + * Copyright (C) 1990 Jarkko Oikarinen and
@@ -1109,6 +1109,10 @@ diff -r a9b437e961ec ircd/welcome.c
 +  Debug((DEBUG_DEBUG, "welcome_do(\"%s\", \"%s\", \"%s\", %Tu, \"%s\", \"%s\", 0x%04x)",
 +   cli_name(cptr), cli_name(sptr), name, timestamp, who, text, flags));
 +
++  /* if for some reason timestamp is 0, increase it */
++  if (timestamp == 0)
++    timestamp++;
++
 +  /* name empty after taking off the prefixes? */
 +  if (EmptyString(name)) {
 +    if (IsUser(sptr))