reduce indentation
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48752 f38db490-d61c-443f-a65b-d21fe96a405b
This commit is contained in:
parent
69f35c5e62
commit
6647f2a9a4
|
@ -1691,24 +1691,22 @@ static int sms_exec (struct ast_channel *chan, void *data)
|
|||
struct ast_module_user *u;
|
||||
struct ast_frame *f;
|
||||
sms_t h = { 0 };
|
||||
unsigned char *p;
|
||||
unsigned char *d = data;
|
||||
int answer = 0;
|
||||
|
||||
u = ast_module_user_add(chan);
|
||||
|
||||
h.ipc0 = h.ipc1 = 20; /* phase for cosine */
|
||||
h.dcs = 0xF1; /* default */
|
||||
if (!data) {
|
||||
ast_log (LOG_ERROR, "Requires queue name at least\n");
|
||||
ast_module_user_remove(u);
|
||||
return -1;
|
||||
}
|
||||
|
||||
u = ast_module_user_add(chan);
|
||||
h.ipc0 = h.ipc1 = 20; /* phase for cosine */
|
||||
h.dcs = 0xF1; /* default */
|
||||
|
||||
if (chan->cid.cid_num)
|
||||
ast_copy_string (h.cli, chan->cid.cid_num, sizeof (h.cli));
|
||||
|
||||
{
|
||||
unsigned char *p;
|
||||
unsigned char *d = data,
|
||||
answer = 0;
|
||||
if (!*d || *d == '|') {
|
||||
ast_log (LOG_ERROR, "Requires queue name\n");
|
||||
ast_module_user_remove(u);
|
||||
|
@ -1727,7 +1725,7 @@ static int sms_exec (struct ast_channel *chan, void *data)
|
|||
for (p = (unsigned char *)h.queue; *p; p++)
|
||||
if (!isalnum (*p))
|
||||
*p = '-'; /* make very safe for filenames */
|
||||
ast_log(LOG_NOTICE, "sms to queue %s\n", h.queue);
|
||||
|
||||
while (*d && *d != '|') {
|
||||
switch (*d) {
|
||||
case 'a': /* we have to send the initial FSK sequence */
|
||||
|
@ -1806,7 +1804,6 @@ ast_log(LOG_NOTICE, "sms to queue %s\n", h.queue);
|
|||
}
|
||||
sms_messagetx (&h);
|
||||
}
|
||||
}
|
||||
|
||||
if (chan->_state != AST_STATE_UP)
|
||||
ast_answer (chan);
|
||||
|
|
Reference in New Issue