From abd3e4040bd76058d0148884879858894258fb9f Mon Sep 17 00:00:00 2001 From: Kinsey Moore Date: Fri, 9 May 2014 22:49:26 +0000 Subject: 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 ........ Merged revisions 413587 from http://svn.asterisk.org/svn/asterisk/branches/11 ........ Merged revisions 413588 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@413589 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- main/translate.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'main/translate.c') diff --git a/main/translate.c b/main/translate.c index df2754d11..c24700b45 100644 --- a/main/translate.c +++ b/main/translate.c @@ -533,7 +533,7 @@ struct ast_frame *ast_translate(struct ast_trans_pvt *path, struct ast_frame *f, frame. */ path->nextout = ast_tvadd(path->nextout, ast_samp2tv(out->samples, ast_format_rate(&out->subclass.format))); if (f->samples != out->samples && ast_test_flag(out, AST_FRFLAG_HAS_TIMING_INFO)) { - ast_debug(4, "Sample size different %u vs %u\n", f->samples, out->samples); + ast_debug(4, "Sample size different %d vs %d\n", f->samples, out->samples); ast_clear_flag(out, AST_FRFLAG_HAS_TIMING_INFO); } } else { @@ -770,7 +770,7 @@ static void matrix_rebuild(int samples) matrix_get(x, z)->table_cost = newtablecost; matrix_get(x, z)->multistep = 1; changed++; - ast_debug(10, "Discovered %d cost path from %s to %s, via %s\n", + ast_debug(10, "Discovered %u cost path from %s to %s, via %s\n", matrix_get(x, z)->table_cost, ast_getformatname(ast_format_set(&tmpx, index2format(x), 0)), ast_getformatname(ast_format_set(&tmpy, index2format(z), 0)), @@ -910,7 +910,7 @@ static char *handle_show_translation_table(struct ast_cli_args *a) if (x >= 0 && y >= 0 && matrix_get(x, y)->step) { /* Actual codec output */ - ast_str_append(&out, 0, "%*d", curlen + 1, (matrix_get(x, y)->table_cost/100)); + ast_str_append(&out, 0, "%*u", curlen + 1, (matrix_get(x, y)->table_cost/100)); } else if (i == -1 && k >= 0) { /* Top row - use a dynamic size */ ast_str_append(&out, 0, "%*s", curlen + 1, ast_getformatname(&f_list[k].format)); -- cgit v1.2.3