summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
ab90b48)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2194
e03df62e-2008-0410-955e-
edbf42e46eb7
{
if ((ts >= c->topicset) || (!*c->topic))
{
{
if ((ts >= c->topicset) || (!*c->topic))
{
+ std::string oldtopic = c->topic;
strlcpy(c->topic,topic.c_str(),MAXTOPIC);
strlcpy(c->setby,setby.c_str(),NICKMAX);
c->topicset = ts;
strlcpy(c->topic,topic.c_str(),MAXTOPIC);
strlcpy(c->setby,setby.c_str(),NICKMAX);
c->topicset = ts;
- WriteChannelWithServ((char*)source.c_str(), c, "TOPIC %s :%s", c->name, c->topic);
+ // if the topic text is the same as the current topic,
+ // dont bother to send the TOPIC command out, just silently
+ // update the set time and set nick.
+ if (oldtopic != topic)
+ WriteChannelWithServ((char*)source.c_str(), c, "TOPIC %s :%s", c->name, c->topic);