mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-03 19:28:53 +00:00
core: Remove additional symbols.
Remove symbols that are depreacated and replaced: * ast_channel_datastore_alloc * ast_channel_datastore_free * ast_channel_cmpwhentohangup * ast_channel_setwhentohangup * config_text_file_save * devstate2str * ast_device_state_changed * ast_device_state_changed_literal * ast_verbose_get_by_module Remove unused symbols: * channelreloadreason2txt (last used in Asterisk 12). Remove unused ast_options flags: * AST_OPT_FLAG_END_CDR_BEFORE_H_EXTEN / ast_opt_end_cdr_before_h_exten * AST_OPT_FLAG_VERBOSE_MODULE / ast_opt_verb_module * AST_OPT_FLAG_INITIATED_SECONDS Change-Id: I841255995d195f8efc1ed47af9c7a2f131c08645
This commit is contained in:
@@ -1144,22 +1144,6 @@ enum ama_flags {
|
||||
* take a channel argument.
|
||||
*/
|
||||
|
||||
/*!
|
||||
* \brief Create a channel data store object
|
||||
* \deprecated You should use the ast_datastore_alloc() generic function instead.
|
||||
* \version 1.6.1 deprecated
|
||||
*/
|
||||
struct ast_datastore *ast_channel_datastore_alloc(const struct ast_datastore_info *info, const char *uid)
|
||||
__attribute__((deprecated));
|
||||
|
||||
/*!
|
||||
* \brief Free a channel data store object
|
||||
* \deprecated You should use the ast_datastore_free() generic function instead.
|
||||
* \version 1.6.1 deprecated
|
||||
*/
|
||||
int ast_channel_datastore_free(struct ast_datastore *datastore)
|
||||
__attribute__((deprecated));
|
||||
|
||||
/*! \brief Inherit datastores from a parent to a child. */
|
||||
int ast_channel_datastore_inherit(struct ast_channel *from, struct ast_channel *to);
|
||||
|
||||
@@ -1708,21 +1692,6 @@ void ast_channel_set_is_t38_active_nolock(struct ast_channel *chan, int is_t38_a
|
||||
*/
|
||||
void ast_channel_softhangup_withcause_locked(struct ast_channel *chan, int causecode);
|
||||
|
||||
/*!
|
||||
* \brief Compare a offset with the settings of when to hang a channel up
|
||||
* \param chan channel on which to check for hang up
|
||||
* \param offset offset in seconds from current time
|
||||
* \return 1, 0, or -1
|
||||
* \details
|
||||
* This function compares a offset from current time with the absolute time
|
||||
* out on a channel (when to hang up). If the absolute time out on a channel
|
||||
* is earlier than current time plus the offset, it returns 1, if the two
|
||||
* time values are equal, it return 0, otherwise, it return -1.
|
||||
* \sa ast_channel_cmpwhentohangup_tv()
|
||||
* \version 1.6.1 deprecated function (only had seconds precision)
|
||||
*/
|
||||
int ast_channel_cmpwhentohangup(struct ast_channel *chan, time_t offset) __attribute__((deprecated));
|
||||
|
||||
/*!
|
||||
* \brief Compare a offset with the settings of when to hang a channel up
|
||||
* \param chan channel on which to check for hangup
|
||||
@@ -1736,23 +1705,6 @@ int ast_channel_cmpwhentohangup(struct ast_channel *chan, time_t offset) __attri
|
||||
*/
|
||||
int ast_channel_cmpwhentohangup_tv(struct ast_channel *chan, struct timeval offset);
|
||||
|
||||
/*!
|
||||
* \brief Set when to hang a channel up
|
||||
*
|
||||
* \param chan channel on which to check for hang up
|
||||
* \param offset offset in seconds relative to the current time of when to hang up
|
||||
*
|
||||
* \details
|
||||
* This function sets the absolute time out on a channel (when to hang up).
|
||||
*
|
||||
* \pre chan is locked
|
||||
*
|
||||
* \return Nothing
|
||||
* \sa ast_channel_setwhentohangup_tv()
|
||||
* \version 1.6.1 deprecated function (only had seconds precision)
|
||||
*/
|
||||
void ast_channel_setwhentohangup(struct ast_channel *chan, time_t offset) __attribute__((deprecated));
|
||||
|
||||
/*!
|
||||
* \brief Set when to hang a channel up
|
||||
*
|
||||
@@ -2736,12 +2688,6 @@ int ast_namedgroups_intersect(struct ast_namedgroups *a, struct ast_namedgroups
|
||||
/*! \brief Print named call groups and named pickup groups */
|
||||
char *ast_print_namedgroups(struct ast_str **buf, struct ast_namedgroups *groups);
|
||||
|
||||
/*!
|
||||
* \brief Convert enum channelreloadreason to text string for manager event
|
||||
* \param reason The reason for reload (manager, cli, start etc)
|
||||
*/
|
||||
const char *channelreloadreason2txt(enum channelreloadreason reason);
|
||||
|
||||
/*! \brief return an ast_variable list of channeltypes */
|
||||
struct ast_variable *ast_channeltype_list(void);
|
||||
|
||||
|
@@ -985,7 +985,6 @@ int ast_config_text_file_save2(const char *filename, const struct ast_config *cf
|
||||
* \return 0 on success or -1 on failure.
|
||||
*/
|
||||
int ast_config_text_file_save(const char *filename, const struct ast_config *cfg, const char *generator);
|
||||
int config_text_file_save(const char *filename, const struct ast_config *cfg, const char *generator) __attribute__((deprecated));
|
||||
|
||||
struct ast_config *ast_config_internal_load(const char *configfile, struct ast_config *cfg, struct ast_flags flags, const char *suggested_incl_file, const char *who_asked);
|
||||
/*!
|
||||
|
@@ -86,7 +86,6 @@ enum ast_device_state ast_state_chan2dev(enum ast_channel_state chanstate);
|
||||
*
|
||||
* \param devstate Current device state
|
||||
*/
|
||||
const char *devstate2str(enum ast_device_state devstate) attribute_pure __attribute__((deprecated));
|
||||
const char *ast_devstate2str(enum ast_device_state devstate) attribute_pure;
|
||||
|
||||
/*!
|
||||
@@ -166,41 +165,6 @@ int ast_devstate_changed(enum ast_device_state state, enum ast_devstate_cache ca
|
||||
*/
|
||||
int ast_devstate_changed_literal(enum ast_device_state state, enum ast_devstate_cache cachable, const char *device);
|
||||
|
||||
/*!
|
||||
* \brief Tells Asterisk the State for Device is changed.
|
||||
* (Accept change notification, add it to change queue.)
|
||||
*
|
||||
* \param fmt device name like a dial string with format parameters
|
||||
*
|
||||
* Asterisk polls the new extension states and calls the registered
|
||||
* callbacks for the changed extensions
|
||||
*
|
||||
* \retval 0 on success
|
||||
* \retval -1 on failure
|
||||
*
|
||||
* \note This is deprecated in favor of ast_devstate_changed()
|
||||
* \version 1.6.1 deprecated
|
||||
*/
|
||||
int ast_device_state_changed(const char *fmt, ...)
|
||||
__attribute__((deprecated,format(printf, 1, 2)));
|
||||
|
||||
/*!
|
||||
* \brief Tells Asterisk the State for Device is changed
|
||||
*
|
||||
* \param device device name like a dial string
|
||||
*
|
||||
* Asterisk polls the new extension states and calls the registered
|
||||
* callbacks for the changed extensions
|
||||
*
|
||||
* \retval 0 on success
|
||||
* \retval -1 on failure
|
||||
*
|
||||
* \note This is deprecated in favor of ast_devstate_changed_literal()
|
||||
* \version 1.6.1 deprecated
|
||||
*/
|
||||
int ast_device_state_changed_literal(const char *device)
|
||||
__attribute__((deprecated));
|
||||
|
||||
/*!
|
||||
* \brief Add device state provider
|
||||
*
|
||||
|
@@ -306,14 +306,6 @@ void ast_console_toggle_loglevel(int fd, int level, int state);
|
||||
*/
|
||||
unsigned int ast_debug_get_by_module(const char *module);
|
||||
|
||||
/*!
|
||||
* \brief Get the verbose level for a module
|
||||
* \param module the name of module
|
||||
* \return the verbose level
|
||||
* \version 11.0.0 deprecated
|
||||
*/
|
||||
unsigned int ast_verbose_get_by_module(const char *module) __attribute__((deprecated));
|
||||
|
||||
/*!
|
||||
* \brief Register a new logger level
|
||||
* \param name The name of the level to be registered
|
||||
|
@@ -74,8 +74,6 @@ enum ast_option_flags {
|
||||
AST_OPT_FLAG_TRANSMIT_SILENCE = (1 << 17),
|
||||
/*! Suppress some warnings */
|
||||
AST_OPT_FLAG_DONT_WARN = (1 << 18),
|
||||
/*! End CDRs before the 'h' extension */
|
||||
AST_OPT_FLAG_END_CDR_BEFORE_H_EXTEN = (1 << 19),
|
||||
/*! Reference Debugging */
|
||||
AST_OPT_FLAG_REF_DEBUG = (1 << 20),
|
||||
/*! Always fork, even if verbose or debug settings are non-zero */
|
||||
@@ -84,12 +82,8 @@ enum ast_option_flags {
|
||||
AST_OPT_FLAG_MUTE = (1 << 22),
|
||||
/*! There is a per-module debug setting */
|
||||
AST_OPT_FLAG_DEBUG_MODULE = (1 << 23),
|
||||
/*! There is a per-module verbose setting */
|
||||
AST_OPT_FLAG_VERBOSE_MODULE = (1 << 24),
|
||||
/*! Terminal colors should be adjusted for a light-colored background */
|
||||
AST_OPT_FLAG_LIGHT_BACKGROUND = (1 << 25),
|
||||
/*! Count Initiated seconds in CDR's */
|
||||
AST_OPT_FLAG_INITIATED_SECONDS = (1 << 26),
|
||||
/*! Force black background */
|
||||
AST_OPT_FLAG_FORCE_BLACK_BACKGROUND = (1 << 27),
|
||||
/*! Hide remote console connect messages on console */
|
||||
@@ -123,11 +117,9 @@ enum ast_option_flags {
|
||||
#define ast_opt_reconnect ast_test_flag(&ast_options, AST_OPT_FLAG_RECONNECT)
|
||||
#define ast_opt_transmit_silence ast_test_flag(&ast_options, AST_OPT_FLAG_TRANSMIT_SILENCE)
|
||||
#define ast_opt_dont_warn ast_test_flag(&ast_options, AST_OPT_FLAG_DONT_WARN)
|
||||
#define ast_opt_end_cdr_before_h_exten ast_test_flag(&ast_options, AST_OPT_FLAG_END_CDR_BEFORE_H_EXTEN)
|
||||
#define ast_opt_always_fork ast_test_flag(&ast_options, AST_OPT_FLAG_ALWAYS_FORK)
|
||||
#define ast_opt_mute ast_test_flag(&ast_options, AST_OPT_FLAG_MUTE)
|
||||
#define ast_opt_dbg_module ast_test_flag(&ast_options, AST_OPT_FLAG_DEBUG_MODULE)
|
||||
#define ast_opt_verb_module ast_test_flag(&ast_options, AST_OPT_FLAG_VERBOSE_MODULE)
|
||||
#define ast_opt_light_background ast_test_flag(&ast_options, AST_OPT_FLAG_LIGHT_BACKGROUND)
|
||||
#define ast_opt_force_black_background ast_test_flag(&ast_options, AST_OPT_FLAG_FORCE_BLACK_BACKGROUND)
|
||||
#define ast_opt_hide_connect ast_test_flag(&ast_options, AST_OPT_FLAG_HIDE_CONSOLE_CONNECT)
|
||||
|
@@ -22,11 +22,8 @@
|
||||
LINKER_SYMBOL_PREFIXio_*;
|
||||
LINKER_SYMBOL_PREFIXjb_*;
|
||||
LINKER_SYMBOL_PREFIXaes_*;
|
||||
LINKER_SYMBOL_PREFIXconfig_*;
|
||||
LINKER_SYMBOL_PREFIXtdd_*;
|
||||
LINKER_SYMBOL_PREFIXterm_*;
|
||||
LINKER_SYMBOL_PREFIXchannelreloadreason2txt;
|
||||
LINKER_SYMBOL_PREFIXdevstate2str;
|
||||
LINKER_SYMBOL_PREFIXstrsep;
|
||||
LINKER_SYMBOL_PREFIXsetenv;
|
||||
LINKER_SYMBOL_PREFIXstasis_*;
|
||||
|
@@ -520,12 +520,6 @@ void ast_channel_setwhentohangup_tv(struct ast_channel *chan, struct timeval off
|
||||
return;
|
||||
}
|
||||
|
||||
void ast_channel_setwhentohangup(struct ast_channel *chan, time_t offset)
|
||||
{
|
||||
struct timeval when = { offset, };
|
||||
ast_channel_setwhentohangup_tv(chan, when);
|
||||
}
|
||||
|
||||
/*! \brief Compare a offset with when to hangup channel */
|
||||
int ast_channel_cmpwhentohangup_tv(struct ast_channel *chan, struct timeval offset)
|
||||
{
|
||||
@@ -542,12 +536,6 @@ int ast_channel_cmpwhentohangup_tv(struct ast_channel *chan, struct timeval offs
|
||||
return ast_tvdiff_ms(whentohangup, *ast_channel_whentohangup(chan));
|
||||
}
|
||||
|
||||
int ast_channel_cmpwhentohangup(struct ast_channel *chan, time_t offset)
|
||||
{
|
||||
struct timeval when = { offset, };
|
||||
return ast_channel_cmpwhentohangup_tv(chan, when);
|
||||
}
|
||||
|
||||
/*! \brief Register a new telephony channel in Asterisk */
|
||||
int ast_channel_register(const struct ast_channel_tech *tech)
|
||||
{
|
||||
@@ -2389,16 +2377,6 @@ static void ast_dummy_channel_destructor(void *obj)
|
||||
ast_channel_internal_cleanup(chan);
|
||||
}
|
||||
|
||||
struct ast_datastore *ast_channel_datastore_alloc(const struct ast_datastore_info *info, const char *uid)
|
||||
{
|
||||
return ast_datastore_alloc(info, uid);
|
||||
}
|
||||
|
||||
int ast_channel_datastore_free(struct ast_datastore *datastore)
|
||||
{
|
||||
return ast_datastore_free(datastore);
|
||||
}
|
||||
|
||||
int ast_channel_datastore_inherit(struct ast_channel *from, struct ast_channel *to)
|
||||
{
|
||||
struct ast_datastore *datastore = NULL, *datastore2;
|
||||
@@ -8009,24 +7987,6 @@ void ast_channel_stop_silence_generator(struct ast_channel *chan, struct ast_sil
|
||||
}
|
||||
|
||||
|
||||
/*! \ brief Convert channel reloadreason (ENUM) to text string for manager event */
|
||||
const char *channelreloadreason2txt(enum channelreloadreason reason)
|
||||
{
|
||||
switch (reason) {
|
||||
case CHANNEL_MODULE_LOAD:
|
||||
return "LOAD (Channel module load)";
|
||||
|
||||
case CHANNEL_MODULE_RELOAD:
|
||||
return "RELOAD (Channel module reload)";
|
||||
|
||||
case CHANNEL_CLI_RELOAD:
|
||||
return "CLIRELOAD (Channel module reload by CLI command)";
|
||||
|
||||
default:
|
||||
return "MANAGERRELOAD (Channel module reload by manager)";
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
* Wrappers for various ast_say_*() functions that call the full version
|
||||
* of the same functions.
|
||||
|
@@ -148,11 +148,6 @@ unsigned int ast_debug_get_by_module(const char *module)
|
||||
return res;
|
||||
}
|
||||
|
||||
unsigned int ast_verbose_get_by_module(const char *module)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*! \internal
|
||||
* \brief Check if the user with 'uid' and 'gid' is allow to execute 'command',
|
||||
* if command starts with '_' then not check permissions, just permit
|
||||
|
@@ -2502,11 +2502,6 @@ static void insert_leading_blank_lines(FILE *fp, struct inclfile *fi, struct ast
|
||||
fi->lineno = lineno + 1; /* Advance the file lineno */
|
||||
}
|
||||
|
||||
int config_text_file_save(const char *configfile, const struct ast_config *cfg, const char *generator)
|
||||
{
|
||||
return ast_config_text_file_save2(configfile, cfg, generator, CONFIG_SAVE_FLAG_PRESERVE_EFFECTIVE_CONTEXT);
|
||||
}
|
||||
|
||||
int ast_config_text_file_save(const char *configfile, const struct ast_config *cfg, const char *generator)
|
||||
{
|
||||
return ast_config_text_file_save2(configfile, cfg, generator, CONFIG_SAVE_FLAG_PRESERVE_EFFECTIVE_CONTEXT);
|
||||
|
@@ -239,12 +239,6 @@ const char *ast_devstate2str(enum ast_device_state devstate)
|
||||
return devstatestring[devstate][0];
|
||||
}
|
||||
|
||||
/* Deprecated interface (not prefixed with ast_) */
|
||||
const char *devstate2str(enum ast_device_state devstate)
|
||||
{
|
||||
return devstatestring[devstate][0];
|
||||
}
|
||||
|
||||
enum ast_device_state ast_state_chan2dev(enum ast_channel_state chanstate)
|
||||
{
|
||||
int i;
|
||||
@@ -513,11 +507,6 @@ int ast_devstate_changed_literal(enum ast_device_state state, enum ast_devstate_
|
||||
return 0;
|
||||
}
|
||||
|
||||
int ast_device_state_changed_literal(const char *dev)
|
||||
{
|
||||
return ast_devstate_changed_literal(AST_DEVICE_UNKNOWN, AST_DEVSTATE_CACHABLE, dev);
|
||||
}
|
||||
|
||||
int ast_devstate_changed(enum ast_device_state state, enum ast_devstate_cache cachable, const char *fmt, ...)
|
||||
{
|
||||
char buf[AST_MAX_EXTENSION];
|
||||
@@ -530,18 +519,6 @@ int ast_devstate_changed(enum ast_device_state state, enum ast_devstate_cache ca
|
||||
return ast_devstate_changed_literal(state, cachable, buf);
|
||||
}
|
||||
|
||||
int ast_device_state_changed(const char *fmt, ...)
|
||||
{
|
||||
char buf[AST_MAX_EXTENSION];
|
||||
va_list ap;
|
||||
|
||||
va_start(ap, fmt);
|
||||
vsnprintf(buf, sizeof(buf), fmt, ap);
|
||||
va_end(ap);
|
||||
|
||||
return ast_devstate_changed_literal(AST_DEVICE_UNKNOWN, AST_DEVSTATE_CACHABLE, buf);
|
||||
}
|
||||
|
||||
/*! \brief Go through the dev state change queue and update changes in the dev state thread */
|
||||
static void *do_devstate_changes(void *data)
|
||||
{
|
||||
|
@@ -1570,20 +1570,14 @@ enum ast_option_flags {
|
||||
AST_OPT_FLAG_TRANSMIT_SILENCE = (1 << 17),
|
||||
/*! Suppress some warnings */
|
||||
AST_OPT_FLAG_DONT_WARN = (1 << 18),
|
||||
/*! End CDRs before the 'h' extension */
|
||||
AST_OPT_FLAG_END_CDR_BEFORE_H_EXTEN = (1 << 19),
|
||||
/*! Always fork, even if verbose or debug settings are non-zero */
|
||||
AST_OPT_FLAG_ALWAYS_FORK = (1 << 21),
|
||||
/*! Disable log/verbose output to remote consoles */
|
||||
AST_OPT_FLAG_MUTE = (1 << 22),
|
||||
/*! There is a per-file debug setting */
|
||||
AST_OPT_FLAG_DEBUG_FILE = (1 << 23),
|
||||
/*! There is a per-file verbose setting */
|
||||
AST_OPT_FLAG_VERBOSE_FILE = (1 << 24),
|
||||
/*! Terminal colors should be adjusted for a light-colored background */
|
||||
AST_OPT_FLAG_LIGHT_BACKGROUND = (1 << 25),
|
||||
/*! Count Initiated seconds in CDR's */
|
||||
AST_OPT_FLAG_INITIATED_SECONDS = (1 << 26),
|
||||
/*! Force black background */
|
||||
AST_OPT_FLAG_FORCE_BLACK_BACKGROUND = (1 << 27),
|
||||
};
|
||||
@@ -1616,7 +1610,6 @@ struct ast_flags ast_options = { AST_DEFAULT_OPTIONS };
|
||||
#define ast_opt_reconnect ast_test_flag(&ast_options, AST_OPT_FLAG_RECONNECT)
|
||||
#define ast_opt_transmit_silence ast_test_flag(&ast_options, AST_OPT_FLAG_TRANSMIT_SILENCE)
|
||||
#define ast_opt_dont_warn ast_test_flag(&ast_options, AST_OPT_FLAG_DONT_WARN)
|
||||
#define ast_opt_end_cdr_before_h_exten ast_test_flag(&ast_options, AST_OPT_FLAG_END_CDR_BEFORE_H_EXTEN)
|
||||
#define ast_opt_always_fork ast_test_flag(&ast_options, AST_OPT_FLAG_ALWAYS_FORK)
|
||||
#define ast_opt_mute ast_test_flag(&ast_options, AST_OPT_FLAG_MUTE)
|
||||
|
||||
|
Reference in New Issue
Block a user