diff options
author | geniusdex geniusdex@31f1291d-b8d6-0310-a050-a5561fc1590b <geniusdex geniusdex@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864> | 2005-03-21 21:02:03 +0000 |
---|---|---|
committer | geniusdex geniusdex@31f1291d-b8d6-0310-a050-a5561fc1590b <geniusdex geniusdex@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864> | 2005-03-21 21:02:03 +0000 |
commit | 250c3f8ab193f3cc90290b81a54f80c516da7225 (patch) | |
tree | 677ed69db8d69ce0ddd6b875c43893baa11eb62f | |
parent | a53f209c7ff5935426b7fc50815a32efaba5a530 (diff) |
BUILD : 1.7.8 (636) BUGS : NOTES : When the topic was fully identical to the topiclocked one it still was being re-set, fixed that
git-svn-id: svn://svn.anope.org/anope/trunk@636 31f1291d-b8d6-0310-a050-a5561fc1590b
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@484 5417fbe8-f217-4b02-8779-1006273d7864
-rw-r--r-- | Changes | 3 | ||||
-rw-r--r-- | src/channels.c | 10 | ||||
-rw-r--r-- | version.log | 6 |
3 files changed, 18 insertions, 1 deletions
@@ -56,6 +56,9 @@ Provided by DrStein <drstein@anope.org> - 2005 03/14 F Updated docs/FAQ. [#312] 03/09 F Updated Spanish language file (es.l). [ #00] +Provided by Scott 'Simba' Garron <simba@pridelands.org> - 2005 +03/21 F Identical topics still being re-set if TOPICLOCK on. [ #00] + Provided by Ricardo <ricardoltdb@gmail.com> - 2005 03/08 F Updated Portuguese language file. [ #00] diff --git a/src/channels.c b/src/channels.c index bd1a5e913..14cb6a396 100644 --- a/src/channels.c +++ b/src/channels.c @@ -1115,6 +1115,7 @@ void do_cmode(const char *source, int ac, char **av) void do_topic(const char *source, int ac, char **av) { Channel *c = findchan(av[0]); + ChannelInfo *ci; int ts; time_t topic_time; @@ -1140,6 +1141,15 @@ void do_topic(const char *source, int ac, char **av) /* We can be sure that the topic will be in sync here -GD */ c->topic_sync = 1; + /* If the current topic we have matches the last known topic for this + * channel exactly, there's no need to update anything and we can as + * well just return silently without updating anything. -GD + */ + if ((ac > 3) && *av[3] && (ci = c->ci) && ci->last_topic + && (strcmp(av[3], ci->last_topic) == 0) + && (strcmp(av[1], ci->last_topic_setter) == 0)) + return; + if (check_topiclock(c, topic_time)) return; diff --git a/version.log b/version.log index 8c476a457..dc3a7c8af 100644 --- a/version.log +++ b/version.log @@ -8,10 +8,14 @@ VERSION_MAJOR="1" VERSION_MINOR="7" VERSION_PATCH="8" -VERSION_BUILD="635" +VERSION_BUILD="636" # $Log$ # +# BUILD : 1.7.8 (636) +# BUGS : +# NOTES : When the topic was fully identical to the topiclocked one it still was being re-set, fixed that +# # BUILD : 1.7.8 (635) # BUGS : # NOTES : Topics should be only updated when really needed during bursts now (on IRCDs that support it) |