[svn-commits] branch north/chan_skinny-fixup r34399 -
/team/north/chan_skinny-fixup/channels/
svn-commits at lists.digium.com
svn-commits at lists.digium.com
Thu Jun 15 19:14:26 MST 2006
Author: north
Date: Thu Jun 15 21:14:25 2006
New Revision: 34399
URL: http://svn.digium.com/view/asterisk?rev=34399&view=rev
Log:
oops..
Modified:
team/north/chan_skinny-fixup/channels/chan_skinny.c
Modified: team/north/chan_skinny-fixup/channels/chan_skinny.c
URL: http://svn.digium.com/view/asterisk/team/north/chan_skinny-fixup/channels/chan_skinny.c?rev=34399&r1=34398&r2=34399&view=diff
==============================================================================
--- team/north/chan_skinny-fixup/channels/chan_skinny.c (original)
+++ team/north/chan_skinny-fixup/channels/chan_skinny.c Thu Jun 15 21:14:25 2006
@@ -1792,8 +1792,7 @@
int speeddialInstance = 1;
int y = 0;
- d = ast_calloc(1, sizeof(struct skinny_device));
- if (!d) {
+ if (!(d = ast_calloc(1, sizeof(struct skinny_device)))) {
return NULL;
} else {
ast_copy_string(d->name, cat, sizeof(d->name));
@@ -1860,6 +1859,8 @@
ast_copy_string(linelabel, v->value, sizeof(linelabel));
} else if (!strcasecmp(v->name, "speeddial")) {
if (!(sd = ast_calloc(1, sizeof(struct skinny_speeddial)))) {
+ return NULL;
+ } else {
char *stringp, *exten, *label;
stringp = v->value;
exten = strsep(&stringp, ",");
@@ -1874,21 +1875,21 @@
sd->next = d->speeddials;
d->speeddials = sd;
- } else {
- return NULL;
}
} else if (!strcasecmp(v->name, "addon")) {
if (!(a = ast_calloc(1, sizeof(struct skinny_addon)))) {
+ return NULL;
+ } else {
ast_mutex_init(&a->lock);
ast_copy_string(a->type, v->value, sizeof(a->type));
a->next = d->addons;
d->addons = a;
- } else {
- return NULL;
}
} else if (!strcasecmp(v->name, "trunk") || !strcasecmp(v->name, "line")) {
if (!(l = ast_calloc(1, sizeof(struct skinny_line)))) {
+ return NULL;
+ } else {
ast_mutex_init(&l->lock);
ast_copy_string(l->name, v->value, sizeof(l->name));
@@ -1930,8 +1931,6 @@
l->next = d->lines;
d->lines = l;
- } else {
- return NULL;
}
} else {
ast_log(LOG_WARNING, "Don't know keyword '%s' at line %d\n", v->name, v->lineno);
@@ -4077,7 +4076,7 @@
ast_log(LOG_WARNING, "Invalid bindport '%s' at line %d of %s\n", v->value, v->lineno, config);
}
if (!strcasecmp(v->name, "port")) { /*! \todo Remove 'port' option after 1.4 */
- ast_log(LOG_WARNING, "Option 'port' at line %d of %s has been deprecated. Please use 'bindport' instead.", v->lineno, config);
+ ast_log(LOG_WARNING, "Option 'port' at line %d of %s has been deprecated. Please use 'bindport' instead.\n", v->lineno, config);
}
}
v = v->next;
More information about the svn-commits
mailing list