From: Russell Bryant Date: Sat, 20 Mar 2010 17:33:03 +0000 (+0000) Subject: Merged revisions 253540 via svnmerge from X-Git-Tag: 1.6.2.7-rc1~31 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4f9c6020c29cf36887aba7da9c902770f9091b1b;p=thirdparty%2Fasterisk.git Merged revisions 253540 via svnmerge from https://origsvn.digium.com/svn/asterisk/trunk ........ r253540 | russell | 2010-03-20 07:03:07 -0500 (Sat, 20 Mar 2010) | 2 lines Resolve more compiler warnings on FreeBSD. ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.2@253620 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/cdr/cdr_pgsql.c b/cdr/cdr_pgsql.c index e32f6f4f83..bca0f863db 100644 --- a/cdr/cdr_pgsql.c +++ b/cdr/cdr_pgsql.c @@ -165,7 +165,7 @@ static int pgsql_log(struct ast_cdr *cdr) if (strcmp(cur->name, "start") == 0 || strcmp(cur->name, "calldate") == 0) { if (strncmp(cur->type, "int", 3) == 0) { LENGTHEN_BUF2(13); - ast_str_append(&sql2, 0, "%s%ld", first ? "" : ",", cdr->start.tv_sec); + ast_str_append(&sql2, 0, "%s%ld", first ? "" : ",", (long) cdr->start.tv_sec); } else if (strncmp(cur->type, "float", 5) == 0) { LENGTHEN_BUF2(31); ast_str_append(&sql2, 0, "%s%f", first ? "" : ",", (double)cdr->start.tv_sec + (double)cdr->start.tv_usec / 1000000.0); @@ -179,7 +179,7 @@ static int pgsql_log(struct ast_cdr *cdr) } else if (strcmp(cur->name, "answer") == 0) { if (strncmp(cur->type, "int", 3) == 0) { LENGTHEN_BUF2(13); - ast_str_append(&sql2, 0, "%s%ld", first ? "" : ",", cdr->answer.tv_sec); + ast_str_append(&sql2, 0, "%s%ld", first ? "" : ",", (long) cdr->answer.tv_sec); } else if (strncmp(cur->type, "float", 5) == 0) { LENGTHEN_BUF2(31); ast_str_append(&sql2, 0, "%s%f", first ? "" : ",", (double)cdr->answer.tv_sec + (double)cdr->answer.tv_usec / 1000000.0); @@ -193,7 +193,7 @@ static int pgsql_log(struct ast_cdr *cdr) } else if (strcmp(cur->name, "end") == 0) { if (strncmp(cur->type, "int", 3) == 0) { LENGTHEN_BUF2(13); - ast_str_append(&sql2, 0, "%s%ld", first ? "" : ",", cdr->end.tv_sec); + ast_str_append(&sql2, 0, "%s%ld", first ? "" : ",", (long) cdr->end.tv_sec); } else if (strncmp(cur->type, "float", 5) == 0) { LENGTHEN_BUF2(31); ast_str_append(&sql2, 0, "%s%f", first ? "" : ",", (double)cdr->end.tv_sec + (double)cdr->end.tv_usec / 1000000.0); diff --git a/main/features.c b/main/features.c index 29567241b2..ecfd8eaf71 100644 --- a/main/features.c +++ b/main/features.c @@ -30,6 +30,7 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$") #include "asterisk/_private.h" #include +#include #include #include #include diff --git a/main/stdtime/localtime.c b/main/stdtime/localtime.c index 925ef029b3..104ab09a34 100644 --- a/main/stdtime/localtime.c +++ b/main/stdtime/localtime.c @@ -48,6 +48,7 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$") +#include #include #include #include diff --git a/main/tcptls.c b/main/tcptls.c index d433facf5d..6c84762d5d 100644 --- a/main/tcptls.c +++ b/main/tcptls.c @@ -33,6 +33,7 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$") #include #endif +#include #include #include "asterisk/compat.h"