summaryrefslogtreecommitdiff
path: root/channels/chan_skinny.c
diff options
context:
space:
mode:
authorRussell Bryant <russell@russellbryant.com>2011-05-03 20:45:32 +0000
committerRussell Bryant <russell@russellbryant.com>2011-05-03 20:45:32 +0000
commit37aa52fd78996b5c516ff4c851b60252eda84b05 (patch)
treee1651180838e594a0203f863f3cdd084860e1bf5 /channels/chan_skinny.c
parent810b9c887949fc4bd9f01dcdc0d3a4f476cb00de (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_skinny.c')
-rw-r--r--channels/chan_skinny.c19
1 files changed, 3 insertions, 16 deletions
diff --git a/channels/chan_skinny.c b/channels/chan_skinny.c
index a105b6c21..fb2a50434 100644
--- a/channels/chan_skinny.c
+++ b/channels/chan_skinny.c
@@ -3610,8 +3610,6 @@ static int manager_skinny_show_lines(struct mansession *s, const struct message
static char *handle_skinny_show_lines(struct ast_cli_entry *e, int cmd, struct ast_cli_args *a)
{
- int verbose = 0;
-
switch (cmd) {
case CLI_INIT:
e->command = "skinny show lines [verbose]";
@@ -3626,9 +3624,7 @@ static char *handle_skinny_show_lines(struct ast_cli_entry *e, int cmd, struct a
}
if (a->argc == e->args) {
- if (!strcasecmp(a->argv[e->args-1], "verbose")) {
- verbose = 1;
- } else {
+ if (strcasecmp(a->argv[e->args-1], "verbose")) {
return CLI_SHOWUSAGE;
}
} else if (a->argc != e->args - 1) {
@@ -4039,7 +4035,6 @@ static void *skinny_ss(void *data)
static int skinny_call(struct ast_channel *ast, char *dest, int timeout)
{
int res = 0;
- int tone = 0;
struct skinny_subchannel *sub = ast->tech_pvt;
struct skinny_line *l = sub->parent;
struct skinny_device *d = l->device;
@@ -4069,10 +4064,8 @@ static int skinny_call(struct ast_channel *ast, char *dest, int timeout)
switch (l->hookstate) {
case SKINNY_OFFHOOK:
- tone = SKINNY_CALLWAITTONE;
break;
case SKINNY_ONHOOK:
- tone = SKINNY_ALERT;
l->activesub = sub;
break;
default:
@@ -4101,7 +4094,6 @@ static int skinny_hangup(struct ast_channel *ast)
struct skinny_subchannel *sub = ast->tech_pvt;
struct skinny_line *l;
struct skinny_device *d;
- struct skinnysession *s;
if (!sub) {
ast_debug(1, "Asked to hangup channel not connected\n");
@@ -4110,7 +4102,6 @@ static int skinny_hangup(struct ast_channel *ast)
l = sub->parent;
d = l->device;
- s = d->session;
if (skinnydebug)
ast_verb(3,"Hanging up %s/%d\n",d->name,sub->callid);
@@ -5333,7 +5324,6 @@ static int handle_offhook_message(struct skinny_req *req, struct skinnysession *
struct ast_channel *c;
struct skinny_line *tmp;
int instance;
- int reference;
/* if any line on a device is offhook, than the device must be offhook,
unless we have shared lines CCM seems that it would never get here,
@@ -5349,7 +5339,6 @@ static int handle_offhook_message(struct skinny_req *req, struct skinnysession *
}
instance = letohl(req->data.offhook.instance);
- reference = letohl(req->data.offhook.reference);
if (instance) {
sub = find_subchannel_by_instance_reference(d, d->lastlineinstance, d->lastcallreference);
@@ -7177,8 +7166,6 @@ static struct ast_channel *skinny_request(const char *type, struct ast_format_ca
int on = 1;
struct ast_config *cfg;
char *cat;
- struct skinny_device *d;
- struct skinny_line *l;
int oldport = ntohs(bindaddr.sin_port);
struct ast_flags config_flags = { 0 };
@@ -7227,7 +7214,7 @@ static struct ast_channel *skinny_request(const char *type, struct ast_format_ca
config_parse_variables(TYPE_DEF_LINE, default_line, ast_variable_browse(cfg, "lines"));
cat = ast_category_browse(cfg, "lines");
while (cat && strcasecmp(cat, "general") && strcasecmp(cat, "devices")) {
- l = config_line(cat, ast_variable_browse(cfg, cat));
+ config_line(cat, ast_variable_browse(cfg, cat));
cat = ast_category_browse(cfg, cat);
}
@@ -7237,7 +7224,7 @@ static struct ast_channel *skinny_request(const char *type, struct ast_format_ca
config_parse_variables(TYPE_DEF_DEVICE, default_device, ast_variable_browse(cfg, "devices"));
cat = ast_category_browse(cfg, "devices");
while (cat && strcasecmp(cat, "general") && strcasecmp(cat, "lines")) {
- d = config_device(cat, ast_variable_browse(cfg, cat));
+ config_device(cat, ast_variable_browse(cfg, cat));
cat = ast_category_browse(cfg, cat);
}