diff options
author | Russell Bryant <russell@russellbryant.com> | 2011-05-03 20:45:32 +0000 |
---|---|---|
committer | Russell Bryant <russell@russellbryant.com> | 2011-05-03 20:45:32 +0000 |
commit | 37aa52fd78996b5c516ff4c851b60252eda84b05 (patch) | |
tree | e1651180838e594a0203f863f3cdd084860e1bf5 /channels/chan_phone.c | |
parent | 810b9c887949fc4bd9f01dcdc0d3a4f476cb00de (diff) |
Merged revisions 316265 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8
........
r316265 | russell | 2011-05-03 14:55:49 -0500 (Tue, 03 May 2011) | 5 lines
Fix a bunch of compiler warnings generated by gcc 4.6.0.
Most of these are -Wunused-but-set-variable, but there were a few others
mixed in here, as well.
........
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@316293 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels/chan_phone.c')
-rw-r--r-- | channels/chan_phone.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/channels/chan_phone.c b/channels/chan_phone.c index 6b7420198..4b7ec9721 100644 --- a/channels/chan_phone.c +++ b/channels/chan_phone.c @@ -295,12 +295,10 @@ static int phone_call(struct ast_channel *ast, char *dest, int timeout) ast_localtime(&UtcTime, &tm, NULL); memset(&cid, 0, sizeof(PHONE_CID)); - if(&tm != NULL) { - snprintf(cid.month, sizeof(cid.month), "%02d",(tm.tm_mon + 1)); - snprintf(cid.day, sizeof(cid.day), "%02d", tm.tm_mday); - snprintf(cid.hour, sizeof(cid.hour), "%02d", tm.tm_hour); - snprintf(cid.min, sizeof(cid.min), "%02d", tm.tm_min); - } + snprintf(cid.month, sizeof(cid.month), "%02d",(tm.tm_mon + 1)); + snprintf(cid.day, sizeof(cid.day), "%02d", tm.tm_mday); + snprintf(cid.hour, sizeof(cid.hour), "%02d", tm.tm_hour); + snprintf(cid.min, sizeof(cid.min), "%02d", tm.tm_min); /* the standard format of ast->callerid is: "name" <number>, but not always complete */ if (!ast->connected.id.name.valid || ast_strlen_zero(ast->connected.id.name.str)) { |