mirror of
https://github.com/anope/anope.git
synced 2026-07-03 22:03:14 +02:00
BUILD : 1.7.6 (513) BUGS : NOTES : Added warnings for NULL-args with sstrdup, and NULL modname with module*Data functions. Fixed Catserv to use moduleAddCommand instead of addCommand.
git-svn-id: svn://svn.anope.org/anope/trunk@513 31f1291d-b8d6-0310-a050-a5561fc1590b git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@367 5417fbe8-f217-4b02-8779-1006273d7864
This commit is contained in:
parent
2be6713785
commit
ae0f3c487d
@@ -1,6 +1,7 @@
|
||||
Anope Version S V N
|
||||
-------------------
|
||||
Provided by Anope Dev. <dev@anope.org> - 2004
|
||||
12/30 A Warnings for NULL values with sstrdup/moduleData. [ #00]
|
||||
12/26 A Services can enforce SGLINE and SQLINE by killing the user on set [#245]
|
||||
12/25 A Flag to tell if we need to enforce SGlines or not [ #00]
|
||||
12/02 A Support for other Ulines Servers (NeoStats/SolarStats). [ #00]
|
||||
@@ -15,6 +16,7 @@ Provided by Anope Dev. <dev@anope.org> - 2004
|
||||
11/19 A Added anope_cmd_ctcp() to code API, for sending CTCP messages. [ #00]
|
||||
11/18 A Unable to use registered nicknames as bot nicks from now on. [ #00]
|
||||
11/18 A NSAddAccessOnReg to control access list on registration. [ #00]
|
||||
12/30 F Catserv now uses moduleAddCommand instead of addCommand. [ #00]
|
||||
12/27 F Not freeing memory when a channel got deleted. [ #00]
|
||||
12/27 F Segfaults with enforcing KillonSGline/KillonSQline. [#260]
|
||||
12/26 F Updated IRCD doc to show all the flags currently in the code. [ #00]
|
||||
|
||||
+1
-1
@@ -613,7 +613,7 @@ E time_t start_time;
|
||||
|
||||
E void save_databases(void);
|
||||
E void expire_all(void);
|
||||
E void do_backtrace(void);
|
||||
E void do_backtrace(int show_segheader);
|
||||
E void sighandler(int signum);
|
||||
|
||||
/**** memory.c ****/
|
||||
|
||||
+6
-4
@@ -407,7 +407,7 @@ void sighandler(int signum)
|
||||
}
|
||||
|
||||
if (signum == SIGSEGV) {
|
||||
do_backtrace();
|
||||
do_backtrace(1);
|
||||
}
|
||||
|
||||
if (started) {
|
||||
@@ -578,7 +578,7 @@ int main(int ac, char **av, char **envp)
|
||||
|
||||
/*************************************************************************/
|
||||
|
||||
void do_backtrace(void)
|
||||
void do_backtrace(int show_segheader)
|
||||
{
|
||||
#ifdef HAVE_BACKTRACE
|
||||
void *array[50];
|
||||
@@ -586,8 +586,10 @@ void do_backtrace(void)
|
||||
char **strings;
|
||||
int i;
|
||||
|
||||
alog("Backtrace: Segmentation fault detected");
|
||||
alog("Backtrace: report the following lines");
|
||||
if (show_segheader) {
|
||||
alog("Backtrace: Segmentation fault detected");
|
||||
alog("Backtrace: report the following lines");
|
||||
}
|
||||
alog("Backtrace: Anope version %s %s %s", version_number,
|
||||
version_build, version_flags);
|
||||
size = backtrace(array, 10);
|
||||
|
||||
@@ -120,6 +120,10 @@ char *sstrdup(const char *src)
|
||||
#else
|
||||
abort();
|
||||
#endif
|
||||
} else {
|
||||
alog("sstrdup() called with NULL-arg");
|
||||
if (debug)
|
||||
do_backtrace(0);
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
||||
@@ -1823,6 +1823,12 @@ int moduleAddData(ModuleData ** md, char *key, char *value)
|
||||
alog("A module tried to use ModuleAddData() with one ore more NULL arguments... returning");
|
||||
return MOD_ERR_PARAMS;
|
||||
}
|
||||
|
||||
if (mod_current_module_name == NULL) {
|
||||
alog("moduleAddData() called with mod_current_module_name being NULL");
|
||||
if (debug)
|
||||
do_backtrace(0);
|
||||
}
|
||||
|
||||
moduleDelData(md, key); /* Remove any existing module data for this module with the same key */
|
||||
|
||||
@@ -1862,6 +1868,12 @@ char *moduleGetData(ModuleData ** md, char *key)
|
||||
char *mod_name = sstrdup(mod_current_module_name);
|
||||
ModuleData *current = *md;
|
||||
|
||||
if (mod_current_module_name == NULL) {
|
||||
alog("moduleGetData() called with mod_current_module_name being NULL");
|
||||
if (debug)
|
||||
do_backtrace(0);
|
||||
}
|
||||
|
||||
if (debug) {
|
||||
alog("debug: moduleGetData %p : key %s", (void *) md, key);
|
||||
alog("debug: Current Module %s", mod_name);
|
||||
@@ -1891,6 +1903,12 @@ void moduleDelData(ModuleData ** md, char *key)
|
||||
ModuleData *prev = NULL;
|
||||
ModuleData *next = NULL;
|
||||
|
||||
if (mod_current_module_name == NULL) {
|
||||
alog("moduleDelData() called with mod_current_module_name being NULL");
|
||||
if (debug)
|
||||
do_backtrace(0);
|
||||
}
|
||||
|
||||
if (key) {
|
||||
while (current) {
|
||||
next = current->next;
|
||||
@@ -1927,6 +1945,12 @@ void moduleDelAllData(ModuleData ** md)
|
||||
ModuleData *prev = NULL;
|
||||
ModuleData *next = NULL;
|
||||
|
||||
if (mod_current_module_name == NULL) {
|
||||
alog("moduleDelAllData() called with mod_current_module_name being NULL");
|
||||
if (debug)
|
||||
do_backtrace(0);
|
||||
}
|
||||
|
||||
while (current) {
|
||||
next = current->next;
|
||||
if ((stricmp(current->moduleName, mod_name) == 0)) {
|
||||
|
||||
@@ -95,9 +95,9 @@ void addMessageList(void)
|
||||
{
|
||||
Command *c;
|
||||
c = createCommand("meow", do_meow, NULL, -1, -1, -1, -1, -1);
|
||||
addCommand(Catserv_cmdTable, c, MOD_UNIQUE);
|
||||
moduleAddCommand(Catserv_cmdTable, c, MOD_UNIQUE);
|
||||
c = createCommand("purr", do_purr, NULL, -1, -1, -1, -1, -1);
|
||||
addCommand(Catserv_cmdTable, c, MOD_UNIQUE);
|
||||
moduleAddCommand(Catserv_cmdTable, c, MOD_UNIQUE);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
||||
+5
-1
@@ -8,10 +8,14 @@
|
||||
VERSION_MAJOR="1"
|
||||
VERSION_MINOR="7"
|
||||
VERSION_PATCH="6"
|
||||
VERSION_BUILD="512"
|
||||
VERSION_BUILD="513"
|
||||
|
||||
# $Log$
|
||||
#
|
||||
# BUILD : 1.7.6 (513)
|
||||
# BUGS :
|
||||
# NOTES : Added warnings for NULL-args with sstrdup, and NULL modname with module*Data functions. Fixed Catserv to use moduleAddCommand instead of addCommand.
|
||||
#
|
||||
# BUILD : 1.7.6 (512)
|
||||
# BUGS :
|
||||
# NOTES : Indenting src/modules.c correctly.... it got skipped somehow...
|
||||
|
||||
Reference in New Issue
Block a user