mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-19 00:00:09 +00:00
Allow Asterisk to compile under GCC 4.10
This resolves a large number of compiler warnings from GCC 4.10 which cause the build to fail under dev mode. The vast majority are signed/unsigned mismatches in printf-style format strings. ........ Merged revisions 413586 from http://svn.asterisk.org/svn/asterisk/branches/1.8 git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/11@413587 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -808,7 +808,7 @@ static void linear_release(struct ast_channel *chan, void *params)
|
||||
struct linear_state *ls = params;
|
||||
|
||||
if (ls->origwfmt.id && ast_set_write_format(chan, &ls->origwfmt)) {
|
||||
ast_log(LOG_WARNING, "Unable to restore channel '%s' to format '%d'\n", ast_channel_name(chan), ls->origwfmt.id);
|
||||
ast_log(LOG_WARNING, "Unable to restore channel '%s' to format '%u'\n", ast_channel_name(chan), ls->origwfmt.id);
|
||||
}
|
||||
|
||||
if (ls->autoclose) {
|
||||
@@ -1723,7 +1723,7 @@ static enum AST_LOCK_RESULT ast_lock_path_lockfile(const char *path)
|
||||
s = ast_alloca(lp + 10);
|
||||
fs = ast_alloca(lp + 20);
|
||||
|
||||
snprintf(fs, strlen(path) + 19, "%s/.lock-%08lx", path, ast_random());
|
||||
snprintf(fs, strlen(path) + 19, "%s/.lock-%08lx", path, (unsigned long)ast_random());
|
||||
fd = open(fs, O_WRONLY | O_CREAT | O_EXCL, AST_FILE_MODE);
|
||||
if (fd < 0) {
|
||||
ast_log(LOG_ERROR, "Unable to create lock file '%s': %s\n", path, strerror(errno));
|
||||
@@ -2101,7 +2101,7 @@ static int ivr_dispatch(struct ast_channel *chan, struct ast_ivr_option *option,
|
||||
ast_stopstream(chan);
|
||||
return res;
|
||||
default:
|
||||
ast_log(LOG_NOTICE, "Unknown dispatch function %d, ignoring!\n", option->action);
|
||||
ast_log(LOG_NOTICE, "Unknown dispatch function %u, ignoring!\n", option->action);
|
||||
return 0;
|
||||
}
|
||||
return -1;
|
||||
|
||||
Reference in New Issue
Block a user