IRCForumları - IRC ve mIRC Kullanıcılarının Buluşma Noktası

IRCForumları - IRC ve mIRC Kullanıcılarının Buluşma Noktası (https://www.ircforumlari.net/)
-   Unreal IRCd (https://www.ircforumlari.net/unreal-ircd/)
-   -   adword.c problemi (https://www.ircforumlari.net/unreal-ircd/524218-adwordc-problemi.html)

Rhall 20 Şubat 2013 16:24

adword.c problemi
 
Kod:

adwords.c: In function âcb_chanmsgâ:
adwords.c:1752: error: âMODE_STRIPBADWORDSâ undeclared (first use in this function)
adwords.c:1752: error: (Each undeclared identifier is reported only once
adwords.c:1752: error: for each function it appears in.)
adwords.c: In function âcb_quitâ:
adwords.c:1783: error: âMODE_STRIPBADWORDSâ undeclared (first use in this function)
adwords.c: In function âcb_partmsgâ:
adwords.c:1884: error: âMODE_STRIPBADWORDSâ undeclared (first use in this function)

modülü kurdugum zaman bu hatayı veriyor. Bu satırları size aşağıda göstereyim ;


1747'den 1761'e kadar olan satır ;
Kod:

static char *cb_chanmsg(aClient *cptr, aClient *from, aChannel *to, char *str, int notice)
{
        ConfigItem_except        *e;

        if (!IsClient(from) || IsULine(from) || (myconf.require_mode_g
            && !(to->mode.mode & MODE_STRIPBADWORDS)))
                return str;

        for (e = conf_exceptchan; e; e = (ConfigItem_except *) e->next)
                if (!match(e->mask, to->chname))
                        return str;

        return adword_checkmsg(cptr, from, to->chname, str,
                notice? CT_NOTICE : CT_PRIVMSG, AdwordsChannel);
}


1771'den 1892'ye kadar olan satır;

Kod:

static char *cb_quit(aClient *sptr, char *comment)
{
        Membership *lp;

        if (IsULine(sptr))
                return comment;

        if (myconf.require_mode_g)
        {
                u_int strip = 0;

                for (lp = sptr->user->channel; lp; lp = lp->next)
                            if (lp->chptr->mode.mode & MODE_STRIPBADWORDS)
                        {
                                strip = 1;
                                break;
                        }

                if (!strip)
                        return comment;
        }

        return adword_checkmsg(sptr, sptr, NULL, comment,
                CT_QUIT, AdwordsQuit);
}

#ifndef HOOKTYPE_PRE_LOCAL_QUIT
/* ugly */
int override_quit(Cmdoverride *ovr, aClient *cptr, aClient *sptr, int parc, char *parv[])
{
        char *ocomment = (parc > 1 && parv[1]) ? parv[1] : parv[0];
        static char comment[TOPICLEN + 1];
        Membership *lp;

        if (!IsServer(cptr) && IsPerson(sptr))
        {
#ifdef STRIPBADWORDS
                int blocked = 0;
#endif
                char *s = comment;
                if (STATIC_QUIT)
                {
                        return exit_client(cptr, sptr, sptr, STATIC_QUIT);
                }
                if (!prefix_quit || strcmp(prefix_quit, "no"))
                        s = ircsprintf(comment, "%s ",
                                    BadPtr(prefix_quit) ? "Quit:" : prefix_quit);
#ifdef STRIPBADWORDS
                ocomment = (char *)stripbadwords_quit(ocomment, &blocked);
                if (blocked)
                        ocomment = parv[0];
#endif
                ocomment = cb_quit(sptr, ocomment);
                if (!ocomment)
                        ocomment = parv[0];
                if (!IsAnOper(sptr) && ANTI_SPAM_QUIT_MSG_TIME)
                        if (sptr->firsttime+ANTI_SPAM_QUIT_MSG_TIME > TStime())
                                ocomment = parv[0];

                /* Strip color codes if any channel is +S, use nick as reason if +c. */
                if (IsPerson(sptr) && (strchr(ocomment, '\003')))
                {
                        unsigned char filtertype = 0; /* 1=filter, 2=block, highest wins. */
                        for (lp = sptr->user->channel; lp; lp = lp->next)
                        {
                                if (lp->chptr->mode.mode & MODE_NOCOLOR)
                                {
                                        filtertype = 2;
                                        break;
                                }
                                if (lp->chptr->mode.mode & MODE_STRIP)
                                {
                                        if (!filtertype)
                                                filtertype = 1;
                                }
                        }
                        if (filtertype == 1)
                        {
                                ocomment = StripColors(ocomment);
                                if (*ocomment == '\0')
                                        ocomment = parv[0];
                        } else
                        if (filtertype == 2)
                                ocomment = parv[0];
                } /* (strip color codes) */

                strncpy(s, ocomment, TOPICLEN - (s - comment));
                comment[TOPICLEN] = '\0';
                return exit_client(cptr, sptr, sptr, comment);
        }
        else
        {
                return exit_client(cptr, sptr, sptr, ocomment);
        }
}
#endif

#ifdef HOOKTYPE_PRE_LOCAL_PART
/*
 * cb_partmsg
 * ==========
 *
 * sptr:        who is sending the message
 * chptr:        the channel where it will be sent to
 * comment:        message text
 */

static char *cb_partmsg(aClient *sptr, aChannel *chptr, char *comment)
{
        ConfigItem_except      *e;

        if (!comment)
                return NULL;
        if (IsULine(sptr) || (myconf.require_mode_g && !(chptr->mode.mode & MODE_STRIPBADWORDS)))
                return comment;

        for (e = conf_exceptchan; e; e = (ConfigItem_except *) e->next)
                if (!match(e->mask, chptr->chname))
                        return comment;

        return adword_checkmsg(sptr, sptr, chptr->chname, comment, CT_PART, AdwordsPart);
}

ne hatası veriyor tam olarak


Tüm Zamanlar GMT +3 Olarak Ayarlanmış. Şuanki Zaman: 07:28.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
Search Engine Friendly URLs by vBSEO
Copyright ©2004 - 2025 IRCForumlari.Net Sparhawk