Rid us of a silly compiler warning
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@4821 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
parent
a00fad7d48
commit
b7178fdce9
|
@ -1118,15 +1118,16 @@ static struct ast_channel *agent_request(const char *type, int format, void *dat
|
||||||
struct ast_channel *chan = NULL;
|
struct ast_channel *chan = NULL;
|
||||||
char *s;
|
char *s;
|
||||||
ast_group_t groupmatch;
|
ast_group_t groupmatch;
|
||||||
|
int groupoff;
|
||||||
int waitforagent=0;
|
int waitforagent=0;
|
||||||
int hasagent = 0;
|
int hasagent = 0;
|
||||||
struct timeval tv;
|
struct timeval tv;
|
||||||
|
|
||||||
s = data;
|
s = data;
|
||||||
if ((s[0] == '@') && (sscanf(s + 1, "%d", &groupmatch) == 1)) {
|
if ((s[0] == '@') && (sscanf(s + 1, "%d", &groupoff) == 1)) {
|
||||||
groupmatch = (1 << groupmatch);
|
groupmatch = (1 << groupoff);
|
||||||
} else if ((s[0] == ':') && (sscanf(s + 1, "%d", &groupmatch) == 1)) {
|
} else if ((s[0] == ':') && (sscanf(s + 1, "%d", &groupoff) == 1)) {
|
||||||
groupmatch = (1 << groupmatch);
|
groupmatch = (1 << groupoff);
|
||||||
waitforagent = 1;
|
waitforagent = 1;
|
||||||
} else {
|
} else {
|
||||||
groupmatch = 0;
|
groupmatch = 0;
|
||||||
|
@ -1965,14 +1966,15 @@ static int agent_devicestate(void *data)
|
||||||
struct agent_pvt *p;
|
struct agent_pvt *p;
|
||||||
char *s;
|
char *s;
|
||||||
ast_group_t groupmatch;
|
ast_group_t groupmatch;
|
||||||
|
int groupoff;
|
||||||
int waitforagent=0;
|
int waitforagent=0;
|
||||||
int res = AST_DEVICE_INVALID;
|
int res = AST_DEVICE_INVALID;
|
||||||
|
|
||||||
s = data;
|
s = data;
|
||||||
if ((s[0] == '@') && (sscanf(s + 1, "%d", &groupmatch) == 1)) {
|
if ((s[0] == '@') && (sscanf(s + 1, "%d", &groupoff) == 1)) {
|
||||||
groupmatch = (1 << groupmatch);
|
groupmatch = (1 << groupoff);
|
||||||
} else if ((s[0] == ':') && (sscanf(s + 1, "%d", &groupmatch) == 1)) {
|
} else if ((s[0] == ':') && (sscanf(s + 1, "%d", &groupoff) == 1)) {
|
||||||
groupmatch = (1 << groupmatch);
|
groupmatch = (1 << groupoff);
|
||||||
waitforagent = 1;
|
waitforagent = 1;
|
||||||
} else {
|
} else {
|
||||||
groupmatch = 0;
|
groupmatch = 0;
|
||||||
|
|
Loading…
Reference in New Issue