aboutsummaryrefslogtreecommitdiffstats
path: root/pbx
diff options
context:
space:
mode:
authormarkster <markster@f38db490-d61c-443f-a65b-d21fe96a405b>2006-02-23 04:38:38 +0000
committermarkster <markster@f38db490-d61c-443f-a65b-d21fe96a405b>2006-02-23 04:38:38 +0000
commitefb2e34d2948dbc76d3be4a3a8805f7baba44bcc (patch)
tree3d2469d4b90405e234aaf1c5354e1ec6130e48fc /pbx
parent12c605e61bc024fefed91b0ae6f8b71555ebeb60 (diff)
Fix a few compile warnings (turned errors) and disable -Werror on the
normal build. If people want this they can turn it on, and don't anyone turn it on by default until you fix building on GCC 4.x git-svn-id: http://svn.digium.com/svn/asterisk/trunk@10842 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'pbx')
-rw-r--r--pbx/pbx_dundi.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/pbx/pbx_dundi.c b/pbx/pbx_dundi.c
index 1bafab2d6..9d842c69b 100644
--- a/pbx/pbx_dundi.c
+++ b/pbx/pbx_dundi.c
@@ -1132,10 +1132,12 @@ static int cache_lookup_internal(time_t now, struct dundi_request *req, char *ke
int expiration;
char fs[256];
time_t timeout;
+ unsigned int x;
/* Build request string */
if (!ast_db_get("dundi/cache", key, data, sizeof(data))) {
ptr = data;
- if (sscanf(ptr, "%d|%n", (int *)&timeout, &length) == 1) {
+ if (sscanf(ptr, "%d|%n", (int *)&x, &length) == 1) {
+ timeout = x;
expiration = timeout - now;
if (expiration > 0) {
ast_log(LOG_DEBUG, "Found cache expiring in %d seconds!\n", (int)(timeout - now));
@@ -2028,9 +2030,11 @@ static void load_password(void)
char *last=NULL;
char tmp[256];
time_t expired;
+ unsigned int x;
ast_db_get(secretpath, "secretexpiry", tmp, sizeof(tmp));
- if (sscanf(tmp, "%d", (int *)&expired) == 1) {
+ if (sscanf(tmp, "%d", (int *)&x) == 1) {
+ expired = x;
ast_db_get(secretpath, "secret", tmp, sizeof(tmp));
current = strchr(tmp, ';');
if (!current)