summaryrefslogtreecommitdiff
path: root/res
diff options
context:
space:
mode:
authorSean Bright <sean@malleable.com>2010-01-11 16:41:44 +0000
committerSean Bright <sean@malleable.com>2010-01-11 16:41:44 +0000
commitea47ab7ed9044793204419072f2eb32da366cf22 (patch)
tree90afc2b66dac5a6c03a8bf4b83d365701da24602 /res
parentba6201cae604be1fc5eb270784ffd21a7aa45d07 (diff)
Pass NULL for the ao2_callback function pointer instead of duplicating cb_true.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@239114 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'res')
-rw-r--r--res/res_calendar_caldav.c7
-rw-r--r--res/res_calendar_exchange.c7
-rw-r--r--res/res_calendar_icalendar.c7
-rw-r--r--res/res_clialiases.c8
4 files changed, 4 insertions, 25 deletions
diff --git a/res/res_calendar_caldav.c b/res/res_calendar_caldav.c
index d1dcbeb4b..d23f9a65a 100644
--- a/res/res_calendar_caldav.c
+++ b/res/res_calendar_caldav.c
@@ -68,11 +68,6 @@ struct caldav_pvt {
struct ao2_container *events;
};
-static int cb_true(void *user_data, void *arg, int flags)
-{
- return CMP_MATCH;
-}
-
static void caldav_destructor(void *obj)
{
struct caldav_pvt *pvt = obj;
@@ -83,7 +78,7 @@ static void caldav_destructor(void *obj)
}
ast_string_field_free_memory(pvt);
- ao2_callback(pvt->events, OBJ_UNLINK | OBJ_NODATA | OBJ_MULTIPLE, cb_true, NULL);
+ ao2_callback(pvt->events, OBJ_UNLINK | OBJ_NODATA | OBJ_MULTIPLE, NULL, NULL);
ao2_ref(pvt->events, -1);
}
diff --git a/res/res_calendar_exchange.c b/res/res_calendar_exchange.c
index 05a42633a..4722e6e88 100644
--- a/res/res_calendar_exchange.c
+++ b/res/res_calendar_exchange.c
@@ -212,11 +212,6 @@ static int parse_cdata(void *data, char *value, size_t len)
return IKS_OK;
}
-static int cb_true(void *user_data, void *arg, int flags)
-{
- return CMP_MATCH;
-}
-
static void exchangecal_destructor(void *obj)
{
struct exchangecal_pvt *pvt = obj;
@@ -227,7 +222,7 @@ static void exchangecal_destructor(void *obj)
}
ast_string_field_free_memory(pvt);
- ao2_callback(pvt->events, OBJ_UNLINK | OBJ_NODATA | OBJ_MULTIPLE, cb_true, NULL);
+ ao2_callback(pvt->events, OBJ_UNLINK | OBJ_NODATA | OBJ_MULTIPLE, NULL, NULL);
ao2_ref(pvt->events, -1);
}
diff --git a/res/res_calendar_icalendar.c b/res/res_calendar_icalendar.c
index 7e7fa8033..08ef8f519 100644
--- a/res/res_calendar_icalendar.c
+++ b/res/res_calendar_icalendar.c
@@ -64,11 +64,6 @@ struct icalendar_pvt {
struct ao2_container *events;
};
-static int cb_true(void *user_data, void *arg, int flags)
-{
- return CMP_MATCH;
-}
-
static void icalendar_destructor(void *obj)
{
struct icalendar_pvt *pvt = obj;
@@ -82,7 +77,7 @@ static void icalendar_destructor(void *obj)
}
ast_string_field_free_memory(pvt);
- ao2_callback(pvt->events, OBJ_UNLINK | OBJ_NODATA | OBJ_MULTIPLE, cb_true, NULL);
+ ao2_callback(pvt->events, OBJ_UNLINK | OBJ_NODATA | OBJ_MULTIPLE, NULL, NULL);
ao2_ref(pvt->events, -1);
}
diff --git a/res/res_clialiases.c b/res/res_clialiases.c
index 853735ba3..14d064a1a 100644
--- a/res/res_clialiases.c
+++ b/res/res_clialiases.c
@@ -168,12 +168,6 @@ static struct ast_cli_entry cli_alias[] = {
AST_CLI_DEFINE(alias_show, "Show CLI command aliases"),
};
-/*! \brief Function called to to see if an alias is marked for destruction, they always are! */
-static int alias_marked(void *obj, void *arg, int flags)
-{
- return CMP_MATCH;
-}
-
/*! \brief Function called to load or reload the configuration file */
static void load_config(int reload)
{
@@ -191,7 +185,7 @@ static void load_config(int reload)
/* Destroy any existing CLI aliases */
if (reload) {
- ao2_callback(cli_aliases, OBJ_UNLINK | OBJ_NODATA | OBJ_MULTIPLE , alias_marked, NULL);
+ ao2_callback(cli_aliases, OBJ_UNLINK | OBJ_NODATA | OBJ_MULTIPLE, NULL, NULL);
}
for (v = ast_variable_browse(cfg, "general"); v; v = v->next) {